gccrs: remove bad assertion
authorPhilip Herron <philip.herron@embecosm.com>
Sat, 17 Sep 2022 09:06:48 +0000 (10:06 +0100)
committerArthur Cohen <arthur.cohen@embecosm.com>
Tue, 31 Jan 2023 13:16:51 +0000 (14:16 +0100)
gcc/rust/ChangeLog:

* backend/rust-tree.cc (rs_type_quals): Comment out bad assertion

gcc/rust/backend/rust-tree.cc

index d2ddcfd..47506d6 100644 (file)
@@ -974,9 +974,10 @@ rs_type_quals (const_tree type)
     return TYPE_UNQUALIFIED;
   quals = TYPE_QUALS (type);
   /* METHOD and REFERENCE_TYPEs should never have quals.  */
-  gcc_assert (
-    (TREE_CODE (type) != METHOD_TYPE && !TYPE_REF_P (type))
-    || ((quals & (TYPE_QUAL_CONST | TYPE_QUAL_VOLATILE)) == TYPE_UNQUALIFIED));
+  // gcc_assert (
+  //   (TREE_CODE (type) != METHOD_TYPE && !TYPE_REF_P (type))
+  //   || ((quals & (TYPE_QUAL_CONST | TYPE_QUAL_VOLATILE)) ==
+  //   TYPE_UNQUALIFIED));
   return quals;
 }