From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21267 invoked by alias); 24 Oct 2003 15:51:34 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 21251 invoked by uid 48); 24 Oct 2003 15:51:33 -0000 Date: Fri, 24 Oct 2003 15:51:00 -0000 From: "bangerth at dealii dot org" To: gcc-bugs@gcc.gnu.org Message-ID: <20031024155131.12762.bangerth@dealii.org> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug c++/12762] New: [3.4 regression] Much worse error message when using a typedef with a template arg X-Bugzilla-Reason: CC X-SW-Source: 2003-10/txt/msg02145.txt.bz2 List-Id: PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org. http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12762 Summary: [3.4 regression] Much worse error message when using a typedef with a template arg Product: gcc Version: 3.4 Status: UNCONFIRMED Keywords: diagnostic Severity: normal Priority: P2 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: bangerth at dealii dot org CC: gcc-bugs at gcc dot gnu dot org,gdr at gcc dot gnu dot org This came out of PR 12507. Consider this code: ------------------- template struct A { A() {}}; typedef A Ac; Ac a; ------------------- The fact the gcc3.3 accepts this is covered by PR 12507, but look at the error message from 3.2.3 and present mainline: g/x> /home/bangerth/bin/gcc-3.2.3/bin/c++ -c x.cc x.cc:3: non-template type `Ac' used as a template x.cc:3: ISO C++ forbids declaration of `a' with no type g/x> /home/bangerth/bin/gcc-3.4-pre/bin/c++ -c x.cc x.cc:3: error: expected unqualified-id x.cc:3: error: expected `,' or `;' This is definitely a regression in quality of error reporting. W.