1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Suppress redefinition warnings of GET_SELF()

This commit is contained in:
Nobuyoshi Nakada 2021-08-30 09:06:36 +09:00
parent 2d93b523e1
commit 26e74c6b1f
No known key found for this signature in database
GPG key ID: 7CD2805BFA3770C6

View file

@ -348,6 +348,7 @@ mjit_compile_body(FILE *f, const rb_iseq_t *iseq, struct compile_status *status)
fprintf(f, " static const VALUE *const original_body_iseq = (VALUE *)0x%"PRIxVALUE";\n",
(VALUE)body->iseq_encoded);
fprintf(f, " VALUE cfp_self = reg_cfp->self;\n"); // cache self across the method
fprintf(f, "#undef GET_SELF\n");
fprintf(f, "#define GET_SELF() cfp_self\n");
// Generate merged ivar guards first if needed