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: aliasing warnings [patch]


David Starner wrote:
> On Thu, Sep 16, 1999 at 09:37:29AM -0700, Zack Weinberg wrote:
> > 
> > The appended patch causes warnings to be generated, in
> > -fstrict-aliasing mode, when a pointer is cast to a type outside its
> > alias set.  char * and void * are excepted, as are casts from T to
> > union containing T; the latter is warned about anyway with -pedantic.
> 
> Is this patch (or another aliasing warning) going to be in GCC 2.95.n 
> (for some n >= 2)? If not, it seems like everyone's going to have to deal
> with this the hard way (either adding -fno-strict-aliasing or finding the
> bugs by hand.) 

I'd like to get some sort of aliasing warning into 2.95.n, but I don't
think this patch is ready to be it.

I'm generally opposed to the notion of attempting to fix up broken
code and/or turning off default -fstrict-aliasing.  However, we might
want to consider turning off strict aliasing with -traditional.

zw


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