From 412defc7ad75b755b4f001bb469691983203213f Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada Date: Fri, 18 Aug 2023 12:46:43 +0900 Subject: [PATCH] [ruby/io-console] Get rid of address of an rvalue on TruffleRuby https://github.com/ruby/io-console/commit/653c1cd33f --- ext/io/console/console.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/io/console/console.c b/ext/io/console/console.c index b24ac74f27..e852d68eed 100644 --- a/ext/io/console/console.c +++ b/ext/io/console/console.c @@ -1564,7 +1564,8 @@ static VALUE str_chomp(VALUE str) { if (!NIL_P(str)) { - rb_funcallv(str, id_chomp_bang, 1, &rb_default_rs); + const VALUE rs = rb_default_rs; /* rvalue in TruffleRuby */ + rb_funcallv(str, id_chomp_bang, 1, &rs); } return str; }