Just a simple question.
Is it guaranteed that the pointer to a structure always points to the structure's first member?
e.g.
Is it always true that &my_struct == &(my_struct.a) ?Code:struct {
data_type a;
data_type b;
...
} my_struct;
Just a simple question.
Is it guaranteed that the pointer to a structure always points to the structure's first member?
e.g.
Is it always true that &my_struct == &(my_struct.a) ?Code:struct {
data_type a;
data_type b;
...
} my_struct;
Yes it does.
The value may be correct, but the type will always be wrong.