aboutsummaryrefslogtreecommitdiffstats
path: root/bootstraptest
diff options
context:
space:
mode:
Diffstat (limited to 'bootstraptest')
-rw-r--r--bootstraptest/test_proc.rb25
1 files changed, 25 insertions, 0 deletions
diff --git a/bootstraptest/test_proc.rb b/bootstraptest/test_proc.rb
index 3d347004ea..c23394e8d2 100644
--- a/bootstraptest/test_proc.rb
+++ b/bootstraptest/test_proc.rb
@@ -456,3 +456,28 @@ assert_equal 'ok', %q{
end
}
+assert_equal 'ok', %q{
+ def x
+ binding
+ end
+ b = x{|a| a }
+ b.eval('yield("ok")')
+}, '[Bug #5634]'
+
+assert_equal 'ok', %q{
+ def x
+ binding
+ end
+ eval("x { 'ok' }").eval "yield"
+}, '[Bug #5634]'
+
+assert_equal 'ok', %q{
+ def x
+ binding
+ end
+ def m
+ x{ 'ok' }
+ end
+ eval('yield', m)
+}, '[Bug #5634]'
+