diff options
Diffstat (limited to 'spec/ruby/optional/capi/ext/object_spec.c')
-rw-r--r-- | spec/ruby/optional/capi/ext/object_spec.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/ruby/optional/capi/ext/object_spec.c b/spec/ruby/optional/capi/ext/object_spec.c index c95e1b553f..477105aacc 100644 --- a/spec/ruby/optional/capi/ext/object_spec.c +++ b/spec/ruby/optional/capi/ext/object_spec.c @@ -348,9 +348,9 @@ static VALUE object_spec_rb_class_inherited_p(VALUE self, VALUE mod, VALUE arg) static VALUE speced_allocator(VALUE klass) { VALUE flags = 0; VALUE instance; - if (rb_class_inherited_p(klass, rb_cString)) { + if (RTEST(rb_class_inherited_p(klass, rb_cString))) { flags = T_STRING; - } else if (rb_class_inherited_p(klass, rb_cArray)) { + } else if (RTEST(rb_class_inherited_p(klass, rb_cArray))) { flags = T_ARRAY; } else { flags = T_OBJECT; |