summaryrefslogtreecommitdiff
path: root/hints
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2002-02-06 23:38:10 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2002-02-06 23:38:10 +0000
commiteecdb66e2703f1b4556c3b52acafae55c7e4d968 (patch)
tree23ece167cc29c7185ead2fdf118a7235e43d0c22 /hints
parent9b7cf638a3124941b94670130183a53639a76cb3 (diff)
downloadperl-eecdb66e2703f1b4556c3b52acafae55c7e4d968.tar.gz
OS/390 gcvt() seems buggy: with -W 0,float(ieee) it
mangles 0.1 to "10". sprintf() seems more well-behaved. p4raw-id: //depot/perl@14579
Diffstat (limited to 'hints')
-rw-r--r--hints/os390.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/hints/os390.sh b/hints/os390.sh
index bb41e6719f..8766f0b566 100644
--- a/hints/os390.sh
+++ b/hints/os390.sh
@@ -203,6 +203,14 @@ EOWARN
fi
fi
+# Most of the time gcvt() seems to work fine but
+# sometimes values like 0.1, 0.2, come out as "10", "20",
+# a trivial Perl demonstration snippet is 'print 0.1'.
+# Yes, a flagrant bug, but unfortunately not trivial to
+# reproduce in C using gcvt().
+# sprintf() seems to get things right(er).
+d_Gconvert='sprintf((b),"%.*g",(n),(x))'
+
cat >config.arch<<'__CONFIG_ARCH__'
# The '-W 0,float(ieee)' cannot be used during Configure as ldflags.