[Bug c++/83529] ICE in canonical types differ for identical types

nathan at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Wed Jan 3 17:40:00 GMT 2018


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83529

--- Comment #7 from Nathan Sidwell <nathan at gcc dot gnu.org> ---
int Foo (void *);

template <int> class TPL;

template <int I> TPL<Foo (I)> Baz ();

int Foo (float);

template <int I> TPL<Foo (I)> Baz ();

constexpr int Foo (int) {return 0;}int Foo (int);

A less templatey case.
83529.ii:6:26: error: call to non-'constexpr' function 'int Foo(void*)'
 template <int I> TPL<Foo (I)> Baz ();
                      ~~~~^~~
83529.ii:10:36: internal compiler error: canonical types differ for identical
types 'TPL<Foo(I)>' and 'TPL<Foo(I)>'


More information about the Gcc-bugs mailing list