+2005-04-18 Bruno Haible <bruno@clisp.org>
+
+ * libgnuintl.h.in (_INTL_REDIRECT_ASM): Test for __APPLE_CC__ > 1.
+ Needed because gcc-4.0 defines __APPLE_CC__ and implements
+ __USER_LABEL_PREFIX__ correctly.
+ * plural-exp.c (GERMANIC_PLURAL): Test for __APPLE_CC > 1.
+ Needed because gcc-4.0 defines __APPLE_CC__.
+
2005-04-11 Bruno Haible <bruno@clisp.org>
* gettext-0.14.4 released.
If he doesn't, we choose the method. A third possible method is
_INTL_REDIRECT_ASM, supported only by GCC. */
#if !(defined _INTL_REDIRECT_INLINE || defined _INTL_REDIRECT_MACROS)
-# if __GNUC__ >= 2 && !defined __APPLE_CC__ && !defined __MINGW32__ && !(__GNUC__ == 2 && defined _AIX) && (defined __STDC__ || defined __cplusplus)
+# if __GNUC__ >= 2 && !(__APPLE_CC__ > 1) && !defined __MINGW32__ && !(__GNUC__ == 2 && defined _AIX) && (defined __STDC__ || defined __cplusplus)
# define _INTL_REDIRECT_ASM
# else
# ifdef __cplusplus
#include "plural-exp.h"
-#if (defined __GNUC__ && !defined __APPLE_CC__) \
+#if (defined __GNUC__ && !(__APPLE_CC__ > 1)) \
|| (defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L)
/* These structs are the constant expression for the germanic plural
+2005-04-18 Bruno Haible <bruno@clisp.org>
+
+ * dfa.c (update_mb_len_index): Change argument type to 'const char *'.
+ Avoids gcc-4.0 warnings.
+
2005-04-11 Bruno Haible <bruno@clisp.org>
* gettext-0.14.4 released.
/* This function update cur_mb_len, and cur_mb_index.
p points current lexptr, len is the remaining buffer length. */
static void
-update_mb_len_index (unsigned char const *p, int len)
+update_mb_len_index (char const *p, int len)
{
/* If last character is a part of a multibyte character,
we update cur_mb_index. */
+2005-04-18 Bruno Haible <bruno@clisp.org>
+
+ * po-lex.h (po_gram_error, po_gram_error_at_line): Test for
+ __APPLE_CC__ > 1. Needed because gcc-4.0 defines __APPLE_CC__ and
+ implements __VA_ARGS__ correctly.
+ * po-lex.c (po_gram_error, po_gram_error_at_line): Likewise.
+ * read-stringtable.c (phase2_getc): Optimize UTF-8 code. Avoids
+ gcc-4.0 warnings.
+
2005-04-11 Bruno Haible <bruno@clisp.org>
* gettext-0.14.4 released.
#if !(__STDC__ && \
((defined __STDC_VERSION__ && __STDC_VERSION__ >= 199901L && !defined __DECC) \
- || (defined __GNUC__ && __GNUC__ >= 2 && !defined __APPLE_CC__)))
+ || (defined __GNUC__ && __GNUC__ >= 2 && !(__APPLE_CC__ > 1))))
/* CAUTION: If you change this function, you must also make identical
changes to the macro of the same name in src/po-lex.h */
} while (0)
/* GCC is also smart enough to allow optimizations like this. */
-#elif __STDC__ && defined __GNUC__ && __GNUC__ >= 2 && !defined __APPLE_CC__
+#elif __STDC__ && defined __GNUC__ && __GNUC__ >= 2 && !(__APPLE_CC__ > 1)
/* CAUTION: If you change this macro, you must also make identical
changes to the function of the same name in src/po-lex.c */
return UEOF;
buf[1] = c;
count = 2;
- }
-
- if (buf[0] >= 0xe0
- && ((buf[1] ^ 0x80) < 0x40))
- {
- c = phase1_getc ();
- if (c == EOF)
- return UEOF;
- buf[2] = c;
- count = 3;
- }
- if (buf[0] >= 0xf0
- && ((buf[1] ^ 0x80) < 0x40)
- && ((buf[2] ^ 0x80) < 0x40))
- {
- c = phase1_getc ();
- if (c == EOF)
- return UEOF;
- buf[3] = c;
- count = 4;
- }
-
- if (buf[0] >= 0xf8
- && ((buf[1] ^ 0x80) < 0x40)
- && ((buf[2] ^ 0x80) < 0x40)
- && ((buf[3] ^ 0x80) < 0x40))
- {
- c = phase1_getc ();
- if (c == EOF)
- return UEOF;
- buf[4] = c;
- count = 5;
- }
-
- if (buf[0] >= 0xfc
- && ((buf[1] ^ 0x80) < 0x40)
- && ((buf[2] ^ 0x80) < 0x40)
- && ((buf[3] ^ 0x80) < 0x40)
- && ((buf[4] ^ 0x80) < 0x40))
- {
- c = phase1_getc ();
- if (c == EOF)
- return UEOF;
- buf[5] = c;
- count = 6;
+ if (buf[0] >= 0xe0
+ && ((buf[1] ^ 0x80) < 0x40))
+ {
+ c = phase1_getc ();
+ if (c == EOF)
+ return UEOF;
+ buf[2] = c;
+ count = 3;
+
+ if (buf[0] >= 0xf0
+ && ((buf[2] ^ 0x80) < 0x40))
+ {
+ c = phase1_getc ();
+ if (c == EOF)
+ return UEOF;
+ buf[3] = c;
+ count = 4;
+
+ if (buf[0] >= 0xf8
+ && ((buf[3] ^ 0x80) < 0x40))
+ {
+ c = phase1_getc ();
+ if (c == EOF)
+ return UEOF;
+ buf[4] = c;
+ count = 5;
+
+ if (buf[0] >= 0xfc
+ && ((buf[4] ^ 0x80) < 0x40))
+ {
+ c = phase1_getc ();
+ if (c == EOF)
+ return UEOF;
+ buf[5] = c;
+ count = 6;
+ }
+ }
+ }
+ }
}
u8_mbtouc (&uc, buf, count);