mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-23 11:32:07 +00:00
Separate errors that shouldn't have been combined in the first place.
This commit is contained in:
@@ -504,9 +504,12 @@ void
|
|||||||
checkcodesection(SLONG size)
|
checkcodesection(SLONG size)
|
||||||
{
|
{
|
||||||
checksection();
|
checksection();
|
||||||
if ((pCurrentSection->nType == SECT_ROM0
|
if (pCurrentSection->nType != SECT_ROM0 &&
|
||||||
|| pCurrentSection->nType == SECT_ROMX)
|
pCurrentSection->nType != SECT_ROMX) {
|
||||||
&& (pCurrentSection->nPC + size <= MAXSECTIONSIZE)) {
|
errx(1, "Section '%s' cannot contain code or data (not a "
|
||||||
|
"ROM0 or ROMX)", pCurrentSection->pzName);
|
||||||
|
}
|
||||||
|
if (pCurrentSection->nPC + size <= MAXSECTIONSIZE) {
|
||||||
if (((pCurrentSection->nPC % SECTIONCHUNK) >
|
if (((pCurrentSection->nPC % SECTIONCHUNK) >
|
||||||
((pCurrentSection->nPC + size) % SECTIONCHUNK))
|
((pCurrentSection->nPC + size) % SECTIONCHUNK))
|
||||||
&& (pCurrentSection->nType == SECT_ROM0
|
&& (pCurrentSection->nType == SECT_ROM0
|
||||||
@@ -523,8 +526,7 @@ checkcodesection(SLONG size)
|
|||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
} else
|
} else
|
||||||
fatalerror
|
errx(1, "Section '%s' is too big", pCurrentSection->pzName);
|
||||||
("Section can't contain initialized data or section limit exceeded");
|
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
* RGBAsm - OUTPUT.C - Outputs an objectfile
|
* RGBAsm - OUTPUT.C - Outputs an objectfile
|
||||||
|
|||||||
Reference in New Issue
Block a user