summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2023-05-01 10:34:11 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2023-05-02 17:39:18 +0900
commitb15e88e0fcccb03b9cc5e4c1478ec9b10e26c961 (patch)
tree7444ffb9aa8c0e6bd879852c885a480a864c6753 /test
parente47aa27dc799213066732fc7e34f2eeaf059b001 (diff)
downloadruby-b15e88e0fcccb03b9cc5e4c1478ec9b10e26c961.tar.gz
[Bug #19619] Preserve numbered parameters context
Preserve numbered parameters context across method definitions
Diffstat (limited to 'test')
-rw-r--r--test/ruby/test_syntax.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/ruby/test_syntax.rb b/test/ruby/test_syntax.rb
index a1b84c61b4..4c0e58cc7b 100644
--- a/test/ruby/test_syntax.rb
+++ b/test/ruby/test_syntax.rb
@@ -1670,6 +1670,8 @@ eom
assert_raise(NameError) {eval("_1")},
]
}
+
+ assert_valid_syntax("proc {def foo(_);end;_1}")
end
def test_value_expr_in_condition