I am trying to define a generic macro, which I intend to use with exception handling while debugging the code. When I try to compile the code below, it says typename not allowed.
I am a noob when it comes to the macros, any and all help is highly appreciated.
#define ASSERTEXCP(x) _Generic((x),\
char *: printf( "assertion error line %d, file(%s):-> %s\n", __LINE__, __FILE__, x );
char strMsg[2014] = {'\0'}; \
sprintf(strMsg, "\nassertion error line %d, file(%s):-> %s\n", __LINE__, __FILE__, x); \
OutputDebugString(strMsg););
#endif