diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-05-18 01:17:43 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2016-05-18 01:17:43 +0000 |
commit | 4a9705d6e3384342a3ee649bfdbd93062140b5fd (patch) | |
tree | adf65284cfe148dee36c8d8def3739543dcdf37a /string.c | |
parent | abe32a00b1096c0be8196385cccb983ca2b5e497 (diff) |
ruby.h: RB_INTEGER_TYPE_P
* include/ruby/ruby.h (RB_INTEGER_TYPE_P): new macro and
underlying inline function to check if the object is an
Integer (Fixnum or Bignum).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@55044 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'string.c')
-rw-r--r-- | string.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -2746,7 +2746,7 @@ rb_str_concat(VALUE str1, VALUE str2) rb_encoding *enc = STR_ENC_GET(str1); int encidx; - if (FIXNUM_P(str2) || RB_TYPE_P(str2, T_BIGNUM)) { + if (RB_INTEGER_TYPE_P(str2)) { if (rb_num_to_uint(str2, &code) == 0) { } else if (FIXNUM_P(str2)) { |