You copied the Doc URL to your clipboard.

The __packed qualifier and unaligned data access in C and C++ code

The __packed qualifier sets the alignment of any valid type to 1.

This enables objects of packed type to be read or written using unaligned access.

Examples of objects that can be packed include:

  • Structures.

  • Unions.

  • Pointers.

Was this page helpful? Yes No