summaryrefslogtreecommitdiff
path: root/numeric.c
diff options
context:
space:
mode:
Diffstat (limited to 'numeric.c')
-rw-r--r--numeric.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/numeric.c b/numeric.c
index 7912c6278c..c2562f4698 100644
--- a/numeric.c
+++ b/numeric.c
@@ -13,6 +13,7 @@
#include "ruby/encoding.h"
#include "ruby/util.h"
#include "internal.h"
+#include "id.h"
#include <ctype.h>
#include <math.h>
#include <stdio.h>
@@ -1528,7 +1529,7 @@ int_round_0(VALUE num, int ndigits)
ID op;
/* If 10**N / 2 > num, then return 0 */
/* We have log_256(10) > 0.415241 and log_256(1/2) = -0.125, so */
- bytes = FIXNUM_P(num) ? sizeof(long) : rb_funcall(num, rb_intern("size"), 0);
+ bytes = FIXNUM_P(num) ? sizeof(long) : rb_funcall(num, idSize, 0);
if (-0.415241 * ndigits - 0.125 > bytes ) {
return INT2FIX(0);
}