diff options
author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-10-27 03:00:26 +0000 |
---|---|---|
committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-10-27 03:00:26 +0000 |
commit | 6ef1aa79644736cbfef51a788750741db300c976 (patch) | |
tree | ddc128054a944ebd1b177037183565b89f1f07d6 /include | |
parent | bb2dc7e98693ad0c27c21d02f8ffd049fa2589a4 (diff) | |
download | ruby-6ef1aa79644736cbfef51a788750741db300c976.tar.gz |
* include/ruby/ruby.h (NUM2LONG_internal): add cast to get rid of a
non GCC compiler warning. this is intentional type conversion.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29605 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include')
-rw-r--r-- | include/ruby/ruby.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h index 28d386996e..4a3e0ffc71 100644 --- a/include/ruby/ruby.h +++ b/include/ruby/ruby.h @@ -481,7 +481,7 @@ void rb_set_errinfo(VALUE); SIGNED_VALUE rb_num2long(VALUE); VALUE rb_num2ulong(VALUE); -#define NUM2LONG_internal(x) (FIXNUM_P(x) ? FIX2LONG(x) : rb_num2long(x)) +#define NUM2LONG_internal(x) ((long)(FIXNUM_P(x) ? FIX2LONG(x) : rb_num2long(x))) #ifdef __GNUC__ #define NUM2LONG(x) \ __extension__ ({VALUE num2long_x = (x); NUM2LONG_internal(num2long_x);}) |