Can someone explain to me what this code means
This is from a tutorial I'm reading
I'm not exactly sure what it means...'byte align structures' ?
// byte-align structures
# pragma pack( push, packing )
# pragma pack( 1 )
# define PACK_STRUCT
#elif defined( __GNUC__ )
# define PACK_STRUCT __attribute__((packed))
# error you must byte-align these structures with the appropriate compiler directives
Is this for like determining an operating system or something?
It would be cool if you could explain what each line means, not just explain what the general purpose is.