Variadic macros issue with FW_ASSERT #2409
Unanswered
JackNWhite
asked this question in
Q&A
Replies: 1 comment
-
Correct, you cannot build F' with I think it's worth revisiting how F' does assertions, but I'm not sure anyone has identified a better solution than variadic macros yet. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
If you have built F' with the
-pedantic
option in GCC, you will have fallen foul of the following error, in many places:This is because the macro is defined thus:
#define FW_ASSERT(cond, ...)
Standard C++ prior to C++ 20 requires that at least one thing be passed as the variable argument list (
...
), but most uses of the macro in F' don't do that.Using the
-Wno-variadic-macros
hasn't worked for me (g++ 11.4.0). Has anyone been able to overcome this difficulty?Beta Was this translation helpful? Give feedback.
All reactions