mirror of
https://github.com/cc65/cc65.git
synced 2024-06-19 14:29:40 +00:00
Parse file included inside a macro at definition time
This commit is contained in:
parent
8e02f8f5ec
commit
b9a3c78888
|
@ -510,6 +510,22 @@ void MacDef (unsigned Style)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (CurTok.Tok == TOK_INCLUDE) {
|
||||||
|
/* Include another file */
|
||||||
|
NextTok ();
|
||||||
|
/* Name must follow */
|
||||||
|
if (CurTok.Tok != TOK_STRCON) {
|
||||||
|
ErrorSkip ("String constant expected");
|
||||||
|
} else {
|
||||||
|
SB_Terminate (&CurTok.SVal);
|
||||||
|
if (NewInputFile (SB_GetConstBuf (&CurTok.SVal)) == 0) {
|
||||||
|
/* Error opening the file, skip remainder of line */
|
||||||
|
SkipUntilSep ();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
NextTok ();
|
||||||
|
}
|
||||||
|
|
||||||
/* Check for a .LOCAL declaration */
|
/* Check for a .LOCAL declaration */
|
||||||
if (CurTok.Tok == TOK_LOCAL && Style == MAC_STYLE_CLASSIC) {
|
if (CurTok.Tok == TOK_LOCAL && Style == MAC_STYLE_CLASSIC) {
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user