summaryrefslogtreecommitdiff
path: root/rational.c
diff options
context:
space:
mode:
Diffstat (limited to 'rational.c')
-rw-r--r--rational.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/rational.c b/rational.c
index b7a3ee6..93a5377 100644
--- a/rational.c
+++ b/rational.c
@@ -368,7 +368,7 @@ f_lcm(VALUE x, VALUE y)
inline static VALUE
nurat_s_new_internal(VALUE klass, VALUE num, VALUE den)
{
- NEWOBJ_OF(obj, struct RRational, klass, T_RATIONAL);
+ NEWOBJ_OF(obj, struct RRational, klass, T_RATIONAL | (RGENGC_WB_PROTECTED_RATIONAL ? FL_WB_PROTECTED : 0));
RRATIONAL_SET_NUM(obj, num);
RRATIONAL_SET_DEN(obj, den);