Allow the index of CHARVAL to be optional

Fixes #1773
This commit is contained in:
Rangi42
2025-08-03 08:44:06 -04:00
parent 543b7fa6c2
commit fc9b614225
6 changed files with 33 additions and 7 deletions

View File

@@ -1527,6 +1527,9 @@ relocexpr_no_str:
| OP_CHARVAL LPAREN string COMMA iconst RPAREN {
$$.makeNumber(act_CharVal($3, $5));
}
| OP_CHARVAL LPAREN string RPAREN {
$$.makeNumber(act_CharVal($3));
}
| OP_STRBYTE LPAREN string COMMA iconst RPAREN {
$$.makeNumber(act_StringByte($3, $5));
}