[Bug c++/26571] New: [4.0/4.1/4.2 regression] Bad diagnostic using type modifier with struct

reichelt at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Mon Mar 6 02:56:00 GMT 2006


The invalid testcase

===============================
struct A {};
unsigned A a;
===============================

triggers the following bogus error message since GCC 3.4.0:

  bug.cc:2: error: 'A' does not name a type

The error message before wasn't very helpful

  bug.cc:2: error: syntax error before `;' token

but at least it wasn't plain wrong.
So I rate this as a regression.


-- 
           Summary: [4.0/4.1/4.2 regression] Bad diagnostic using type
                    modifier with struct
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Keywords: diagnostic, monitored
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: reichelt at gcc dot gnu dot org


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



More information about the Gcc-bugs mailing list