Allow targets to define the default for the short enums option.
gcc/
* config/arm/arm.h (ARM_DEFAULT_SHORT_ENUMS): Provide default
definition.
* config/arm/arm.c (arm_default_short_enums): Use
ARM_DEFAULT_SHORT_ENUMS.
* config/arm/rtems.h (ARM_DEFAULT_SHORT_ENUMS): Define.
From-SVN: r246753
+2017-04-07 Sebastian Huber <sebastian.huber@embedded-brains.de>
+
+ * config/arm/arm.h (ARM_DEFAULT_SHORT_ENUMS): Provide default
+ definition.
+ * config/arm/arm.c (arm_default_short_enums): Use
+ ARM_DEFAULT_SHORT_ENUMS.
+ * config/arm/rtems.h (ARM_DEFAULT_SHORT_ENUMS): Define.
+
2017-04-06 Jakub Jelinek <jakub@redhat.com>
PR debug/80234
return mode;
}
-/* AAPCS based ABIs use short enums by default. */
static bool
arm_default_short_enums (void)
{
- return TARGET_AAPCS_BASED && arm_abi != ARM_ABI_AAPCS_LINUX;
+ return ARM_DEFAULT_SHORT_ENUMS;
}
#define ARM_DEFAULT_ABI ARM_ABI_APCS
#endif
+/* AAPCS based ABIs use short enums by default. */
+#ifndef ARM_DEFAULT_SHORT_ENUMS
+#define ARM_DEFAULT_SHORT_ENUMS \
+ (TARGET_AAPCS_BASED && arm_abi != ARM_ABI_AAPCS_LINUX)
+#endif
+
/* Map each of the micro-architecture variants to their corresponding
major architecture revision. */
builtin_assert ("system=rtems"); \
TARGET_BPABI_CPP_BUILTINS(); \
} while (0)
+
+#define ARM_DEFAULT_SHORT_ENUMS false