c++/10385: Internal compiler error in build_up_reference, at cp/cvt.c:353

Giovanni Bajo giovannibajo@libero.it
Sat Apr 12 17:26:00 GMT 2003


The following reply was made to PR c++/10385; it has been noted by GNATS.

From: "Giovanni Bajo" <giovannibajo@libero.it>
To: <gcc-gnats@gcc.gnu.org>,
	<gcc-bugs@gcc.gnu.org>,
	<nobody@gcc.gnu.org>,
	<gcc-prs@gcc.gnu.org>,
	<douglas@coc.ufrj.br>
Cc: "Wolfgang Bangerth" <bangerth@ices.utexas.edu>
Subject: Re: c++/10385: Internal compiler error in build_up_reference, at cp/cvt.c:353
Date: Sat, 12 Apr 2003 19:21:37 +0200

 http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&p
 r=10385
 
 Confirmed on GCC 3.2, 3.2.2 and 3.3 20030401. Reduced testcase is:
 
 -------------------------------------------------
 struct Foo {};
 
 struct Bar
 {
     void func(void);
 };
 
 Bar& GetBar(void);
 
 int main()
 {
     dynamic_cast<Foo&>( GetBar().func )
 }
 --------------------------------------------------
 pr10385.cpp: In function `int main()':
 pr10385.cpp:13: internal compiler error: in build_up_reference, at
 cp/cvt.c:356
 Please submit a full bug report,
 
 GCC 2.95.3 gives the following error message:
 
 pr10385.cpp:13: sorry, not implemented: `overload' not supported by
 dump_expr
 pr10385.cpp: In function `int main()':
 pr10385.cpp:13: cannot dynamic_cast `GetBar()->{error}' (of type `{unknown
 type}
 ') to type `struct Foo &'
 pr10385.cpp:14: parse error before `}'
 
 The error message we get on 2.95 (even though it is not complete due to the
 'error' and 'unknown type') gives some clue about what's wrong with the
 code, so I'd still rate it as a 3.2/3.3 regression. Somebody should check it
 on 3.4 (mainline broken on cygwin).
 
 The code is obviously illegal, fixing it makes the ICE disappear.
 
 Giovanni Bajo
 



More information about the Gcc-prs mailing list