[patch, hpux, fixincludes, committed] Fix hpux_stdint_least_fast fixup for HP-UX.
Steve Ellcey
sje@cup.hp.com
Wed Oct 21 17:12:00 GMT 2009
This patch fixes several C++ library test failures on IA64 HP-UX;
17_intro/headers/c++200x/all_no_exceptions.cc,
17_intro/headers/c++200x/all_pedantic_errors.cc, and
26_numerics/headers/random/types_std_c++0x.cc.
The problem is that, in 32 bit mode, we were defining UINT_FAST64_MAX
and UINT_LEAST64_MAX in terms of ULLONG_MAX which is a C99 defined
macro. The HP-UX header files do not make this symbol visible in C++
which is a problem if the C++ code uses UINT_FAST64_MAX or
UINT_LEAST64_MAX. The fix is to define these symbols in terms of
__UINT64_MAX__ which GCC defines automatically and avoid the dependence
on ULLONG_MAX.
Tested on IA64 and PA HP-UX with no regressions and checked in.
Steve Ellcey
sje@cup.hp.com
2009-10-21 Steve Ellcey <sje@cup.hp.com>
* inclhack.def (hpux_stdint_least_fast): Simplify.
* fixincl.x: Regenerate.
* tests/base/stdint.h: Update.
Index: inclhack.def
===================================================================
--- inclhack.def (revision 153048)
+++ inclhack.def (working copy)
@@ -2213,16 +2213,9 @@ fix = {
select =
"^[ \t]*#[ \t]*define[ \t]+UINT_(LEAST|FAST)64_MAX[ \t]+ULLONG_MAX";
c_fix = format;
- c-fix-arg = <<- _EOFix_
- #ifdef __LP64__
- # define UINT_%164_MAX ULONG_MAX
- #else
- %0
- #endif
- _EOFix_;
- test-text = <<- _EOFix_
- # define UINT_FAST64_MAX ULLONG_MAX
- # define UINT_LEAST64_MAX ULLONG_MAX
+ c-fix-arg = "# define UINT_%164_MAX __UINT64_MAX__";
+ test-text = "# define UINT_FAST64_MAX ULLONG_MAX\n"
+ "# define UINT_LEAST64_MAX ULLONG_MAX\n";
_EOFix_;
};
More information about the Gcc-patches
mailing list