ruby-changes:35300
From: ko1 <ko1@a...>
Date: Thu, 4 Sep 2014 17:50:48 +0900 (JST)
Subject: [ruby-changes:35300] ko1:r47382 (trunk): * dir.c (glob_helper): use #ifdef instead of #if.
ko1 2014-09-04 17:50:31 +0900 (Thu, 04 Sep 2014) New Revision: 47382 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=47382 Log: * dir.c (glob_helper): use #ifdef instead of #if. gcc's -Wundef option shows warning for undefined macro. * numeric.c (flo_is_finite_p): ditto. * vm_dump.c (rb_vmdebug_thread_dump_state): ditto. * vm_core.h: define VM_DEBUG_VERIFY_METHOD_CACHE to 0. Modified files: trunk/ChangeLog trunk/dir.c trunk/numeric.c trunk/vm_core.h trunk/vm_dump.c Index: ChangeLog =================================================================== --- ChangeLog (revision 47381) +++ ChangeLog (revision 47382) @@ -1,3 +1,14 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Thu Sep 4 17:44:40 2014 Koichi Sasada <ko1@a...> + + * dir.c (glob_helper): use #ifdef instead of #if. + gcc's -Wundef option shows warning for undefined macro. + + * numeric.c (flo_is_finite_p): ditto. + + * vm_dump.c (rb_vmdebug_thread_dump_state): ditto. + + * vm_core.h: define VM_DEBUG_VERIFY_METHOD_CACHE to 0. + Thu Sep 4 03:57:46 2014 Eric Wong <e@8...> * man/ruby.1: spelling fix ("bellow" => "below") [ci-skip] Index: vm_core.h =================================================================== --- vm_core.h (revision 47381) +++ vm_core.h (revision 47382) @@ -474,6 +474,10 @@ typedef struct rb_vm_struct { https://github.com/ruby/ruby/blob/trunk/vm_core.h#L474 #define VM_DEBUG_BP_CHECK 0 #endif +#ifndef VM_DEBUG_VERIFY_METHOD_CACHE +#define VM_DEBUG_VERIFY_METHOD_CACHE 0 +#endif + typedef struct rb_control_frame_struct { VALUE *pc; /* cfp[0] */ VALUE *sp; /* cfp[1] */ Index: dir.c =================================================================== --- dir.c (revision 47381) +++ dir.c (revision 47382) @@ -1405,11 +1405,11 @@ glob_helper( https://github.com/ruby/ruby/blob/trunk/dir.c#L1405 if (magical || recursive) { struct dirent *dp; DIR *dirp; -# if DOSISH +# ifdef DOSISH char *plainname = 0; # endif IF_HAVE_HFS(int hfs_p); -# if DOSISH +# ifdef DOSISH if (cur + 1 == end && (*cur)->type <= ALPHA) { plainname = join_path(path, pathlen, dirsep, (*cur)->str, strlen((*cur)->str)); if (!plainname) return -1; Index: numeric.c =================================================================== --- numeric.c (revision 47381) +++ numeric.c (revision 47382) @@ -1488,7 +1488,7 @@ flo_is_finite_p(VALUE num) https://github.com/ruby/ruby/blob/trunk/numeric.c#L1488 { double value = RFLOAT_VALUE(num); -#if HAVE_ISFINITE +#ifdef HAVE_ISFINITE if (!isfinite(value)) return Qfalse; #else Index: vm_dump.c =================================================================== --- vm_dump.c (revision 47381) +++ vm_dump.c (revision 47382) @@ -432,7 +432,7 @@ rb_vmdebug_thread_dump_state(VALUE self) https://github.com/ruby/ruby/blob/trunk/vm_dump.c#L432 } #if defined(HAVE_BACKTRACE) -# if HAVE_LIBUNWIND +# ifdef HAVE_LIBUNWIND # undef backtrace # define backtrace unw_backtrace # elif defined(__APPLE__) && defined(__x86_64__) -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/