[#104004] [Ruby master Feature#17883] Load bundler/setup earlier to make `bundle exec ruby -r` respect Gemfile — mame@...
Issue #17883 has been reported by mame (Yusuke Endoh).
21 messages
2021/05/24
[ruby-core:103798] [Ruby master Bug#17858] Trailing comma after a `&block` parameter cause a syntax error
From:
matz@...
Date:
2021-05-12 13:54:31 UTC
List:
ruby-core #103798
Issue #17858 has been updated by matz (Yukihiro Matsumoto). Status changed from Open to Closed It is intended. `&block` argument must come at the end of arguments. Nothing comes after. Matz. ---------------------------------------- Bug #17858: Trailing comma after a `&block` parameter cause a syntax error https://bugs.ruby-lang.org/issues/17858#change-91913 * Author: byroot (Jean Boussier) * Status: Closed * Priority: Normal * Backport: 2.6: UNKNOWN, 2.7: UNKNOWN, 3.0: UNKNOWN ---------------------------------------- Something I just noticed: ```ruby some_long_method( 1, &block, # syntax error, unexpected ',', expecting ')' ) ``` Which seems inconsistent to me as it works for regular parameters: ```ruby some_long_method( 1, 2, ) ``` I'm not sure if this is an intended limitation or just an oversight. -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:[email protected]?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>