]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
sim: igen: extend error to take arguments
authorMike Frysinger <vapier@gentoo.org>
Mon, 1 Jan 2024 22:28:51 +0000 (17:28 -0500)
committerMike Frysinger <vapier@gentoo.org>
Mon, 1 Jan 2024 22:31:12 +0000 (17:31 -0500)
The ppc igen error helper allows arbitrary printf calls, so extend
the common one to do the same.

sim/igen/misc.h

index eff8a203cabf0dc432edafc222f51fdacceff6c2..45610558a262a08944e96c503664bc9af854b2ca 100644 (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) \