This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Clarification anyone? -- was Re: Linux and aliasing?


>>>>> "Nick" == Nick Ing-Simmons <nik@tiuk.ti.com> writes:

    Nick> I assume unions are exempt from this?

Somewhat.  Please see the manual section I just posted for more
information. 

    Nick> What is proposed is that any mem-assign can be considered to
    Nick> "clobber" any value of the same type, and an assign via a
    Nick> char * to clobber anything ?

Right.

    Nick> And thus problem is that if I do this:

    Nick> int a; *((short *) &a) = 123;

    Nick> Then 'a' is not considered clobbered?

Right.

    Nick> Even in the same function?

Right.

--
Mark Mitchell                   mark@codesourcery.com
CodeSourcery, LLC               http://www.codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]