From c752222a285432bdd46e7b0096eb1fad6bd4eba0 Mon Sep 17 00:00:00 2001
From: 3gg <3gg@shellblade.net>
Date: Thu, 15 Jun 2023 19:37:31 -0700
Subject: Remove use of non-standard __VA_OPT__

---
 gfx/include/gfx/error.h | 18 ++++++++----------
 1 file changed, 8 insertions(+), 10 deletions(-)

diff --git a/gfx/include/gfx/error.h b/gfx/include/gfx/error.h
index dcb6932..062dba1 100644
--- a/gfx/include/gfx/error.h
+++ b/gfx/include/gfx/error.h
@@ -9,16 +9,14 @@ const char* gfx_get_error(void);
 extern xlstring gfx_error;
 
 /// Set the last error.
-#define gfx_set_error(FORMAT, ...) \
-  gfx_error.length = snprintf(     \
-      gfx_error.str, xlstring_size, FORMAT __VA_OPT__(, ) __VA_ARGS__)
+#define gfx_set_error(...) \
+  gfx_error.length = snprintf(gfx_error.str, xlstring_size, __VA_ARGS__)
 
 /// Prepend an error to the last error.
-#define gfx_prepend_error(FORMAT, ...)                                        \
-  {                                                                           \
-    xlstring head;                                                            \
-    head.length =                                                             \
-        snprintf(head.str, xlstring_size, FORMAT __VA_OPT__(, ) __VA_ARGS__); \
-    xlstring_append(&head, xlstring_make(": "));                              \
-    gfx_error = xlstring_concat(head, gfx_error);                             \
+#define gfx_prepend_error(...)                                    \
+  {                                                               \
+    xlstring head;                                                \
+    head.length = snprintf(head.str, xlstring_size, __VA_ARGS__); \
+    xlstring_append(&head, xlstring_make(": "));                  \
+    gfx_error = xlstring_concat(head, gfx_error);                 \
   }
-- 
cgit v1.2.3