ruby-changes:57517
From: Takashi <ko1@a...>
Date: Tue, 3 Sep 2019 21:13:08 +0900 (JST)
Subject: [ruby-changes:57517] beaabd2308 (master): Unify SUPPORT_JOKE and OPT_SUPPORT_JOKE
https://git.ruby-lang.org/ruby.git/commit/?id=beaabd2308 From beaabd23087a54364bc8fc8aa7a45dd9f425e19b Mon Sep 17 00:00:00 2001 From: Takashi Kokubun <takashikkbn@g...> Date: Tue, 3 Sep 2019 21:08:07 +0900 Subject: Unify SUPPORT_JOKE and OPT_SUPPORT_JOKE for simplicity and consistency. Now SUPPORT_JOKE needs to be prefixed with OPT_ to make the config visible in `RubyVM::VmOptsH`, and the inconsistency was introduced. As it has never been available for override in configure (no #ifndef guard), it should be fine to rename the config. diff --git a/compile.c b/compile.c index ad99982..3315716 100644 --- a/compile.c +++ b/compile.c @@ -732,7 +732,7 @@ rb_iseq_compile_node(rb_iseq_t *iseq, const NODE *node) https://github.com/ruby/ruby/blob/trunk/compile.c#L732 ADD_INSN(ret, ISEQ_COMPILE_DATA(iseq)->last_line, leave); } -#if SUPPORT_JOKE +#if OPT_SUPPORT_JOKE if (ISEQ_COMPILE_DATA(iseq)->labels_table) { st_table *labels_table = ISEQ_COMPILE_DATA(iseq)->labels_table; ISEQ_COMPILE_DATA(iseq)->labels_table = 0; @@ -6570,7 +6570,7 @@ compile_call(rb_iseq_t *iseq, LINK_ANCHOR *const ret, const NODE *const node, in https://github.com/ruby/ruby/blob/trunk/compile.c#L6570 INIT_ANCHOR(recv); INIT_ANCHOR(args); -#if SUPPORT_JOKE +#if OPT_SUPPORT_JOKE if (nd_type(node) == NODE_VCALL) { ID id_bitblt; ID id_answer; diff --git a/eval.c b/eval.c index 614bb04..30d4ea5 100644 --- a/eval.c +++ b/eval.c @@ -478,7 +478,7 @@ static VALUE get_ec_errinfo(const rb_execution_context_t *ec); https://github.com/ruby/ruby/blob/trunk/eval.c#L478 static VALUE exc_setup_cause(VALUE exc, VALUE cause) { -#if SUPPORT_JOKE +#if OPT_SUPPORT_JOKE if (NIL_P(cause)) { ID id_true_cause; CONST_ID(id_true_cause, "true_cause"); diff --git a/iseq.h b/iseq.h index 13cbd90..711afeb 100644 --- a/iseq.h +++ b/iseq.h @@ -109,7 +109,7 @@ struct iseq_compile_data { https://github.com/ruby/ruby/blob/trunk/iseq.h#L109 unsigned int ci_kw_index; const rb_compile_option_t *option; struct rb_id_table *ivar_cache_table; -#if SUPPORT_JOKE +#if OPT_SUPPORT_JOKE st_table *labels_table; #endif }; diff --git a/vm_opts.h b/vm_opts.h index 9892d3c..d4e2ed7 100644 --- a/vm_opts.h +++ b/vm_opts.h @@ -62,7 +62,6 @@ https://github.com/ruby/ruby/blob/trunk/vm_opts.h#L62 /* misc */ #define OPT_SUPPORT_JOKE 0 -#define SUPPORT_JOKE OPT_SUPPORT_JOKE #ifndef VM_COLLECT_USAGE_DETAILS #define VM_COLLECT_USAGE_DETAILS 0 -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/