The first named element of a structure is required to be located at the same address as the structure, yes; but I'm not aware of any requirement beyond that.
Can you point me at the relevant paragraph?
Can you point me at the relevant paragraph?
This is from the draft N1256 document as I don't have access to the official standard. From 6.2.5 - Types:
"A structure type describes a sequentially allocated nonempty set of member objects (and, in certain circumstances, an incomplete array), each of which has an optionally specified name and possibly distinct type"
I can say that a lot of device drivers in the Linux kernel depend on this ...
As for Linux device drivers... it wouldn't be the first time that the Linux kernel (and especially device drivers) assumed a certain compiler behaviour which wasn't guaranteed, with hilarious results on later compilers.