R
Russell Shaw
Hi,
I have a variadic macro:
#define throw(msg, ...) excep_throw(msg, __VA_ARGS__)
If i do: throw("Error", 0), it compiles ok.
If i do: throw("Error"), i get an error:
error: parse error before ')' token
I think it's because without the last parameter, the function is
called as: except_throw("Error", ). How do i get rid of this trailing
comma problem?
I'm using gcc-3.4.4.
void excep_throw(char *msg, ...)
{
...
}
I have a variadic macro:
#define throw(msg, ...) excep_throw(msg, __VA_ARGS__)
If i do: throw("Error", 0), it compiles ok.
If i do: throw("Error"), i get an error:
error: parse error before ')' token
I think it's because without the last parameter, the function is
called as: except_throw("Error", ). How do i get rid of this trailing
comma problem?
I'm using gcc-3.4.4.
void excep_throw(char *msg, ...)
{
...
}