clear TREE_USED f;ag for build_type_variant types as well
authorAndrew MacLeod <amacleod@cygnus.com>
Thu, 7 May 1998 14:30:53 +0000 (14:30 +0000)
committerAndrew Macleod <amacleod@gcc.gnu.org>
Thu, 7 May 1998 14:30:53 +0000 (14:30 +0000)
From-SVN: r19611

gcc/cp/ChangeLog
gcc/cp/method.c

index 665b05866247e590665ff7fe7c191579f2755db1..c5699e629afa17b4662b906a69f9bb2fdcf9cb48 100644 (file)
@@ -1,3 +1,8 @@
+Thu May  7 17:09:25 EDT 1998  Andrew MacLeod  <amacleod@cygnus.com>
+
+       * method.c (build_decl_overload_real): Set TREE_USED flag to
+       zero for build_type_variants nodes as well.
+
 Wed May  6 19:27:09 1998  Jason Merrill  <jason@yorick.cygnus.com>
 
        * pt.c (tsubst): Don't tsubst the type of an IDENTIFIER_NODE.
@@ -40,7 +45,8 @@ Tue May  5 23:54:04 1998  Jason Merrill  <jason@yorick.cygnus.com>
 
 Tue May  5 18:24:13 EDT 1998  Andrew MacLeod  <amacleod@cygnus.com>
 
-       * method.c: Add a call to build_type_variant to get the right type.
+       * method.c (build_mangled_name): Add a call to build_type_variant 
+       to get the right type.
 
 Tue May  5 01:25:03 1998  Jason Merrill  <jason@yorick.cygnus.com>
 
index 02b1b65a4261adf377377e65298d3f0e7155d4c5..e97c62641018eed4c5b3b197ec240f0dfc453052 100644 (file)
@@ -1621,7 +1621,12 @@ build_decl_overload_real (dname, parms, ret_type, tparms, targs,
           typevec = NULL;
           while (t)
             {
-              TREE_USED (TREE_VALUE (t)) = 0;
+              tree temp = TREE_VALUE (t);
+              TREE_USED (temp) = 0;
+              /* clear out the type variant in case we used it */
+              temp = build_type_variant (TYPE_MAIN_VARIANT (temp),
+                    TYPE_READONLY (temp), TYPE_VOLATILE (temp));
+              TREE_USED (temp) = 0;
               t = TREE_CHAIN (t);
             }
         }