mirror of
https://github.com/cc65/cc65.git
synced 2025-01-12 17:30:50 +00:00
Allow switching warnings about unused pragmas on or off.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4366 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
62fdd55fee
commit
d9753c2eb7
@ -174,7 +174,7 @@ static int GetComma (StrBuf* B)
|
||||
Error ("Comma expected");
|
||||
return 0;
|
||||
}
|
||||
SB_SkipWhite (B);
|
||||
SB_SkipWhite (B);
|
||||
return 1;
|
||||
}
|
||||
|
||||
@ -675,10 +675,11 @@ static void ParsePragma (void)
|
||||
/* Do we know this pragma? */
|
||||
if (Pragma == PRAGMA_ILLEGAL) {
|
||||
/* According to the ANSI standard, we're not allowed to generate errors
|
||||
* for unknown pragmas, however, we're allowed to warn - and we will
|
||||
* do so. Otherwise one typo may give you hours of bug hunting...
|
||||
* for unknown pragmas, but warn about them if enabled (the default).
|
||||
*/
|
||||
Warning ("Unknown pragma `%s'", SB_GetConstBuf (&Ident));
|
||||
if (IS_Get (&WarnUnknownPragma)) {
|
||||
Warning ("Unknown pragma `%s'", SB_GetConstBuf (&Ident));
|
||||
}
|
||||
goto ExitPoint;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user