From 3ef09c6e66cf28455536593af60a7c7072fb1777 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Tue, 21 Apr 2020 18:23:20 +0900 Subject: eval_error.c: default nil as "reverse" is now false [Feature #8661] --- eval_error.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'eval_error.c') diff --git a/eval_error.c b/eval_error.c index 809d8aef00..89e27afe56 100644 --- a/eval_error.c +++ b/eval_error.c @@ -309,9 +309,9 @@ rb_error_write(VALUE errinfo, VALUE emesg, VALUE errat, VALUE str, VALUE highlig errat = Qnil; } eclass = CLASS_OF(errinfo); - if (NIL_P(reverse) || NIL_P(highlight)) { + if (NIL_P(reverse)) reverse = Qfalse; + if (NIL_P(highlight)) { VALUE tty = (VALUE)rb_stderr_tty_p(); - if (NIL_P(reverse)) reverse = tty; if (NIL_P(highlight)) highlight = tty; } if (reverse) { -- cgit v1.2.3