#pragma sizeof
Go Up to Pragma Directives Overview Index
Contents
Syntax (See Pseudo-grammar)
#pragma sizeof( [{ struct | class | union }] SYM )
Description
#pragma sizeof prints the size of the aggregate.
Example
Source file
| file.cpp |
|---|
struct X {
};
#pragma sizeof(X)
// ...
|
Command line
> bcc32 -c file.cpp
Compiler output
The size of 'X' is 8 bytes (alignment 8)
See also
- SizeOf (in Delphi)