mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-24 03:52:08 +00:00
Implement ALIGN keyword in rgbasm
The ALIGN keyword specifies the number of bits that should be zero at the start of a section. It works in a simliar fashion to BANK.
This commit is contained in:
@@ -631,7 +631,10 @@ out_NewAbsSection(char *pzName, ULONG secttype, SLONG org, SLONG bank)
|
||||
void
|
||||
out_NewAlignedSection(char *pzName, ULONG secttype, SLONG alignment, SLONG bank)
|
||||
{
|
||||
out_SetCurrentSection(out_FindSection(pzName, secttype, -1, bank, alignment));
|
||||
if (alignment < 0) {
|
||||
yyerror("Alignment must not be negative.");
|
||||
}
|
||||
out_SetCurrentSection(out_FindSection(pzName, secttype, -1, bank, 1 << alignment));
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user