summaryrefslogtreecommitdiff
path: root/bootstraptest
diff options
context:
space:
mode:
Diffstat (limited to 'bootstraptest')
-rw-r--r--bootstraptest/test_method.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/bootstraptest/test_method.rb b/bootstraptest/test_method.rb
index 5bc0f8ccec..63c6ad2db1 100644
--- a/bootstraptest/test_method.rb
+++ b/bootstraptest/test_method.rb
@@ -1058,3 +1058,14 @@ assert_equal '[false, false, false, false, true, true]', %q{
D.new.bar{}
[C.new.foo, C.new.foo{}, D.new.m1, D.new.m1{}, D.new.m2, D.new.m2{}]
}, '[ruby-core:14813]'
+
+assert_equal 'ok', %q{
+ class Foo
+ define_method(:foo) do |&b|
+ b.call
+ end
+ end
+ Foo.new.foo do
+ break :ok
+ end
+}, '[ruby-dev:36028]'