vendredi 24 novembre 2017

C++ Directive With void(0)

What is the purpose of having a directive like below?

#define TEST_CONDITION(con) !(con) ? (void)0:

In particular, I see this called at the start of other directives.

For example,

#define OTHER_CONDITION(..)
  TEST_CONDITION(someFunction)
  ANOTHER_DIRECTIVE(...)

Doesn't TEST_CONDITION just no-op or a boolean is returned that isn't used in these cases?

Aucun commentaire:

Enregistrer un commentaire