summaryrefslogtreecommitdiff
path: root/gcc/optabs.c
diff options
context:
space:
mode:
authorian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2009-06-10 02:01:06 +0000
committerian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>2009-06-10 02:01:06 +0000
commit423aab86b96cee0e4855395e07f7086ffebea6cd (patch)
treedb7cab5db121bc9f4ea32f384356de3085b43d24 /gcc/optabs.c
parent5741047ef3d6bd21528067e7ff6b0af43efc5614 (diff)
downloadgcc-423aab86b96cee0e4855395e07f7086ffebea6cd.tar.gz
* system.h (HAVE_DESIGNATED_INITIALIZERS): Don't define if
compiling with C++. * optabs.c (optab_table): Only use designated initializers if HAVE_DESIGNATED_INITIALIZERS is defined. (convert_optab_table): Likewise. (init_optabs): Always call init_insn_codes if HAVE_DESIGNATED_INITIALIZERS is not defined. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@148336 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/optabs.c')
-rw-r--r--gcc/optabs.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/optabs.c b/gcc/optabs.c
index 2b9da2cdb29..257edd9e648 100644
--- a/gcc/optabs.c
+++ b/gcc/optabs.c
@@ -54,7 +54,7 @@ along with GCC; see the file COPYING3. If not see
See expr.h for documentation of these optabs. */
-#if GCC_VERSION >= 4000
+#if GCC_VERSION >= 4000 && HAVE_DESIGNATED_INITIALIZERS
__extension__ struct optab_d optab_table[OTI_MAX]
= { [0 ... OTI_MAX - 1].handlers[0 ... NUM_MACHINE_MODES - 1].insn_code
= CODE_FOR_nothing };
@@ -66,7 +66,7 @@ struct optab_d optab_table[OTI_MAX];
rtx libfunc_table[LTI_MAX];
/* Tables of patterns for converting one mode to another. */
-#if GCC_VERSION >= 4000
+#if GCC_VERSION >= 4000 && HAVE_DESIGNATED_INITIALIZERS
__extension__ struct convert_optab_d convert_optab_table[COI_MAX]
= { [0 ... COI_MAX - 1].handlers[0 ... NUM_MACHINE_MODES - 1]
[0 ... NUM_MACHINE_MODES - 1].insn_code
@@ -6153,7 +6153,7 @@ init_optabs (void)
vcondu_gen_code[i] = CODE_FOR_nothing;
}
-#if GCC_VERSION >= 4000
+#if GCC_VERSION >= 4000 && HAVE_DESIGNATED_INITIALIZERS
/* We statically initialize the insn_codes with CODE_FOR_nothing. */
if (reinit)
init_insn_codes ();