diff options
author | Joseph Myers <jsm@polyomino.org.uk> | 2004-08-05 01:38:31 +0100 |
---|---|---|
committer | Joseph Myers <jsm28@gcc.gnu.org> | 2004-08-05 01:38:31 +0100 |
commit | 852910694f6d4480afd733a62fd6b93de62b51e6 (patch) | |
tree | 06690c205a19e52eb65cb0ac2b6391e8c47bc57c /gcc/testsuite/gcc.dg/torture | |
parent | 5a05b7c5dad390be66339c575ea4623dfb55cf57 (diff) | |
download | gcc-852910694f6d4480afd733a62fd6b93de62b51e6.zip gcc-852910694f6d4480afd733a62fd6b93de62b51e6.tar.gz gcc-852910694f6d4480afd733a62fd6b93de62b51e6.tar.bz2 |
c-common.c (c_stddef_cpp_builtins): Define __INTMAX_TYPE__ and __UINTMAX_TYPE__.
* c-common.c (c_stddef_cpp_builtins): Define __INTMAX_TYPE__ and
__UINTMAX_TYPE__.
* c-cppbuiltin.c (builtin_define_stdint_macros): New. Define
__INTMAX_MAX__.
(c_cpp_builtins): Call it.
* doc/cpp.texi: Update.
testsuite:
* gcc.c-torture/execute/builtins/abs-2.c,
gcc.c-torture/execute/builtins/abs-3.c,
gcc.c-torture/execute/builtins/lib/abs.c, gcc.dg/format/format.h,
gcc.dg/torture/builtin-attr-1.c: Use predefined macros for
intmax_t, uintmax_t and their limits.
* gcc.dg/intmax_t-1.c: New test.
From-SVN: r85588
Diffstat (limited to 'gcc/testsuite/gcc.dg/torture')
-rw-r--r-- | gcc/testsuite/gcc.dg/torture/builtin-attr-1.c | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/gcc/testsuite/gcc.dg/torture/builtin-attr-1.c b/gcc/testsuite/gcc.dg/torture/builtin-attr-1.c index 62070c4..2183021 100644 --- a/gcc/testsuite/gcc.dg/torture/builtin-attr-1.c +++ b/gcc/testsuite/gcc.dg/torture/builtin-attr-1.c @@ -404,16 +404,7 @@ CPTEST1 (csqrt) CPTEST1 (ctan) CPTEST1 (ctanh) -/* These next definitions are kludges. When GCC has a <stdint.h> it - should be used. -*/ -#if __INT_MAX__ == __LONG_LONG_MAX__ -typedef int intmax_t; -#elif __LONG_MAX__ == __LONG_LONG_MAX__ -typedef long intmax_t; -#else -typedef long long intmax_t; -#endif +typedef __INTMAX_TYPE__ intmax_t; /* Various other const builtins. */ TEST1 (abs, int, int) |