]> gcc.gnu.org Git - gcc.git/commitdiff
typeck.c (strip_all_pointer_quals): Use TYPE_MAIN_VARIANT, to strip array element...
authorNathan Sidwell <nathan@acm.org>
Tue, 8 Feb 2000 11:15:24 +0000 (11:15 +0000)
committerNathan Sidwell <nathan@gcc.gnu.org>
Tue, 8 Feb 2000 11:15:24 +0000 (11:15 +0000)
* typeck.c (strip_all_pointer_quals): Use TYPE_MAIN_VARIANT, to
strip array element qualifiers too.

From-SVN: r31849

gcc/cp/ChangeLog
gcc/cp/typeck.c

index 82faae374ca804616d5e31bf2430c96b7a2fa5c4..e6326728a1b47546d4cbddb7613aa4f278d727bf 100644 (file)
@@ -1,3 +1,8 @@
+2000-02-08  Nathan Sidwell  <nathan@acm.org>
+
+       * typeck.c (strip_all_pointer_quals): Use TYPE_MAIN_VARIANT, to
+       strip array element qualifiers too.
+
 2000-02-07  Mark Mitchell  <mark@codesourcery.com>
 
        * decl.c (store_parm_decls): Don't build cleanups for parameters
index c9c10854fb5c5c134057ec7f413139430acdae8b..1ffd7bc881850aad8d695d9f4836ee3bd49bd041 100644 (file)
@@ -7170,7 +7170,8 @@ casts_away_constness (t1, t2)
 
 /* Returns TYPE with its cv qualifiers removed
    TYPE is T cv* .. *cv where T is not a pointer type,
-   returns T * .. *  */
+   returns T * .. *. (If T is an array type, then the cv qualifiers
+   above are those of the array members.)  */
 
 static tree
 strip_all_pointer_quals (type)
@@ -7179,5 +7180,5 @@ strip_all_pointer_quals (type)
   if (TREE_CODE (type) == POINTER_TYPE)
     return build_pointer_type (strip_all_pointer_quals (TREE_TYPE (type)));
   else
-    return strip_top_quals (type);
+    return TYPE_MAIN_VARIANT (type);
 }
This page took 0.09181 seconds and 5 git commands to generate.