summaryrefslogtreecommitdiff
path: root/iseq.c
diff options
context:
space:
mode:
authortenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-04-13 21:36:51 +0000
committertenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-04-13 21:36:51 +0000
commit5bafb6c596ae140e70aebb2378f81e4273c99058 (patch)
tree2584452bbb6f653b3a5bd9d72777ad6ba40e4663 /iseq.c
parent282efd1f326c75bfa1368ddd9ea54464a361bd4f (diff)
Add write barrier calls for direct marking objects.
This commit adds write barriers for objects marked from `rb_iseq_mark`. r62851 introduced direct marking from iseqs to: * keyword arg default values * catch table iseqs * VALUEs embedded in encoded instructions This patch adds missing write barrier calls to those references. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63147 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'iseq.c')
-rw-r--r--iseq.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/iseq.c b/iseq.c
index 68ad9a3160..96ccb56ecd 100644
--- a/iseq.c
+++ b/iseq.c
@@ -235,7 +235,7 @@ rb_iseq_mark(const rb_iseq_t *iseq)
for (j = 0; i < body->param.keyword->num; i++, j++) {
VALUE obj = body->param.keyword->default_values[j];
- if (obj != Qundef) {
+ if (!SPECIAL_CONST_P(obj)) {
rb_gc_mark(obj);
}
}