tech-userlevel archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: style: structures
On Tue, Oct 08, 2024 at 10:06:39AM +0200, tlaronde%kergis.com@localhost wrote:
> Shouldn't an exception been mentionned concerning structures that may be
> derived from a base structure, so that the first member of the derived
> structures is a base structure, using the C standard guaranteed property
> that the address of the first member is the address of the structure,
> allowing to cast pointers in order to operate whether on the base
> structure or on the derived structure?
Not sure this needs an explicit exception in the style rules. It is a
technical necessarity and requires a comment when it is used.
Martin
Home |
Main Index |
Thread Index |
Old Index