This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/12170] ICE in cp_type_quals
- From: "bangerth at dealii dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 5 Sep 2003 23:45:53 -0000
- Subject: [Bug c++/12170] ICE in cp_type_quals
- References: <20030904162242.12170.dave@boost-consulting.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12170
bangerth at dealii dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2003-09-05 23:45:52
date| |
Summary|Internal compiler error |ICE in cp_type_quals
------- Additional Comments From bangerth at dealii dot org 2003-09-05 23:45 -------
OK, here's a reduced testcase (that was tough...):
-------------------------
template <typename> struct W {};
template< template<typename> class F, typename T>
int foo(W< F<T> >);
template<typename T>
struct L {
static int const value = sizeof(foo(W<T>()));
typedef T type;
};
template <typename>
struct Y {
template <typename> struct X { typedef int type; };
typedef typename L<X<int> >::type type;
};
template struct Y<int>;
-----------------------------
This crashes all compiles I have, since 2.95. With 3.3 and 3.4 we get:
g/x> /home/bangerth/bin/gcc-3.3*-pre/bin/c++ -c z.cc
z.cc: In instantiation of `L<Y<int>::X<int> >':
z.cc:17: instantiated from `Y<int>'
z.cc:20: instantiated from here
z.cc:9: internal compiler error: tree check: expected class 't', have 'x' (
tree_vec) in cp_type_quals, at cp/typeck.c:6597
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
g/x> /home/bangerth/bin/gcc-3.4*-pre/bin/c++ -c z.cc
z.cc: In instantiation of `L<Y<int>::X<int> >':
z.cc:17: instantiated from `Y<int>'
z.cc:20: instantiated from here
z.cc:9: internal compiler error: tree check: expected class 't', have 'x'
(tree_vec) in cp_type_quals, at cp/typeck.c:6111
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
W.