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]
Other format: [Raw text]

Re: [PATCH] C undefined behavior fix


<<> Why not?  It documents that You Can't Do That.

But that's against the C standard.

You _can_ cast a integer to a pointer and expect some defined meaning for
it.
>>

Once again, this unsupported statement that simply makes no sense.
Of course the meaning is defined in GCC, it is defined by the gcc coding,
this will tell you EXACTLY what to expect. 

The idea that the C standard is requiring some simple semantics is wrong,
and the idea that the C standard is requiring the simple semantics that
YOU want is even wronger.

This is an old area of argument between those who make language standards
and those who code in the trenches. One of the measures of success of a 
language standard is the extent to which it can narrow this gap. Clearly
the C standard has not done so well here so far :-)


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