diff --git a/defs/id.def b/defs/id.def index 90d2e84074..42386e5f36 100644 --- a/defs/id.def +++ b/defs/id.def @@ -35,6 +35,7 @@ firstline, predefined = __LINE__+1, %[\ to_io to_a to_s + to_i _ UScore "/*NULL*/" NULL diff --git a/numeric.c b/numeric.c index 35aa8e93c9..34abd1d90c 100644 --- a/numeric.c +++ b/numeric.c @@ -109,7 +109,8 @@ static VALUE fix_uminus(VALUE num); static VALUE fix_mul(VALUE x, VALUE y); static VALUE int_pow(long x, unsigned long y); -static ID id_coerce, id_to_i, id_div; +static ID id_coerce, id_div; +#define id_to_i idTo_i #define id_eq idEq #define id_cmp idCmp @@ -3981,7 +3982,6 @@ Init_Numeric(void) _control87(_control87(0,0),0x1FFF); #endif id_coerce = rb_intern("coerce"); - id_to_i = rb_intern("to_i"); id_div = rb_intern("div"); rb_eZeroDivError = rb_define_class("ZeroDivisionError", rb_eStandardError); diff --git a/object.c b/object.c index 4f360a7906..582e2e2121 100644 --- a/object.c +++ b/object.c @@ -2559,6 +2559,7 @@ static const struct conv_method_tbl { M(io), M(a), M(s), + M(i), #undef M }; #define IMPLICIT_CONVERSIONS 7