diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | test/ruby/test_proc.rb | 8 | ||||
-rw-r--r-- | version.h | 2 | ||||
-rw-r--r-- | vm.c | 2 |
4 files changed, 15 insertions, 2 deletions
@@ -1,3 +1,8 @@ +Sun Aug 29 13:22:43 2010 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * vm.c (rb_thread_method_id_and_class): curried proc has no + method. [ruby-core:31871] + Fri Sep 24 23:44:59 2010 Nobuyoshi Nakada <nobu@ruby-lang.org> * string.c (sym_call), vm.c (invoke_block_from_c), diff --git a/test/ruby/test_proc.rb b/test/ruby/test_proc.rb index 4a1eee3926..efd5a269fd 100644 --- a/test/ruby/test_proc.rb +++ b/test/ruby/test_proc.rb @@ -793,6 +793,14 @@ class TestProc < Test::Unit::TestCase end end + def test_curry_with_trace + bug3751 = '[ruby-core:31871]' + set_trace_func(proc {}) + test_curry + ensure + set_trace_func(nil) + end + def test_block_propagation bug3792 = '[ruby-core:32075]' c = Class.new do @@ -1,5 +1,5 @@ #define RUBY_VERSION "1.9.2" -#define RUBY_PATCHLEVEL 54 +#define RUBY_PATCHLEVEL 55 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 9 #define RUBY_VERSION_TEENY 1 @@ -1396,7 +1396,7 @@ rb_thread_method_id_and_class(rb_thread_t *th, { rb_control_frame_t *cfp = th->cfp; rb_iseq_t *iseq = cfp->iseq; - if (!iseq) { + if (!iseq && cfp->me) { if (idp) *idp = cfp->me->def->original_id; if (klassp) *klassp = cfp->me->klass; return 1; |