From a5f1c5f89bcdd5dcf3ae81a09d568b9be02c7142 Mon Sep 17 00:00:00 2001 From: Nathan Sidwell Date: Thu, 6 Jul 2000 15:34:09 +0000 Subject: [PATCH] * pt.c (tsubst): Don't layout type, if it's error_mark. From-SVN: r34888 --- gcc/cp/ChangeLog | 4 ++++ gcc/cp/pt.c | 6 ++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 6386d66d5a6..bce0feaa6cc 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +2000-07-06 Nathan Sidwell + + * pt.c (tsubst): Don't layout type, if it's error_mark. + 2000-07-06 Nathan Sidwell * pt.c (instantiate_pending_templates): Reset template level. diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index 9f88761c21f..cef15125eba 100644 --- a/gcc/cp/pt.c +++ b/gcc/cp/pt.c @@ -6515,8 +6515,10 @@ tsubst (t, args, complain, in_decl) r = build_reference_type (type); r = cp_build_qualified_type_real (r, TYPE_QUALS (t), complain); - /* Will this ever be needed for TYPE_..._TO values? */ - layout_type (r); + if (r != error_mark_node) + /* Will this ever be needed for TYPE_..._TO values? */ + layout_type (r); + return r; } case OFFSET_TYPE: -- 2.30.2