  static VALUE
  insn_operand_intern(rb_iseq_t *iseq,
  		    VALUE insn, int op_no, VALUE op,
-@@ -898,9 +1020,8 @@
+@@ -901,9 +1023,8 @@
  }
  
  VALUE
 -rb_iseq_disasm(VALUE self)
-+rb_iseq_disasm_internal(rb_iseq_t *iseqdat)
++rb_iseq_disasm_internal(rb_iseq_t *iseqdat, int include_child)
  {
 -    rb_iseq_t *iseqdat = iseq_check(self);
      VALUE *iseq;
      VALUE str = rb_str_new(0, 0);
      VALUE child = rb_ary_new();
-@@ -1000,6 +1121,19 @@
+@@ -995,14 +1116,44 @@
+ 	n += rb_iseq_disasm_insn(str, iseq, n, iseqdat, child);
+     }
+ 
+-    for (i = 0; i < RARRAY_LEN(child); i++) {
+-	VALUE isv = rb_ary_entry(child, i);
+-	rb_str_concat(str, rb_iseq_disasm(isv));
+-    }
++    if (include_child)
++	for (i = 0; i < RARRAY_LEN(child); i++) {
++	    VALUE isv = rb_ary_entry(child, i);
++	    rb_str_concat(str, rb_iseq_disasm(isv));
++	}
+ 
      return str;
  }
  

 #define RUBY_EVENT_COVERAGE 0x40000
Index: vm_core.h
===================================================================
--- vm_core.h	(revision 25354)
+++ vm_core.h	(working copy)
@@ -155,7 +155,7 @@
     VALUE type;          /* instruction sequence type */

     struct METHOD *data;
Index: thread.c
===================================================================
--- thread.c	(revision 25424)
+++ thread.c	(working copy)
@@ -309,6 +309,16 @@
 
