From 801fda2b00ca399ced33e8ea74aee60a0950bbba Mon Sep 17 00:00:00 2001 From: Gonzalo Garramuno Date: Sat, 2 Jun 2007 10:24:23 +0000 Subject: [PATCH] Moved Init_stack() declaration over to rubyapi to avoid potential C++ issues. git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@9844 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Lib/ruby/rubyapi.swg | 8 ++++++++ Lib/ruby/rubyhead.swg | 9 --------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/Lib/ruby/rubyapi.swg b/Lib/ruby/rubyapi.swg index 7883e9e6c..6c5fdfee3 100644 --- a/Lib/ruby/rubyapi.swg +++ b/Lib/ruby/rubyapi.swg @@ -21,6 +21,14 @@ SWIG_Ruby_AppendOutput(VALUE target, VALUE o) { return target; } +// For ruby1.8.4 and earlier. +#ifndef RUBY_INIT_STACK + extern void Init_stack(VALUE* addr); +# define RUBY_INIT_STACK \ + VALUE variable_in_this_stack_frame; \ + Init_stack(&variable_in_this_stack_frame); +#endif + #ifdef __cplusplus } #endif diff --git a/Lib/ruby/rubyhead.swg b/Lib/ruby/rubyhead.swg index d55d49882..bf46dc88d 100644 --- a/Lib/ruby/rubyhead.swg +++ b/Lib/ruby/rubyhead.swg @@ -96,14 +96,5 @@ #endif -// For ruby1.8.4 and earlier. -#ifndef RUBY_INIT_STACK - extern void Init_stack(VALUE* addr); -# define RUBY_INIT_STACK \ - VALUE variable_in_this_stack_frame; \ - Init_stack(&variable_in_this_stack_frame); -#endif - - /* Global module used to keep some internal SWIG stuff */ static VALUE _mSWIG = Qnil;