Actions
Feature #6096
closedParser tweak - curly braces followed by a coma...
Status:
Rejected
Assignee:
-
Target version:
-
Description
It would be sweet if ruby treated curly braces followed by a coma as a hash rather than as a coma:
def foo(bar, baz)
end
=> nil
foo {}, :baz
SyntaxError: (irb):3: syntax error, unexpected ',', expecting $end
foo {}, :baz
^
from /opt/local/bin/irb:12:in `'
I keep forgetting and run into the issue on a regular basis when writing unit tests... aka:
assert_equal {}, do_stuff
Actions
Like0
Like0Like0Like0Like0