From 36a704ef1a762943bb2e6cfdf93e8b130199a553 Mon Sep 17 00:00:00 2001 From: jason Date: Sun, 17 May 1998 13:26:02 +0000 Subject: * decl.c (duplicate_decls): Use CANONICAL_TYPE_VARIANT to compare old and new types. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@19816 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/cp/ChangeLog | 3 +++ gcc/cp/decl.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) (limited to 'gcc') diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 69e6fc68b31..6c8b627969a 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,8 @@ Sun May 17 12:32:08 1998 Jason Merrill + * decl.c (duplicate_decls): Use CANONICAL_TYPE_VARIANT to compare + old and new types. + * pt.c (tsubst): Make sure that BINFO_TYPE of new binfos is the canonical type. diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c index 9d409e3620d..1ab0922a28d 100644 --- a/gcc/cp/decl.c +++ b/gcc/cp/decl.c @@ -2926,7 +2926,7 @@ duplicate_decls (newdecl, olddecl) TREE_TYPE (newdecl) = TREE_TYPE (olddecl) = newtype; /* Lay the type out, unless already done. */ - if (oldtype != TREE_TYPE (newdecl) + if (newtype != CANONICAL_TYPE_VARIANT (oldtype) && TREE_TYPE (newdecl) != error_mark_node && !(processing_template_decl && uses_template_parms (newdecl))) layout_type (TREE_TYPE (newdecl)); -- cgit v1.2.3