Project

General

Profile

Actions

Bug #14341

closed

do/end blocks after arrow operator don't work with ensure/rescue/else

Added by takiuchi (Genki Takiuchi) over 4 years ago. Updated over 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
[ruby-core:84754]

Description

New feature #12906 seems lacks a bit of implementation.

Example:

-> do
rescue
end
# => syntax error, unexpected keyword_rescue

lambda do
rescue
end
# => it's ok!

This behavior looks inconsistent.
I think all do/end blocks should work with ensure/rescue/else.

Actions

Also available in: Atom PDF