M
Mark J. Reed
Okay, this is probably a dumb question, but how do I declare an
optional block parameter with a default value?
I tried several variations on this basic theme:
def meth(&block = lambda { |i| ... })
...
end
But I keep getting syntax errors. Help?
optional block parameter with a default value?
I tried several variations on this basic theme:
def meth(&block = lambda { |i| ... })
...
end
But I keep getting syntax errors. Help?