]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
trans.c (mark_visited_r): Set TYPE_SIZES_GIMPLIFIED on the main variant of a type...
authorEric Botcazou <ebotcazou@adacore.com>
Sat, 29 Jun 2019 07:39:11 +0000 (07:39 +0000)
committerEric Botcazou <ebotcazou@gcc.gnu.org>
Sat, 29 Jun 2019 07:39:11 +0000 (07:39 +0000)
* gcc-interface/trans.c (mark_visited_r): Set TYPE_SIZES_GIMPLIFIED on
the main variant of a type, if any.

From-SVN: r272818

gcc/ada/ChangeLog
gcc/ada/gcc-interface/trans.c

index e8a8e1c89036c64f8e8ebd9242f9a284c8bec556..cfb613d69eb6658f2b6f420a20769acb0400fc8e 100644 (file)
@@ -1,3 +1,8 @@
+2019-06-29  Eric Botcazou  <ebotcazou@adacore.com>
+
+       * gcc-interface/trans.c (mark_visited_r): Set TYPE_SIZES_GIMPLIFIED on
+       the main variant of a type, if any.
+
 2019-06-29  Eric Botcazou  <ebotcazou@adacore.com>
 
        * gcc-interface/decl.c (set_nonaliased_component_on_array_type): Add
index c320481e4f82912ddaabf10be4bef445efbaf080..cccbcaa176e426ed7aef18318d5efde1a8dbf590 100644 (file)
@@ -8100,8 +8100,9 @@ mark_visited_r (tree *tp, int *walk_subtrees, void *data ATTRIBUTE_UNUSED)
   else if (!TYPE_IS_DUMMY_P (t))
     TREE_VISITED (t) = 1;
 
+  /* The test in gimplify_type_sizes is on the main variant.  */
   if (TYPE_P (t))
-    TYPE_SIZES_GIMPLIFIED (t) = 1;
+    TYPE_SIZES_GIMPLIFIED (TYPE_MAIN_VARIANT (t)) = 1;
 
   return NULL_TREE;
 }