summaryrefslogtreecommitdiff
path: root/lib/stdint.in.h
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2011-12-14 23:02:29 +0100
committerLudovic Courtès <ludo@gnu.org>2011-12-14 23:46:22 +0100
commit7f1ea859ee33383db29e38dec5802ee0f21b09bc (patch)
treeca1cdf98963ecf6108cda6298ea8d7674283980a /lib/stdint.in.h
parent1002c774e0b908b50895da9a21a4bb63d18228de (diff)
downloadguile-7f1ea859ee33383db29e38dec5802ee0f21b09bc.tar.gz
Update Gnulib to v0.0-6703-g4e0358a.
Diffstat (limited to 'lib/stdint.in.h')
-rw-r--r--lib/stdint.in.h19
1 files changed, 11 insertions, 8 deletions
diff --git a/lib/stdint.in.h b/lib/stdint.in.h
index 16967f2e8..1451dbf25 100644
--- a/lib/stdint.in.h
+++ b/lib/stdint.in.h
@@ -49,6 +49,17 @@
diagnostics. */
# define __STDINT_H__
# endif
+
+ /* Some pre-C++11 <stdint.h> implementations need this. */
+# ifdef __cplusplus
+# ifndef __STDC_CONSTANT_MACROS
+# define __STDC_CONSTANT_MACROS 1
+# endif
+# ifndef __STDC_LIMIT_MACROS
+# define __STDC_LIMIT_MACROS 1
+# endif
+# endif
+
/* Other systems may have an incomplete or buggy <stdint.h>.
Include it before <inttypes.h>, since any "#include <stdint.h>"
in <inttypes.h> would reinclude us, skipping our contents because
@@ -313,8 +324,6 @@ typedef int _verify_intmax_size[sizeof (intmax_t) == sizeof (uintmax_t)
/* 7.18.2. Limits of specified-width integer types */
-#if ! defined __cplusplus || defined __STDC_LIMIT_MACROS
-
/* 7.18.2.1. Limits of exact-width integer types */
/* Here we assume a standard architecture where the hardware integer
@@ -534,12 +543,8 @@ typedef int _verify_intmax_size[sizeof (intmax_t) == sizeof (uintmax_t)
#define WINT_MAX \
_STDINT_MAX (@HAVE_SIGNED_WINT_T@, @BITSIZEOF_WINT_T@, 0@WINT_T_SUFFIX@)
-#endif /* !defined __cplusplus || defined __STDC_LIMIT_MACROS */
-
/* 7.18.4. Macros for integer constants */
-#if ! defined __cplusplus || defined __STDC_CONSTANT_MACROS
-
/* 7.18.4.1. Macros for minimum-width integer constants */
/* According to ISO C 99 Technical Corrigendum 1 */
@@ -600,7 +605,5 @@ typedef int _verify_intmax_size[sizeof (intmax_t) == sizeof (uintmax_t)
# endif
#endif
-#endif /* !defined __cplusplus || defined __STDC_CONSTANT_MACROS */
-
#endif /* _@GUARD_PREFIX@_STDINT_H */
#endif /* !defined _@GUARD_PREFIX@_STDINT_H && !defined _GL_JUST_INCLUDE_SYSTEM_STDINT_H */