diff options
author | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-09-15 19:09:27 +0000 |
---|---|---|
committer | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2005-09-15 19:09:27 +0000 |
commit | 96eced216d6e34f1404c9222124d2f6723c0d70c (patch) | |
tree | 09c7d56df5e7852774bb3a461cda54ed55c02121 /fixincludes/inclhack.def | |
parent | e57bcbd387e30f5c7ce2b02eff7255360029d21c (diff) | |
download | gcc-96eced216d6e34f1404c9222124d2f6723c0d70c.tar.gz |
fixincludes:
PR c++/23139
* inclhack.def (huge_val_hex, huge_valf_hex, huge_vall_hex): New
fixes.
* fixincl.x: Regenerate.
* tests/base/bits/huge_val.h: New file.
gcc/testsuite:
* g++.dg/warn/huge-val1.C: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@104315 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'fixincludes/inclhack.def')
-rw-r--r-- | fixincludes/inclhack.def | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/fixincludes/inclhack.def b/fixincludes/inclhack.def index 2ff588719b7..3cfb3e099e3 100644 --- a/fixincludes/inclhack.def +++ b/fixincludes/inclhack.def @@ -1681,6 +1681,54 @@ fix = { /* + * Fix glibc definition of HUGE_VAL in terms of hex floating point constant + */ +fix = { + hackname = huge_val_hex; + files = bits/huge_val.h; + select = "^#[ \t]*define[ \t]*HUGE_VAL[ \t].*0x1\\.0p.*"; + bypass = "__builtin_huge_val"; + + c_fix = format; + c_fix_arg = "#define HUGE_VAL (__builtin_huge_val())\n"; + + test_text = "# define HUGE_VAL\t(__extension__ 0x1.0p2047)"; +}; + + +/* + * Fix glibc definition of HUGE_VALF in terms of hex floating point constant + */ +fix = { + hackname = huge_valf_hex; + files = bits/huge_val.h; + select = "^#[ \t]*define[ \t]*HUGE_VALF[ \t].*0x1\\.0p.*"; + bypass = "__builtin_huge_valf"; + + c_fix = format; + c_fix_arg = "#define HUGE_VALF (__builtin_huge_valf())\n"; + + test_text = "# define HUGE_VALF (__extension__ 0x1.0p255f)"; +}; + + +/* + * Fix glibc definition of HUGE_VALL in terms of hex floating point constant + */ +fix = { + hackname = huge_vall_hex; + files = bits/huge_val.h; + select = "^#[ \t]*define[ \t]*HUGE_VALL[ \t].*0x1\\.0p.*"; + bypass = "__builtin_huge_vall"; + + c_fix = format; + c_fix_arg = "#define HUGE_VALL (__builtin_huge_vall())\n"; + + test_text = "# define HUGE_VALL (__extension__ 0x1.0p32767L)"; +}; + + +/* * Fix return type of abort and free */ fix = { |