mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 18:22:07 +00:00
Fix org location being undefined when incorrect
This commit is contained in:
@@ -1443,10 +1443,12 @@ sectiontype : T_SECT_WRAM0 { $$ = SECTTYPE_WRAM0; }
|
|||||||
sectorg : { $$ = -1; }
|
sectorg : { $$ = -1; }
|
||||||
| '[' uconst ']'
|
| '[' uconst ']'
|
||||||
{
|
{
|
||||||
if ($2 < 0 || $2 >= 0x10000)
|
if ($2 < 0 || $2 >= 0x10000) {
|
||||||
yyerror("Address $%x is not 16-bit", $2);
|
yyerror("Address $%x is not 16-bit", $2);
|
||||||
else
|
$$ = -1;
|
||||||
|
} else {
|
||||||
$$ = $2;
|
$$ = $2;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user