summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--eval.c8
2 files changed, 12 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 4872696b43..ce0922120d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,7 @@
-Sun Jul 30 23:04:03 2006 Nobuyoshi Nakada <nobu@ruby-lang.org>
+Sun Jul 30 23:26:22 2006 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * eval.c (rb_call0): trace call/return of method defined from block.
+ fixed: [ruby-core:08329]
* eval.c (rb_trap_eval): make the current thread runnable to deal with
exceptions which occurred within the trap. fixed: [ruby-dev:27729]
diff --git a/eval.c b/eval.c
index 2917e38c37..60d2b46a3c 100644
--- a/eval.c
+++ b/eval.c
@@ -5838,7 +5838,15 @@ rb_call0(klass, recv, id, oid, argc, argv, body, flags)
case NODE_BMETHOD:
ruby_frame->flags |= FRAME_DMETH;
+ if (event_hooks) {
+ struct BLOCK *data;
+ Data_Get_Struct(body->nd_cval, struct BLOCK, data);
+ EXEC_EVENT_HOOK(RUBY_EVENT_CALL, data->body, recv, id, klass);
+ }
result = proc_invoke(body->nd_cval, rb_ary_new4(argc, argv), recv, klass);
+ if (event_hooks) {
+ EXEC_EVENT_HOOK(RUBY_EVENT_RETURN, body, recv, id, klass);
+ }
break;
case NODE_SCOPE: