summaryrefslogtreecommitdiff
path: root/insns.def
diff options
context:
space:
mode:
authorAaron Patterson <tenderlove@ruby-lang.org>2021-03-16 15:30:47 -0700
committerAaron Patterson <aaron.patterson@gmail.com>2021-03-17 10:55:37 -0700
commit8359821870d756eb75d66c5ddb5d119f6247c35d (patch)
treeda96d7248f3725aadd08eed812d5460f4d6a260d /insns.def
parentea817c60fcbdc2c4496be045f5bf028b702561ba (diff)
Use rb_fstring for "defined" strings.
We can take advantage of fstrings to de-duplicate the defined strings. This means we don't need to keep the list of defined strings on the VM (or register them as mark objects)
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/4279
Diffstat (limited to 'insns.def')
-rw-r--r--insns.def4
1 files changed, 2 insertions, 2 deletions
diff --git a/insns.def b/insns.def
index 1dc0bb3365..5704bf44e7 100644
--- a/insns.def
+++ b/insns.def
@@ -662,14 +662,14 @@ adjuststack
/* defined? */
DEFINE_INSN
defined
-(rb_num_t op_type, VALUE obj, VALUE needstr)
+(rb_num_t op_type, VALUE obj, VALUE pushval)
(VALUE v)
(VALUE val)
// attr bool leaf = leafness_of_defined(op_type);
{
val = Qnil;
if (vm_defined(ec, GET_CFP(), op_type, obj, v)) {
- val = needstr;
+ val = pushval;
}
}