g++-980308: New problem with template template parameters :-(
Bernd Nottelmann
nottelm@ptp283.uni-muenster.de
Wed Mar 11 06:58:00 GMT 1998
Hi,
I have applied your (Kriangôs) patch and the example program
which I sent compiles fine. But now I have a new problem -
it is relating to mixing of template template parameters and
the member template feature of the new g++. Here is the example
code:
/*-------------------------bug2.C-------------------------*/
template < class T, template < class > class E1, template < class > class E2 >
class Add {
public:
Add(const E1<T>& e1, const E2<T>& e2) {}
};
template < class T >
struct Id {
template < template < class > class E >
Add < T, Id, E > operator+(const E<T>& e) const {
return Add < T, Id, E >(*this, e);
}
};
template struct Id<double>;
/*--------------------------------------------------------*/
# g++ -c bug2.C
bug2.C:15: Internal compiler error.
bug2.C:15: Please submit a full bug report to `egcs-bugs@cygnus.com'.
Bernd
More information about the Gcc-bugs
mailing list