bug-tar
[Top][All Lists]
Advanced

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

[Bug-tar] Re: AC_TYPE_LONG_LONG_INT and AC_TYPE_UNSIGNED_LONG_LONG_INT


From: Bruno Haible
Subject: [Bug-tar] Re: AC_TYPE_LONG_LONG_INT and AC_TYPE_UNSIGNED_LONG_LONG_INT
Date: Tue, 23 Oct 2007 00:35:54 +0200
User-agent: KMail/1.5.4

Paul Eggert wrote:
> >     * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Use -1ull, not
> >     -1u, in preprocessor expression.
> 
> Thanks for checking that.  I installed that fix into gnulib, and a
> similar patch into autoconf.

Thanks. Now, since this is already the second time that we are on the
borderline to a situation where intmax_t and uintmax_t don't fit together,
I'm adding a check against it to stdint.in.h. I wasn't pleased to see that
the entire gettext package was compiled with these weird settings and the
problem was only revealed by the 'fprintf-posix' test.


2007-10-22  Bruno Haible  <address@hidden>

        * lib/stdint.in.h: Add check that intmax_t and uintmax_t have the same
        size.

*** lib/stdint.in.h.orig        2007-10-23 00:07:37.000000000 +0200
--- lib/stdint.in.h     2007-10-23 00:06:59.000000000 +0200
***************
*** 247,252 ****
--- 247,257 ----
  # define uintmax_t unsigned long int
  #endif
  
+ /* Verify that intmax_t and uintmax_t have the same size.  Too much code
+    breaks if this is not the case.  If this check fails, the reason is likely
+    to be found in the autoconf macros.  */
+ typedef int _verify_intmax_size[2 * (sizeof (intmax_t) == sizeof (uintmax_t)) 
- 1];
+ 
  /* 7.18.2. Limits of specified-width integer types */
  
  #if ! defined __cplusplus || defined __STDC_LIMIT_MACROS





reply via email to

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