This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] PR bootstrap/61598


From: Trevor Saunders <tsaunders@mozilla.com>

Hi,

Basically the same as the mingw issue, fixed similarly.

Trev

        PR bootstrap/61598
        * fold-const.c (fold_checksum_tree): fix const qualification of
        argument passed to hash_table::find_slot with a const_cast.
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 79847e3..4ebdfc7 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2014-06-25  Trevor Saunders  <tsaunders@mozilla.com>
+
+	PR bootstrap/61598
+	* fold-const.c (fold_checksum_tree): fix const qualification of
+	argument passed to hash_table::find_slot with a const_cast.
+
 2014-06-25  Nick Clifton  <nickc@redhat.com>
 
 	* config/v850/v850.c (GHS_default_section_names): Change to const
diff --git a/gcc/fold-const.c b/gcc/fold-const.c
index f6b72b7..ed90a8d 100644
--- a/gcc/fold-const.c
+++ b/gcc/fold-const.c
@@ -14752,7 +14752,7 @@ fold_checksum_tree (const_tree expr, struct md5_ctx *ctx,
  recursive_label:
   if (expr == NULL)
     return;
-  slot = ht->find_slot (expr, INSERT);
+  slot = ht->find_slot (const_cast<tree> (expr), INSERT);
   if (*slot != NULL)
     return;
   *slot = CONST_CAST_TREE (expr);
-- 
2.0.0


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]