This is the mail archive of the gcc-bugs@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]

[Bug c++/61007] New: New strict-aliasing warnings in 4.10.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=61007

            Bug ID: 61007
           Summary: New strict-aliasing warnings in 4.10.0
           Product: gcc
           Version: 4.10.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: larsbj at gullik dot net

Created attachment 32707
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=32707&action=edit
gzipped preprossed code showing the problem

In current trunk I get some new strict-aliasing warnings that I did
not get with 4.9.0.

Shown when compiling attached preprocessed code with:
(the operations.ii is from boost release 1.55, boost.filesystem)

g++ -O2 -Wall -Wno-unused -std=gnu++11 -c operations.ii

...
functional/boost/libs/filesystem/src/operations.cpp:343:40: warning:
dereferencing type-punned pointer will break strict-aliasing rules
[-Wstrict-aliasing]
     return fs::directory_iterator(p)== end_dir_itr;
                                        ^
...

$ g++ --version
g++ (GCC) 4.10.0 20140424 (experimental)


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