c++/7295: GCC 3.1 problem with templates
vincent.lascaux@ifrance.com
vincent.lascaux@ifrance.com
Fri Jul 12 14:16:00 GMT 2002
>Number: 7295
>Category: c++
>Synopsis: GCC 3.1 problem with templates
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: unassigned
>State: open
>Class: rejects-legal
>Submitter-Id: net
>Arrival-Date: Fri Jul 12 14:16:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator: Vincent Lascaux
>Release: gcc version 3.1
>Organization:
>Environment:
winXP
>Description:
The following code leads to an "internal error"
main.cpp:
---------
template<template<class A> class CContainer>
struct CFoo
{
typedef int i;
CContainer<int> Foo;
};
template<class B>
struct CTest
{
template<class A> struct value {};
CFoo<value>::i CFooI;
};
int main() {}
g++ main.cpp
main.cpp: In instantiation of `CFoo<CTest<B>::value>':
main.cpp:11: instantiated from here
main.cpp:3: internal error: Segmentation fault
>How-To-Repeat:
Compile the code
>Fix:
If you find one, please, tell me :)
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the Gcc-prs
mailing list