Actions
Bug #20423
closedAnonymous block forwarding shouldn't work with ... but it does
Description
According to this note, anonymous block forwarding should only be supported when explicitly used in the method signature.
For example:
def foo(&) = bar(&) # OK
def foo = bar(&) # NG
However, if you use ...
in the method signature, &
seems to work:
def foo(...)
# bar(*) # Syntax Error
# bar(**) # Syntax Error
bar(&) # not a syntax error, but I think it should be
end
I think this should be a syntax error.
Updated by nobu (Nobuyoshi Nakada) 9 months ago
Updated by nobu (Nobuyoshi Nakada) 9 months ago
- Status changed from Open to Closed
Applied in changeset git|e36988450e9e9ccccb41c72135f1e57790920668.
[Bug #20423] Disallow anonymous block within argument forwarding
Actions
Like0
Like0Like0