Use the common ansidecl.h macros to replace our ad-hoc printf attributes.
+2021-06-16 Mike Frysinger <vapier@gentoo.org>
+
+ * cpu.h: Include ansidecl.h.
+ (cpu_error): Change __attribute__ ((format (printf... to
+ ATTRIBUTE_PRINTF_3.
+ * device.h (device_error): Change __attribute__ ((format (printf...
+ to ATTRIBUTE_PRINTF_2.
+ * lf.h: Include ansidecl.h.
+ (lf_printf): Change __attribute__ ((format (printf... to
+ ATTRIBUTE_PRINTF_2.
+ * sim_callbacks.h (sim_io_printf_filtered): Change __attribute__
+ ((format (printf... to ATTRIBUTE_PRINTF_1.
+ * tree.h (tree_parse): Change __attribute__ ((format (printf... to
+ ATTRIBUTE_PRINTF_2.
+
2021-06-16 Mike Frysinger <vapier@gentoo.org>
* double.c: Include ansidecls.h.
#include "os_emul.h"
#include "mon.h"
#include "model.h"
+#include "ansidecl.h"
#include "libiberty.h"
#ifndef CONST_ATTRIBUTE
(cpu *processor,
unsigned_word cia,
const char *fmt,
- ...) __attribute__ ((format (printf, 3, 4)));
+ ...) ATTRIBUTE_PRINTF_3;
/* The processors local concept of time */
(void) device_error
(device *me,
const char *fmt,
- ...) __attribute__ ((format (printf, 2, 3)));
+ ...) ATTRIBUTE_PRINTF_2;
INLINE_DEVICE\
(int) device_trace
/* LF: Line Numbered Output Stream */
+#include "ansidecl.h"
+
typedef struct _lf lf;
typedef enum {
extern int lf_printf
(lf *file,
const char *fmt,
- ...) __attribute__((format(printf, 2, 3)));
+ ...) ATTRIBUTE_PRINTF_2;
/* Indentation control.
#define printf_filtered sim_io_printf_filtered
void sim_io_printf_filtered
-(const char *msg, ...) __attribute__ ((format (printf, 1, 2)));
+(const char *msg, ...) ATTRIBUTE_PRINTF_1;
void ATTRIBUTE_NORETURN error
(const char *msg, ...);
(device *) tree_parse
(device *root,
const char *fmt,
- ...) __attribute__ ((format (printf, 2, 3)));
+ ...) ATTRIBUTE_PRINTF_2;
INLINE_TREE\