preprocessor

__attribute__((packed))

The __attribute__ keyword in GCC allows you to specify special attributes on variables, functions, and types — including struct and union definitions. It is a non-standard compiler extension that gives you fine-grained control over how the compiler handles memory layout, alignment, calling conventions, and more. This article focuses on one of its most commonly encountered […]