diff options
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | test/ruby/test_settracefunc.rb | 2 | ||||
-rw-r--r-- | version.h | 2 | ||||
-rw-r--r-- | vm_insnhelper.c | 2 |
4 files changed, 12 insertions, 2 deletions
@@ -1,3 +1,11 @@ +Tue Aug 18 11:37:24 2009 wanabe <s.wanabe@gmail.com> + + * vm_insnhelper.c (vm_call_cfunc): ensure hook c-return. + [Bug #1588] + + * test/ruby/test_settracefunc.rb (TestSetTraceFunc#test_raise): + follow above. + Mon Aug 17 14:35:03 2009 Nobuyoshi Nakada <nobu@ruby-lang.org> * parse.y (lex_get_str, lex_io_gets, rb_parser_compile_string): diff --git a/test/ruby/test_settracefunc.rb b/test/ruby/test_settracefunc.rb index 8e06c3b515..9486163770 100644 --- a/test/ruby/test_settracefunc.rb +++ b/test/ruby/test_settracefunc.rb @@ -167,6 +167,8 @@ class TestSetTraceFunc < Test::Unit::TestCase events.shift) assert_equal(["raise", 5, :test_raise, TestSetTraceFunc], events.shift) + assert_equal(["c-return", 5, :raise, Kernel], + events.shift) assert_equal(["c-call", 6, :===, Module], events.shift) assert_equal(["c-return", 6, :===, Module], @@ -1,5 +1,5 @@ #define RUBY_VERSION "1.9.1" -#define RUBY_PATCHLEVEL 295 +#define RUBY_PATCHLEVEL 296 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 9 #define RUBY_VERSION_TEENY 1 diff --git a/vm_insnhelper.c b/vm_insnhelper.c index 2a48dba4ad..316f52aeb1 100644 --- a/vm_insnhelper.c +++ b/vm_insnhelper.c @@ -365,7 +365,7 @@ vm_call_cfunc(rb_thread_t *th, rb_control_frame_t *reg_cfp, EXEC_EVENT_HOOK(th, RUBY_EVENT_C_CALL, recv, id, klass); TH_PUSH_TAG(th); - if (th->event_flags & RUBY_EVENT_C_RETURN) { + if (th->event_flags & (RUBY_EVENT_C_RETURN | RUBY_EVENT_VM)) { state = TH_EXEC_TAG(); } else { |