Previous | Table of Contents | Next |
The basic data types available in OMG IDL map to the corresponding data types
available in Microsoft IDL as shown in Table 18-1.
Table 18-1 OMG IDL to MIDL Intrinsic Data Type Mappings
OMG IDL |
Microsoft IDL |
Microsoft ODL |
Description |
||
short | short | short | Signed integer with a range of -215...215 - 1 | ||
long | long | long | Signed integer with a range of -231...231 - 1 | ||
unsigned short | unsigned short | unsigned short | Unsigned integer with a range of 0...216 - 1 | ||
unsigned long | unsigned long | unsigned long | Unsigned integer with a range of 0...232 - 1 | ||
float | float | float | IEEE single-precision floating point number | ||
double | double | double | IEEE double-precision floating point number | ||
char | char | char | 8-bit quantity limited to the ISO Latin-1 character set | ||
wchar | WCHAR | WCHAR | wide character | ||
boolean | boolean | boolean | 8-bit quantity that is limited to 1 and 0 | ||
octet | byte | unsigned char | 8-bit opaque data type, guaranteed to not undergo any conversion during transfer between systems. |
Note – midl and mktyplib disagree about the size of boolean when used in an ODL specification. To avoid this ambiguity, we
make the mapping explicit and use the VARIANT BOOL type instead of the built-in boolean type.