https://gcc.gnu.org/bugzilla/show_bug.cgi?id=14319
Vincent Lefèvre <vincent-gcc at vinc17 dot net> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |vincent-gcc at vinc17 dot net --- Comment #17 from Vincent Lefèvre <vincent-gcc at vinc17 dot net> --- (In reply to Tim Rentsch from comment #10) > Four: Despite the last observation, the "one special guarantee" clause > (and hence also DR 257) is clearly not germane to this problem. The > reason for this is that the "one special guarantee" clause is concerned > with read access ("inspect" is the word used in the Standard), [...] In any case, the aliasing rule is only about read access: "An object shall have its stored value accessed only by [...]" (6.5#7). If you are accessing a stored value, this means that you are reading it. Thus the "yp->y = 1;" does not imply undefined behavior, in case this is what you were thinking about. Note: Forbidding write accesses with a different effective type would make "for subsequent accesses that do not modify the value" from 6.5#6 pointless.