Actions
Feature #8361
closedAlternative syntax for block parameter
Status:
Closed
Assignee:
-
Target version:
-
Description
=begin
I propose an alternative syntax for block parameters:
p = lambda [x] {
# do whatever you like with x here, but be sure to return the result
}
instead of
p = lambda { |x|
# ...
}
This would be consistent with the syntax of procedure call: (({p[a]})).
Also, compare:
a_bunch.each [element] do
# ...
end
with:
a_bunch.each do |element|
# ...
end
=end
Actions
Like0
Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0