From 356db29280db321ec601dc64740cc2f07b158813 Mon Sep 17 00:00:00 2001 From: Tom de Vries Date: Thu, 23 Nov 2017 15:03:39 +0000 Subject: [PATCH] [sh] Wrap ASM_OUTPUT_ADDR_VEC_ELT in do {} while (0) 2017-11-23 Tom de Vries * config/sh/sh.h (ASM_OUTPUT_ADDR_VEC_ELT): Wrap in "do {} while (0)". From-SVN: r255100 --- gcc/ChangeLog | 4 ++++ gcc/config/sh/sh.h | 13 +++++++------ 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index c4c8287f2a7..39486ff2612 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2017-11-23 Tom de Vries + + * config/sh/sh.h (ASM_OUTPUT_ADDR_VEC_ELT): Wrap in "do {} while (0)". + 2017-11-23 Tom de Vries * config/ft32/ft32.h (ASM_OUTPUT_ADDR_VEC_ELT): Remove semicolon after diff --git a/gcc/config/sh/sh.h b/gcc/config/sh/sh.h index f5d80da1451..82699cd70d3 100644 --- a/gcc/config/sh/sh.h +++ b/gcc/config/sh/sh.h @@ -1754,12 +1754,13 @@ extern bool current_function_interrupt; } /* Output an absolute table element. */ -#define ASM_OUTPUT_ADDR_VEC_ELT(STREAM,VALUE) \ - if (! optimize || TARGET_BIGTABLE) \ - asm_fprintf ((STREAM), "\t.long\t%LL%d\n", (VALUE)); \ - else \ - asm_fprintf ((STREAM), "\t.word\t%LL%d\n", (VALUE)); - +#define ASM_OUTPUT_ADDR_VEC_ELT(STREAM,VALUE) \ + do { \ + if (! optimize || TARGET_BIGTABLE) \ + asm_fprintf ((STREAM), "\t.long\t%LL%d\n", (VALUE)); \ + else \ + asm_fprintf ((STREAM), "\t.word\t%LL%d\n", (VALUE)); \ + } while (0) /* A C statement to be executed just prior to the output of assembler code for INSN, to modify the extracted operands so -- 2.30.2