11.9.1 Packed Example

__pack_upper_byte char message[] = "Hello World!\n";

will allocate the message string into Flash memory in such a way that the upper byte of memory contains valid data.

There are no restrictions to the types of __pack_upper_byte data. The compiler will 'pack' structures as if __attribute__((packed)) had also been specified. This further eliminates wasted space due to padding.

Like other extended type qualifiers, the __pack_upper_byte type qualifier enforces a unique addressing space on the compiler; therefore, it is important to maintain this qualifier when passing values as parameters. Do not be tempted to cast away the __pack_upper_byte qualifier – it won't work.