This documentation is archived and is not being maintained.

Compiler Error C2714

__alignof(void) is not allowed

An invalid value was passed to an operator.

See __alignof Operator for more information.

The following sample generates C2714.

// C2714.cpp
int main() {
   return __alignof(void);   // C2714
   return __alignof(char);   // OK
}
Show: