This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/12160] New: [3.4 regression] confusing error message with invalid function declaration
- From: "bangerth at dealii dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 3 Sep 2003 22:44:23 -0000
- Subject: [Bug c++/12160] New: [3.4 regression] confusing error message with invalid function declaration
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12160
Summary: [3.4 regression] confusing error message with invalid
function declaration
Product: gcc
Version: 3.4
Status: UNCONFIRMED
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
This is totally useless:
-----------------------------------
struct X {
virtual void f(int,
itn, // typo
int);
};
-----------------------------------
>> ~/bin/gcc-3.3/bin/c++ -c x.cc
x.cc:3: error: type specifier omitted for parameter `itn'
>> ~/bin/gcc-3.4/c++ -c x.cc
x.cc:2: error: variable or field `f' declared void
x.cc:2: error: `f' declared as a `virtual' field
x.cc:2: error: expected function-definition
The error message is completely unreadable and doesn't reveal where the problem
really is. It doesn't say which parameter is misspelled, and if the parameter list
is long and contains lots of templates and incomplete types, it doesn't help to
to fix the problem.
I rate this as a regression.
W.