P99

◆ P99_SIZE_CHOICE

#define P99_SIZE_CHOICE (   UI,
  YES,
  NO,
  ... 
)

Classify expression UI according to its value and return YES if the value is in the list and NO, otherwise.

UI is evaluated only at compile time and the resulting value is cast to size_t. It must not be 0.

YES and NO are evaluated at most once.

Warning
The range of allowed values for UI is platform dependent. The only known fixed guarantee is UINT16_MAX, but the result of a sizeof operator should always work.

Definition at line 835 of file p99_generic.h.