class.c (instantiate_type): Don't just return a known type if it's wrong.
authorJason Merrill <jason@gcc.gnu.org>
Thu, 29 Jan 1998 00:08:53 +0000 (19:08 -0500)
committerJason Merrill <jason@gcc.gnu.org>
Thu, 29 Jan 1998 00:08:53 +0000 (19:08 -0500)
commitabff8e0691a5b560c4680cac0ddf6e6f61849bc8
tree57fb4c8fa376c32ea452e23fa89d13704ca6602e
parent76d31c63736a0a5a0560fccf5d400c5a5b8a20b9
class.c (instantiate_type): Don't just return a known type if it's wrong.

* class.c (instantiate_type): Don't just return a known type if
  it's wrong.
* class.c (instantiate_type): Remove handling of FUNCTION_DECL
since that code could never be reached.
* error.c (dump_decl): Avoid aborting in the midst of printing an
error message about an illegal template declaration.
* parse.y (structsp): Print an error message, rather than crashing,
when a class-head does not name a class.
* pt.c (convert_nontype_argument):  Allow REAL_TYPE and COMPLEX_TYPE
template arguments as a g++ extension.
* cp-tree.def (ALIGNOF_EXPR): New tree code.
* decl2.c (grok_alignof): If processing_template_decl, just store
the expression.
* typeck.c (c_alignof): Likewise.
* decl2.c (build_expr_from_tree): Handle ALIGNOF_EXPR.
* error.c (dump_expr): Likewise.
* pt.c (tsubst_copy): Likewise.
* tree.c (cp_tree_equal): Likewise.
* pt.c (uses_template_parms): Correctly determine whether or not a
SIZEOF_EXPR/ALIGNOF_EXPR uses template parameters so that constant
folding can be done.

From-SVN: r17545
gcc/cp/ChangeLog
gcc/cp/class.c
gcc/cp/cp-tree.def
gcc/cp/decl2.c
gcc/cp/error.c
gcc/cp/parse.c
gcc/cp/parse.y
gcc/cp/pt.c
gcc/cp/tree.c
gcc/cp/typeck.c