[前][次][番号順一覧][スレッド一覧]

ruby-changes:12842

From: wanabe <ko1@a...>
Date: Tue, 18 Aug 2009 11:44:30 +0900 (JST)
Subject: [ruby-changes:12842] Ruby:r24574 (trunk): * vm_insnhelper.c (vm_call_cfunc): ensure hook c-return.

wanabe	2009-08-18 11:44:10 +0900 (Tue, 18 Aug 2009)

  New Revision: 24574

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=24574

  Log:
    * vm_insnhelper.c (vm_call_cfunc): ensure hook c-return.
      [Bug #1588]
    * test/ruby/test_settracefunc.rb (TestSetTraceFunc#test_raise):
      follow above.

  Modified files:
    trunk/ChangeLog
    trunk/test/ruby/test_settracefunc.rb
    trunk/vm_insnhelper.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 24573)
+++ ChangeLog	(revision 24574)
@@ -1,3 +1,11 @@
+Tue Aug 18 11:37:24 2009  wanabe  <s.wanabe@g...>
+
+	* vm_insnhelper.c (vm_call_cfunc): ensure hook c-return.
+	  [Bug #1588]
+
+	* test/ruby/test_settracefunc.rb (TestSetTraceFunc#test_raise):
+	  follow above.
+
 Tue Aug 18 01:57:00 2009  Yukihiro Matsumoto  <matz@r...>
 
 	* range.c (range_step): treat symbols specially so that iterating
Index: vm_insnhelper.c
===================================================================
--- vm_insnhelper.c	(revision 24573)
+++ vm_insnhelper.c	(revision 24574)
@@ -370,7 +370,7 @@
 #if defined(__cplusplus) || (__STDC_VERSION__ >= 199901L)
     // TODO: fix me.  separate event
 #endif
-    if (th->event_flags & RUBY_EVENT_C_RETURN) {
+    if (th->event_flags & (RUBY_EVENT_C_RETURN | RUBY_EVENT_VM)) {
 	state = TH_EXEC_TAG();
     }
     else {
Index: test/ruby/test_settracefunc.rb
===================================================================
--- test/ruby/test_settracefunc.rb	(revision 24573)
+++ test/ruby/test_settracefunc.rb	(revision 24574)
@@ -167,6 +167,8 @@
                  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],

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]