chiark / gitweb /
utils/macros.h: Support for compiler-specific annotations.
[mLib] / ui / report.h
index 90128fb247f9c52e7736153ac643f377b4022d3c..4266cc2f6bafb2158120917a5ef0df046976f8b4 100644 (file)
   extern "C" {
 #endif
 
+/*----- Header files ------------------------------------------------------*/
+
+#ifndef MLIB_MACROS_H
+#  include "macros.h"
+#endif
+
 /*----- Functions provided ------------------------------------------------*/
 
 /* --- @moan@ --- *
@@ -44,7 +50,8 @@
  * Use:                Reports an error.
  */
 
-extern void moan(const char *f, ...);
+extern void PRINTF_LIKE(1, 2)
+  moan(const char *f, ...);
 
 /* --- @die@ --- *
  *
@@ -58,7 +65,8 @@ extern void moan(const char *f, ...);
  *             permanent.
  */
 
-extern void die(int status, const char *f, ...);
+extern void PRINTF_LIKE(2, 3) NORETURN
+  die(int status, const char *f, ...);
 
 /*----- That's all, folks -------------------------------------------------*/