sim: igen: extend error to take arguments

The ppc igen error helper allows arbitrary printf calls, so extend
the common one to do the same.
This commit is contained in:
Mike Frysinger 2024-01-01 17:28:51 -05:00
parent 9b6e0cb3ba
commit ef993dfa05

View File

@ -56,12 +56,12 @@ extern error_func warning;
extern error_func notify;
#define ERROR(EXPRESSION) \
#define ERROR(EXPRESSION, args...) \
do { \
line_ref line; \
line.file_name = filter_filename (__FILE__); \
line.line_nr = __LINE__; \
error (&line, EXPRESSION "\n"); \
error (&line, EXPRESSION "\n", ## args); \
} while (0)
#define ASSERT(EXPRESSION) \