diff options
author | Brian Gaeke <gaeke@uiuc.edu> | 2003-08-11 20:04:57 +0000 |
---|---|---|
committer | Brian Gaeke <gaeke@uiuc.edu> | 2003-08-11 20:04:57 +0000 |
commit | 80d79fa5b497fc076cbef514be2ac45794e67f70 (patch) | |
tree | b4824c8e9120340bc62a7acb08a1c0e6e9a3e084 /include/Support | |
parent | 2bcee3400f0a7260b6dfc178d18ba29a5114911b (diff) |
If we can't find INT64_MAX, set it to a reasonable default value,
instead of printing out an (incorrect) #error message.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7744 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/Support')
-rw-r--r-- | include/Support/DataTypes.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/include/Support/DataTypes.h b/include/Support/DataTypes.h index 2f6724c4fb..84f3c2b356 100644 --- a/include/Support/DataTypes.h +++ b/include/Support/DataTypes.h @@ -32,8 +32,16 @@ #error "Cannot define both ENDIAN_LITTLE and ENDIAN_BIG!" #endif -#if (!defined(ENDIAN_LITTLE) && !defined(ENDIAN_BIG)) || !defined(INT64_MAX) +#if (!defined(ENDIAN_LITTLE) && !defined(ENDIAN_BIG)) #error "include/Support/DataTypes.h could not determine endianness!" #endif +#if !defined(INT64_MAX) +/* We couldn't determine INT64_MAX; default it. */ +#define INT64_MAX 9223372036854775807LL +#endif +#if !defined(UINT64_MAX) +#define UINT64_MAX 0xffffffffffffffffULL +#endif + #endif /* SUPPORT_DATATYPES_H */ |