bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Trivial patches to silence -Wundef


From: Gisle Vanem
Subject: Re: Trivial patches to silence -Wundef
Date: Sat, 22 Apr 2017 11:00:32 +0200
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0

Bruno Haible wrote:

diff --git a/lib/gettext.h b/lib/gettext.h
index 888e2fc..2a12bb6 100644
--- a/lib/gettext.h
+++ b/lib/gettext.h
@@ -18,8 +18,9 @@
 #ifndef _LIBGETTEXT_H
 #define _LIBGETTEXT_H 1

-/* NLS can be disabled through the configure --disable-nls option.  */
-#if ENABLE_NLS
+/* NLS can be disabled through the configure --disable-nls option
+   or through "#define ENABLE NLS 0" before including this file.  */
+#if defined ENABLE_NLS && ENABLE_NLS

Speaking of gettext, shouldn't lib/xbinary-io.c test on ENABLE_NLS
too? Because now I get:
  xbinary-io.c(34): warning C4047: 'function': 'const char *' differs in levels 
of indirection from 'int'
  xbinary-io.c(34): warning C4024: 'error': different types for formal and 
actual parameter 3

Where is '_(x)' defined if ENABLE_NLS is not defined?

--
--gv



reply via email to

[Prev in Thread] Current Thread [Next in Thread]