|
-
April 6th, 1999, 02:51 PM
#1
#pragma pack(): Is it Microsoft compiler dependent?
Is the preprocessor command:
#pragma pack(...)
A Microsoft compiler dependant command? I looked through the help and couldn't really find out for sure.
I'm making a DLL which will use a struct data type. The struct will be declared in a header file which will be used by the DLL project itself and programs using the DLL.
I want to make sure that the other programs compile the structure under the same packing style. If all programs were using Microsoft VC++ compilers, I could use #pragma pack(16).
However, some programs might be using a different compiler. So putting #pragma pack(16) in the header would confuse the other compiler.
If there is something else besides #pragma pack which ensures a specific structure layout over all compilers, I'd love to know it.
Thanks
Steve
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|