middle-end/10451: (3.2.2) ICE on mutable definitions of iterators
Giovanni Bajo
giovannibajo@libero.it
Tue Apr 22 14:36:00 GMT 2003
The following reply was made to PR middle-end/10451; it has been noted by GNATS.
From: "Giovanni Bajo" <giovannibajo@libero.it>
To: <gcc-gnats@gcc.gnu.org>,
<gcc-bugs@gcc.gnu.org>,
<mark.merriman@dc.alphatech.com>,
<nobody@gcc.gnu.org>,
<gcc-prs@gcc.gnu.org>
Cc: "Wolfgang Bangerth" <bangerth@ices.utexas.edu>
Subject: Re: middle-end/10451: (3.2.2) ICE on mutable definitions of iterators
Date: Tue, 22 Apr 2003 16:34:53 +0200
http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&p
r=10451
Reduced snippet is:
-----------------------------------------
struct Bar
{
typedef int type;
};
struct Foo
{
void func(void)
{
mutable Bar::type x;
}
};
-----------------------------------------
pr10451.cpp: In member function `void Foo::func()':
pr10451.cpp:10: Internal compiler error in grokdeclarator, at
cp/decl.c:11906
Please submit a full bug report,
The code is illegal, but we should not ICE anyway. This is a 3.2/3.3/3.4
regression wrt to 2.95 which was giving a normal error message.
For the original poster: your code is illegal because mutable may not be
used to define local variables.
Giovanni Bajo
More information about the Gcc-prs
mailing list