What does this expression mean, and why does it compile? [duplicate]

It looks like this is a Visual C++ extension to support a particular ‘no function defined’ idiom. From the warning C4353 page:

// C4353.cpp
// compile with: /W1
void MyPrintf(void){};
#define X 0
#if X
   #define DBPRINT MyPrint
#else
   #define DBPRINT 0   // C4353 expected
#endif
int main(){
    DBPRINT();
}

the intention being that DBPRINT is a no-op. The warning suggests #define DBPRINT __noop instead, using VC’s __noop extension instead.

If you view the assembly listing for your output you’ll see the second clause is omitted, even in debug mode.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)