From: cuz Date: Thu, 14 Aug 2003 21:05:25 +0000 (+0000) Subject: Add gcc attributes X-Git-Tag: V2.12.0~1420 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=58e3d8c97cd62913388a09568943e3f5ae0787e1;p=cc65 Add gcc attributes git-svn-id: svn://svn.cc65.org/cc65/trunk@2314 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- diff --git a/src/co65/error.h b/src/co65/error.h index 9eab1e7ba..48ba30caf 100644 --- a/src/co65/error.h +++ b/src/co65/error.h @@ -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 */ diff --git a/src/co65/o65.c b/src/co65/o65.c index 976e23a70..5a14d17f9 100644 --- a/src/co65/o65.c +++ b/src/co65/o65.c @@ -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'); diff --git a/src/od65/error.h b/src/od65/error.h index f4dbf3fd4..af5c907fd 100644 --- a/src/od65/error.h +++ b/src/od65/error.h @@ -6,10 +6,10 @@ /* */ /* */ /* */ -/* (C) 1998-2000 Ullrich von Bassewitz */ -/* Wacholderweg 14 */ -/* D-70597 Stuttgart */ -/* EMail: uz@musoftware.de */ +/* (C) 1998-2003 Ullrich von Bassewitz */ +/* Römerstrasse 52 */ +/* D-70794 Filderstadt */ +/* EMail: uz@cc65.org */ /* */ /* */ /* This software is provided 'as-is', without any expressed or implied */ @@ -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 */