From 2ced82ab8e4cce86bcbf7f11edcc80a6842ab2da Mon Sep 17 00:00:00 2001 From: is Date: Tue, 2 May 2000 12:39:03 +0000 Subject: Add the (void)&acc; hack from strtouq.c to strtoull.c. This works around an arm32 compiler bug. Change the comment in strtouq.c to reflect the current usage of the hack. --- lib/libc/stdlib/strtoull.c | 9 +++++++-- lib/libc/stdlib/strtouq.c | 6 +++--- 2 files changed, 10 insertions(+), 5 deletions(-) (limited to 'lib/libc/stdlib') diff --git a/lib/libc/stdlib/strtoull.c b/lib/libc/stdlib/strtoull.c index ae4ad8e8450..79a2f9ee552 100644 --- a/lib/libc/stdlib/strtoull.c +++ b/lib/libc/stdlib/strtoull.c @@ -1,4 +1,4 @@ -/* $NetBSD: strtoull.c,v 1.2 2000/03/07 20:02:00 kleink Exp $ */ +/* $NetBSD: strtoull.c,v 1.3 2000/05/02 12:39:03 is Exp $ */ /* * Copyright (c) 1990, 1993 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "from: @(#)strtoul.c 8.1 (Berkeley) 6/4/93"; #else -__RCSID("$NetBSD: strtoull.c,v 1.2 2000/03/07 20:02:00 kleink Exp $"); +__RCSID("$NetBSD: strtoull.c,v 1.3 2000/05/02 12:39:03 is Exp $"); #endif #endif /* LIBC_SCCS and not lint */ @@ -75,6 +75,11 @@ strtoull(nptr, endptr, base) _DIAGASSERT(nptr != NULL); /* endptr may be NULL */ +#ifdef __GNUC__ + /* This outrageous construct works around an arm32 compiler bug. */ + (void) &acc; +#endif + /* * See strtol for comments as to the logic used. */ diff --git a/lib/libc/stdlib/strtouq.c b/lib/libc/stdlib/strtouq.c index 92ed6f195e3..7ccf4b94d9a 100644 --- a/lib/libc/stdlib/strtouq.c +++ b/lib/libc/stdlib/strtouq.c @@ -1,4 +1,4 @@ -/* $NetBSD: strtouq.c,v 1.14 2000/03/08 20:17:21 kleink Exp $ */ +/* $NetBSD: strtouq.c,v 1.15 2000/05/02 12:39:03 is Exp $ */ /*- * Copyright (c) 1992, 1993 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "@(#)strtouq.c 8.1 (Berkeley) 6/4/93"; #else -__RCSID("$NetBSD: strtouq.c,v 1.14 2000/03/08 20:17:21 kleink Exp $"); +__RCSID("$NetBSD: strtouq.c,v 1.15 2000/05/02 12:39:03 is Exp $"); #endif #endif /* LIBC_SCCS and not lint */ @@ -71,7 +71,7 @@ strtouq(nptr, endptr, base) /* endptr may be NULL */ #ifdef __GNUC__ - /* This outrageous construct just to shut up a GCC warning. */ + /* This outrageous construct works around an arm32 compiler bug. */ (void) &acc; #endif -- cgit