From: "mame (Yusuke Endoh)" Date: 2012-03-30T01:53:57+09:00 Subject: [ruby-core:43890] [ruby-trunk - Feature #6096][Rejected] Parser tweak - curly braces followed by a coma... Issue #6096 has been updated by mame (Yusuke Endoh). Status changed from Open to Rejected I agree with Tom. Considering Tom's code, it is apparently difficult to fix this issue. -- Yusuke Endoh ---------------------------------------- Feature #6096: Parser tweak - curly braces followed by a coma... https://bugs.ruby-lang.org/issues/6096#change-25398 Author: ddebernardy (Denis de Bernardy) Status: Rejected Priority: Low Assignee: Category: core Target version: 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 -- http://bugs.ruby-lang.org/