mruby-compiler: replace MRB_SYM_2() with MRB_SYM() macros

The _2 suffix variants accept an mrb_state* parameter that is
always ignored with presym enabled. Replace all uses in codegen.c,
parse.y, and y.tab.c with the standard macros. The _2 macro
definitions are kept in presym headers for backward compatibility.

Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
Yukihiro "Matz" Matsumoto
2026-02-19 14:14:40 +09:00
parent bd4f380178
commit dcd77f1efd
7 changed files with 86 additions and 82 deletions
+1
View File
@@ -18,6 +18,7 @@
#define MRB_SYM_E(name) MRB_SYM_E__##name
#define MRB_SYM(name) MRB_SYM__##name
/* backward compatibility: _2 variants accept but ignore mrb_state* */
#define MRB_OPSYM_2(mrb, name) MRB_OPSYM__##name
#define MRB_GVSYM_2(mrb, name) MRB_GVSYM__##name
#define MRB_CVSYM_2(mrb, name) MRB_CVSYM__##name