diff options
author | Kevin Newton <kddnewton@gmail.com> | 2023-09-07 09:10:50 -0400 |
---|---|---|
committer | Kevin Newton <kddnewton@gmail.com> | 2023-09-07 09:10:50 -0400 |
commit | 0c8928721e19dda1ce7b1a8797b18d199207708c (patch) | |
tree | 033deee88bf8c6b3d8d942cb0b492dd1ae577bb6 /yarp | |
parent | 14970cfc8d4ae68d173a2df45abecc4c41220270 (diff) |
[YARP] Use the correct field for the name on classes and modules
Diffstat (limited to 'yarp')
-rw-r--r-- | yarp/yarp_compiler.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/yarp/yarp_compiler.c b/yarp/yarp_compiler.c index 10ef6a1e8c..8b9190cad8 100644 --- a/yarp/yarp_compiler.c +++ b/yarp/yarp_compiler.c @@ -597,7 +597,7 @@ yp_compile_node(rb_iseq_t *iseq, const yp_node_t *node, LINK_ANCHOR *const ret, yp_scope_node_t scope_node; yp_scope_node_init((yp_node_t *)class_node, &scope_node); - ID class_id = yp_constant_id_lookup(compile_context, class_node->name_constant); + ID class_id = yp_constant_id_lookup(compile_context, class_node->name); VALUE class_name = rb_str_freeze(rb_sprintf("<class:%"PRIsVALUE">", rb_id2str(class_id))); @@ -1463,7 +1463,7 @@ yp_compile_node(rb_iseq_t *iseq, const yp_node_t *node, LINK_ANCHOR *const ret, yp_scope_node_t scope_node; yp_scope_node_init((yp_node_t *)module_node, &scope_node); - ID module_id = yp_constant_id_lookup(compile_context, module_node->name_constant); + ID module_id = yp_constant_id_lookup(compile_context, module_node->name); VALUE module_name = rb_str_freeze(rb_sprintf("<module:%"PRIsVALUE">", rb_id2str(module_id))); const rb_iseq_t *module_iseq = NEW_CHILD_ISEQ(&scope_node, module_name, ISEQ_TYPE_CLASS, lineno); |