2 ms·
It works because C structs are just contiguous bits of memory, interpreted as various fields Well... almost. C structs can have internal padding -- but the C
by cperciva 17y ago
It works because C structs are just contiguous bits of memory, interpreted as various fields
Well... almost. C structs can have internal padding -- but the C standard doesn't allow padding before the first element, so that first element is guaranteed to begin at the beginning of the struct.
- mhansen 17y agoThanks! You learn something every day :)