Add gcc attributes

git-svn-id: svn://svn.cc65.org/cc65/trunk@2314 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz
2003-08-14 21:05:25 +00:00
parent 73ab1ef8a9
commit 58e3d8c97c
3 changed files with 12 additions and 10 deletions

View File

@@ -52,10 +52,10 @@
void Warning (const char* Format, ...) attribute((format(printf,1,2)));
/* Print a warning message */
void Error (const char* Format, ...) attribute((format(printf,1,2)));
void Error (const char* Format, ...) attribute((noreturn, format(printf,1,2)));
/* Print an error message and die */
void Internal (const char* Format, ...) attribute((format(printf,1,2)));
void Internal (const char* Format, ...) attribute((noreturn, format(printf,1,2)));
/* Print an internal error message and die */

View File

@@ -187,7 +187,8 @@ static O65Import* ReadO65Import (FILE* F)
do {
C = Read8 (F);
if (Len >= sizeof (Buf)) {
Error ("Imported identifier exceeds maximum size (%u)", sizeof (Buf));
Error ("Imported identifier exceeds maximum size (%u)",
(unsigned) sizeof (Buf));
}
Buf[Len++] = C;
} while (C != '\0');
@@ -281,7 +282,8 @@ static O65Export* ReadO65Export (FILE* F, const O65Header* H)
do {
C = Read8 (F);
if (Len >= sizeof (Buf)) {
Error ("Exported identifier exceeds maximum size (%u)", sizeof (Buf));
Error ("Exported identifier exceeds maximum size (%u)",
(unsigned) sizeof (Buf));
}
Buf[Len++] = C;
} while (C != '\0');