ruby-changes:58633
From: =E5=8D=9C=E9=83=A8=E6=98=8C=E5=B9=B3 <ko1@a...>
Date: Fri, 8 Nov 2019 11:25:31 +0900 (JST)
Subject: [ruby-changes:58633] 7661150109 (master): revival of __func__
https://git.ruby-lang.org/ruby.git/commit/?id=7661150109 From 766115010932d977142097f60c76dd20af73196e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8D=9C=E9=83=A8=E6=98=8C=E5=B9=B3?= <shyouhei@r...> Date: Fri, 8 Nov 2019 11:11:21 +0900 Subject: revival of __func__ dad2abc69fdd1af52df353b8604017bd6a5c6a99 deleted __func__ but ruby already use this feature under RUBY_FUNCTION_NAME_STRING macro. Use it. diff --git a/compile.c b/compile.c index 08a7576..b9106d2 100644 --- a/compile.c +++ b/compile.c @@ -9769,9 +9769,9 @@ ibf_load_builtin(const struct ibf_load *load, ibf_offset_t *offset) https://github.com/ruby/ruby/blob/trunk/compile.c#L9769 } const struct rb_builtin_function *table = GET_VM()->builtin_function_table; - if (table == NULL) rb_bug("ibf_load_builtin: table is not provided."); + if (table == NULL) rb_bug("%s: table is not provided.", RUBY_FUNCTION_NAME_STRING); if (strncmp(table[i].name, name, len) != 0) { - rb_bug("ibf_load_builtin: index (%d) mismatch (expect %s but %s).", i, name, table[i].name); + rb_bug("%s: index (%d) mismatch (expect %s but %s).", RUBY_FUNCTION_NAME_STRING, i, name, table[i].name); } // fprintf(stderr, "load-builtin: name:%s(%d)\n", table[i].name, table[i].argc); -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/