ruby-changes:14830
From: nobu <ko1@a...>
Date: Wed, 17 Feb 2010 17:06:00 +0900 (JST)
Subject: [ruby-changes:14830] Ruby:r26695 (trunk): * vm_insnhelper.c (vm_call_cfunc): removed unused variable.
nobu 2010-02-17 17:05:42 +0900 (Wed, 17 Feb 2010) New Revision: 26695 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=26695 Log: * vm_insnhelper.c (vm_call_cfunc): removed unused variable. * vm.c (vm_frametype_name): define only when VMDEBUG. Modified files: trunk/ChangeLog trunk/vm.c trunk/vm_eval.c trunk/vm_insnhelper.c Index: ChangeLog =================================================================== --- ChangeLog (revision 26694) +++ ChangeLog (revision 26695) @@ -1,3 +1,9 @@ +Wed Feb 17 17:05:39 2010 Nobuyoshi Nakada <nobu@r...> + + * vm_insnhelper.c (vm_call_cfunc): removed unused variable. + + * vm.c (vm_frametype_name): define only when VMDEBUG. + Wed Feb 17 15:34:45 2010 Nobuyoshi Nakada <nobu@r...> * ext/dl/dl_conversions.c (rb_dl_type_to_ffi_type): support signed Index: vm_eval.c =================================================================== --- vm_eval.c (revision 26694) +++ vm_eval.c (revision 26695) @@ -814,8 +814,10 @@ return Qnil; /* dummy */ } +#if VMDEBUG static const char * vm_frametype_name(const rb_control_frame_t *cfp); +#endif VALUE rb_iterate(VALUE (* it_proc) (VALUE), VALUE data1, @@ -858,7 +860,9 @@ /* check skipped frame */ while (th->cfp != cfp) { - /* printf("skipped frame: %s\n", vm_frametype_name(th->cfp)); */ +#if VMDEBUG + printf("skipped frame: %s\n", vm_frametype_name(th->cfp)); +#endif if (UNLIKELY(VM_FRAME_TYPE(th->cfp) == VM_FRAME_MAGIC_CFUNC)) { const rb_method_entry_t *me = th->cfp->me; EXEC_EVENT_HOOK(th, RUBY_EVENT_C_RETURN, th->cfp->self, me->called_id, me->klass); Index: vm.c =================================================================== --- vm.c (revision 26694) +++ vm.c (revision 26695) @@ -987,6 +987,7 @@ /* for vm development */ +#if VMDEBUG static const char * vm_frametype_name(const rb_control_frame_t *cfp) { @@ -1005,6 +1006,7 @@ rb_bug("unknown frame"); } } +#endif /* evaluator body */ Index: vm_insnhelper.c =================================================================== --- vm_insnhelper.c (revision 26694) +++ vm_insnhelper.c (revision 26695) @@ -364,7 +364,6 @@ const rb_method_entry_t *me) { VALUE val = 0; - int state = 0; const rb_method_definition_t *def = me->def; rb_control_frame_t *cfp; -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/