This is the mail archive of the
gcc-prs@gcc.gnu.org
mailing list for the GCC project.
c++/10555: [3.3/3.4 regression] ICE on undefined template argument
- From: reichelt at igpm dot rwth-aachen dot de
- To: gcc-gnats at gcc dot gnu dot org
- Date: 29 Apr 2003 20:00:00 -0000
- Subject: c++/10555: [3.3/3.4 regression] ICE on undefined template argument
- Reply-to: reichelt at igpm dot rwth-aachen dot de
>Number: 10555
>Category: c++
>Synopsis: [3.3/3.4 regression] ICE on undefined template argument
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: ice-on-illegal-code
>Submitter-Id: net
>Arrival-Date: Tue Apr 29 20:06:00 UTC 2003
>Closed-Date:
>Last-Modified:
>Originator: Volker Reichelt
>Release: 3.1 - 3.4-20030402
>Organization:
>Environment:
i686-pc-linux-gnu
>Description:
Consider the following code snippet:
-------------------------------snip here------------------------
template <typename> struct A
{
template <typename> struct B;
};
template <typename T> struct C
{
typedef typename A<T>::template B<U> X; // U is undefined
};
C<void> c;
-------------------------------snip here------------------------
PR8582D.cc:8: error: `U' has not been declared
PR8582D.cc: In instantiation of `C<void>':
PR8582D.cc:11: instantiated from here
PR8582D.cc:8: error: template argument 1 is invalid
PR8582D.cc:8: internal compiler error: tree check: expected tree_vec, have
error_mark in check_instantiated_args, at cp/pt.c:8403
Please submit a full bug report, [etc.]
This error recovery problem affects mainline, 3.3 branch and the 3.2 branch
(at least if configured with --enable-checking).
So it's a regression from 3.0.x.
>How-To-Repeat:
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted: