Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/gpl3/gcc/dist/libiberty pass lint on vax (avoid zer...
details: https://anonhg.NetBSD.org/src/rev/b88ac14618d6
branches: trunk
changeset: 369653:b88ac14618d6
user: christos <christos%NetBSD.org@localhost>
date: Sat Aug 27 08:30:04 2022 +0000
description:
pass lint on vax (avoid zerodivide)
diffstat:
external/gpl3/gcc/dist/libiberty/floatformat.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diffs (18 lines):
diff -r 1a4eb16bd97e -r b88ac14618d6 external/gpl3/gcc/dist/libiberty/floatformat.c
--- a/external/gpl3/gcc/dist/libiberty/floatformat.c Sat Aug 27 06:32:53 2022 +0000
+++ b/external/gpl3/gcc/dist/libiberty/floatformat.c Sat Aug 27 08:30:04 2022 +0000
@@ -53,9 +53,14 @@
#ifdef DBL_QNAN
#define NAN DBL_QNAN
#else
+#ifdef __lint__
+static double zero = 0.0;
+#define NAN (0.0 / zero)
+#else
#define NAN (0.0 / 0.0)
#endif
#endif
+#endif
static int mant_bits_set (const struct floatformat *, const unsigned char *);
static unsigned long get_field (const unsigned char *,
Home |
Main Index |
Thread Index |
Old Index