public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [Committed][ARM] Fix ARM bootstrap failure
@ 2017-05-30 14:46 Wilco Dijkstra
  0 siblings, 0 replies; only message in thread
From: Wilco Dijkstra @ 2017-05-30 14:46 UTC (permalink / raw)
  To: GCC Patches; +Cc: nd

Fix ARM bootstrap failure due to an odd warning:

/src/gcc/gcc/config/arm/arm-builtins.c: In function 'rtx_def* arm_expand_builtin(tree, rtx, rtx, machine_mode, int)':
/src/gcc/gcc/config/arm/arm-builtins.c:3056:46: error: type qualifiers ignored on cast result type [-Werror=ignored-qualifiers]
     if (d->code == (const enum arm_builtins) fcode)
                                              ^~~~~

Avoid the warning by removing const, and bootstrap is OK again.

Committed as trivial patch (r248686).

ChangeLog:
2017-05-30  Wilco Dijkstra  <wdijkstr@arm.com>

    * config/arm/arm-builtins.c (arm_expand_builtin): Remove const.
--

diff --git a/gcc/config/arm/arm-builtins.c b/gcc/config/arm/arm-builtins.c
index deebb59f6a6fcdae3378f4e3fb021e008a4354b0..a0569ed10c5d6e5e857d7abe37d52b06a9a292b4 100644
--- a/gcc/config/arm/arm-builtins.c
+++ b/gcc/config/arm/arm-builtins.c
@@ -3053,15 +3053,15 @@ arm_expand_builtin (tree exp,
     }
 
   for (i = 0, d = bdesc_2arg; i < ARRAY_SIZE (bdesc_2arg); i++, d++)
-    if (d->code == (const enum arm_builtins) fcode)
+    if (d->code == (enum arm_builtins) fcode)
       return arm_expand_binop_builtin (d->icode, exp, target);
 
   for (i = 0, d = bdesc_1arg; i < ARRAY_SIZE (bdesc_1arg); i++, d++)
-    if (d->code == (const enum arm_builtins) fcode)
+    if (d->code == (enum arm_builtins) fcode)
       return arm_expand_unop_builtin (d->icode, exp, target, 0);
 
   for (i = 0, d = bdesc_3arg; i < ARRAY_SIZE (bdesc_3arg); i++, d++)
-    if (d->code == (const enum arm_builtins) fcode)
+    if (d->code == (enum arm_builtins) fcode)
       return arm_expand_ternop_builtin (d->icode, exp, target);
 
   /* @@@ Should really do something sensible here.  */

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2017-05-30 14:30 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-30 14:46 [Committed][ARM] Fix ARM bootstrap failure Wilco Dijkstra

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).