diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 7a370367c426..79dce7482ac3 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,8 @@ +2007-01-05 Douglas Gregor + + * pt.c (tsubst): Propagate the need for structural equality checks + when reducing the level of template parameters. + 2007-01-03 Kazu Hirata * pt.c: Fix a comment typo. diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index c1fc2ad4f46b..787cd60b060e 100644 --- a/gcc/cp/pt.c +++ b/gcc/cp/pt.c @@ -7530,6 +7530,8 @@ tsubst (tree t, tree args, tsubst_flags_t complain, tree in_decl) require structural equality checking to compare TEMPLATE_TEMPLATE_PARMs. */ SET_TYPE_STRUCTURAL_EQUALITY (r); + else if (TYPE_STRUCTURAL_EQUALITY_P (t)) + SET_TYPE_STRUCTURAL_EQUALITY (r); else TYPE_CANONICAL (r) = canonical_type_parameter (r);