diff --git a/ChangeLog b/ChangeLog index 115da412b0..fb13855562 100644 --- a/ChangeLog +++ b/ChangeLog @@ -6,7 +6,6 @@ Sun Nov 9 23:25:49 2014 Nobuyoshi Nakada * vm_insnhelper.c (vm_yield_with_cfunc): push defined class and bound proc method entry to the control frame. - Sun Nov 9 22:46:13 2014 Tanaka Akira * test/open-uri: Test server log in server thread. diff --git a/test/-ext-/proc/test_bmethod.rb b/test/-ext-/proc/test_bmethod.rb new file mode 100644 index 0000000000..09f52140b9 --- /dev/null +++ b/test/-ext-/proc/test_bmethod.rb @@ -0,0 +1,24 @@ +require 'test/unit' +require '-test-/proc' + +class TestProc < Test::Unit::TestCase + class TestBMethod < Test::Unit::TestCase + end +end + +class TestProc::TestBMethod + class Base + def foo(*a) + a + end + end + + class Bound < Base + define_method(:foo, Bug::Proc.make_caller(42)) + end + + def test_super_in_bmethod + obj = Bound.new + assert_equal([1, 42], obj.foo(1)) + end +end