summaryrefslogtreecommitdiff
path: root/ruby.c
diff options
context:
space:
mode:
Diffstat (limited to 'ruby.c')
-rw-r--r--ruby.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ruby.c b/ruby.c
index b53784feb1..2e6751f0f2 100644
--- a/ruby.c
+++ b/ruby.c
@@ -1137,7 +1137,7 @@ uscore_get(void)
VALUE line;
line = rb_lastline_get();
- if (TYPE(line) != T_STRING) {
+ if (!RB_TYPE_P(line, T_STRING)) {
rb_raise(rb_eTypeError, "$_ value need to be String (%s given)",
NIL_P(line) ? "nil" : rb_obj_classname(line));
}