]> git.sur5r.net Git - cc65/blobdiff - src/common/xsprintf.h
Only for jumps, the lib uses named asm labels in branches
[cc65] / src / common / xsprintf.h
index 2758e5bc22a2523d76262a29e50953bf2fc2b587..a37b71914b100c80a31873106324b03c71abba30 100644 (file)
 
 
 /* We need a way to output a StrBuf, but on the other side, we don't want to 
- * switch off gcc's printf format string checking. So we cheat as follows: 
- * %m (which is a gcc extension and doesn't take an argument) switches %p 
- * between outputting a pointer and a string buf. This works just one time,
- * so each StrBuf needs in fact a %m%p spec. There's no way to apply a width
- * and precision to such a StrBuf, but *not* using %p would bring up a warning
- * about a wrong argument type each time. Maybe gcc will one day allow custom
- * format specifiers and we can change this ...
- * However this cheat doesn't work with MinGW as there's no support for %m :-(
- */
-#if defined( __MINGW32__)
-#  pragma GCC diagnostic ignored "-Wformat"
-#endif
+** switch off gcc's printf format string checking. So we cheat as follows: 
+** %m (which is a gcc extension and doesn't take an argument) switches %p 
+** between outputting a pointer and a string buf. This works just one time,
+** so each StrBuf needs in fact a %m%p spec. There's no way to apply a width
+** and precision to such a StrBuf, but *not* using %p would bring up a warning
+** about a wrong argument type each time. Maybe gcc will one day allow custom
+** format specifiers and we can change this ...
+*/
 
 
 
 int xvsnprintf (char* Buf, size_t Size, const char* Format, va_list ap)
         attribute ((format (printf, 3, 0)));
 /* A basic vsnprintf implementation. Does currently only support integer
- * formats.
- */
+** formats.
+*/
 
 int xsnprintf (char* Buf, size_t Size, const char* Format, ...)
         attribute ((format (printf, 3, 4)));
 /* A basic snprintf implementation. Does currently only support integer
- * formats.
- */
+** formats.
+*/
 
 int xsprintf (char* Buf, size_t BufSize, const char* Format, ...)
         attribute ((format (printf, 3, 4)));
@@ -92,7 +88,3 @@ int xvsprintf (char* Buf, size_t BufSize, const char* Format, va_list ap)
 /* End of xsprintf.h */
 
 #endif
-
-
-
-