This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: templates: crashes on ctor initting templated base class
- To: grg at ai dot mit dot edu, egcs-bugs at cygnus dot com
- Subject: Re: templates: crashes on ctor initting templated base class
- From: Kriang Lerdsuwanakij <lerdsuwa at scf-fs dot usc dot edu>
- Date: Mon, 28 Dec 1998 03:01:17 +0000
> This is starting to use some of the more advanced template options,
> so I'm not 100% sure of the syntax, but I think:
>
> class A;
> template<template<class Ignored> class base> class C :
> public base<A> {
> public:
> C(A& newa) : base<A>(newa) {}
> };
>
> ought to be correct. egcs crashes trying to call base(newa), and
> begs me to send this message to the list ("internal compiler error").
Thanks for the report. This is a known bug. A kludge that fixes the
problem can be found at
http://www.cygnus.com/ml/egcs-patches/1998-Aug/0215.html
A better way fix to the bug is not trivial and is not available yet.
--kriang