mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-27 05:22:07 +00:00
Allow BANK() in constexpr expressions
This commit is contained in:
@@ -1394,6 +1394,14 @@ const : T_ID { constexpr_Symbol(&$$, $1); }
|
||||
| T_NUMBER { constexpr_Number(&$$, $1); }
|
||||
| T_OP_HIGH '(' const ')' { constexpr_UnaryOp(&$$, $1, &$3); }
|
||||
| T_OP_LOW '(' const ')' { constexpr_UnaryOp(&$$, $1, &$3); }
|
||||
| T_OP_BANK '(' T_ID ')'
|
||||
{
|
||||
constexpr_BankSymbol(&$$, $3);
|
||||
}
|
||||
| T_OP_BANK '(' string ')'
|
||||
{
|
||||
constexpr_BankSection(&$$, $3);
|
||||
}
|
||||
| string
|
||||
{
|
||||
char *s = $1;
|
||||
|
||||
Reference in New Issue
Block a user