cp-tree.h (PROCESSING_REAL_TEMPLATE_DECL_P): New macro.
authorMark Mitchell <mark@markmitchell.com>
Fri, 31 Jul 1998 15:01:21 +0000 (15:01 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Fri, 31 Jul 1998 15:01:21 +0000 (15:01 +0000)
commit39c01e4c532100e8e5239591146eec1b20593547
treecde82810bdca623c7d1ae0769916edf5170cd355
parent5f97de0ac982f8439ca78db6652fb722fe4fafe9
cp-tree.h (PROCESSING_REAL_TEMPLATE_DECL_P): New macro.

1998-07-31  Mark Mitchell  <mark@markmitchell.com>
* cp-tree.h (PROCESSING_REAL_TEMPLATE_DECL_P): New macro.
(maybe_check_template_type): New function.
* decl.c (maybe_process_template_type_declaration): New function,
split out from pushtag  Call maybe_check_template_type.
(pushtag): Use it.  Use PROCESSING_REAL_TEMPLATE_DECL_P.
(xref_tag): Use PROCESSING_REAL_TEMPLATE_DECL_P.
* friend.c (do_friend): Use PROCESSING_REAL_TEMPLATE_DECL_P.
* pt.c (template_class_depth_real): Generalization of ...
(template_class_depth): Use it.
(register_specialization): Use duplicate_decls for duplicate
declarations of specializations.
(maybe_check_template_type): New function.
(push_template_decl_real): Fix comment.
(convert_nontype_argument): Likewise.
(lookup_template_class): Likewise.  Avoid an infinite loop on
erroneous code.
(tsubst_friend_function): Fix comment.
(tsubst, case FUNCTION_DECL): Deal with a DECL_TI_TEMPLATE that is
an IDENTIFIER_NODE.
* semantics.c (begin_function_definition): Use
reset_specialization to note that template headers don't apply
directly to declarations after the opening curly for a function.

From-SVN: r21505
gcc/cp/ChangeLog
gcc/cp/cp-tree.h
gcc/cp/decl.c
gcc/cp/friend.c
gcc/cp/pt.c
gcc/cp/semantics.c
gcc/testsuite/g++.old-deja/g++.pt/crash15.C [new file with mode: 0644]
gcc/testsuite/g++.old-deja/g++.pt/enum5.C [new file with mode: 0644]
gcc/testsuite/g++.old-deja/g++.pt/explicit34.C
gcc/testsuite/g++.old-deja/g++.pt/friend28.C [new file with mode: 0644]
gcc/testsuite/g++.old-deja/g++.pt/friend29.C [new file with mode: 0644]