From: Ramsay Jones Date: Thu, 7 Apr 2011 18:41:48 +0000 (+0100) Subject: i18n: avoid parenthesized string as array initializer X-Git-Tag: v1.7.5-rc2~7 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=642f85faab27adec13eced36cd7e7548311f6c87;p=git.git i18n: avoid parenthesized string as array initializer The syntax static const char ignore_error[] = ("something"); is invalid C. A parenthesized string is not allowed as an array initializer. Some compilers, for example GCC and MSVC, allow this syntax as an extension, but it is not a portable construct. tcc does not parse it, for example. Remove the parenthesis from the definition of the N_() macro to fix this. Signed-off-by: Ramsay Jones Acked-by: Jonathan Nieder Acked-by: Ævar Arnfjörð Bjarmason Signed-off-by: Junio C Hamano --- diff --git a/gettext.h b/gettext.h index 1b253b7e7..24d91824e 100644 --- a/gettext.h +++ b/gettext.h @@ -35,6 +35,6 @@ const char *Q_(const char *msgid, const char *plu, unsigned long n) } /* Mark msgid for translation but do not translate it. */ -#define N_(msgid) (msgid) +#define N_(msgid) msgid #endif