diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index a405a9114eb..9b6bcdcbd88 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,8 @@ 2002-09-16 Nathan Sidwell + PR c++/7718 + * pt.c (tsubst_decl): Remove assert. + Remove DR 295 implementation. * pt.c (check_cv_quals_for_unify): Disable function & method cases. * tree.c (cp_build_qualified_type_real): Likewise. Don't warn diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index 86b3fc20d8e..64696bcdbc9 100644 --- a/gcc/cp/pt.c +++ b/gcc/cp/pt.c @@ -5694,8 +5694,6 @@ tsubst_decl (t, args, type, complain) tree r = NULL_TREE; tree in_decl = t; - my_friendly_assert (complain & tf_error, 20011214); - /* Set the filename and linenumber to improve error-reporting. */ saved_lineno = lineno; saved_filename = input_filename; diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index e399a34b141..63b882ffbae 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,9 +1,17 @@ +2002-09-16 Nathan Sidwell + + * g++.dg/template/subst1.C: New test. + 2002-09-16 Steve Ellcey * gcc.dg/20020312-2.c: Change __parisc__ to __hppa__. 2002-09-16 Nathan Sidwell + * g++.dg/template/qualttp20.C: Adjust expected errors. + * g++.old-deja/g++.jason/report.C: Likewise. + * g++.old-deja/g++.other/qual1.C: Likewise. + * g++.dg/lookup/scoped2.C: New test. * g++.dg/ext/asm3.C: New test. diff --git a/gcc/testsuite/g++.dg/template/subst1.C b/gcc/testsuite/g++.dg/template/subst1.C new file mode 100644 index 00000000000..827af23d21e --- /dev/null +++ b/gcc/testsuite/g++.dg/template/subst1.C @@ -0,0 +1,27 @@ +// { dg-do compile } + +// Copyright (C) 2002 Free Software Foundation, Inc. +// Contributed by Nathan Sidwell 16 Sep 2002 + +// PR 7718. ICE. + +template +void default_initializer(const OBJECT &) { } + + +template +class cContainer { + public: + template + void Add(const INITIALIZER &initializer) { + init_function(initializer); + } +}; + +int main() { + cContainer > c; + + c.Add(42); + + return 0; +}