diff mbox

Fix gcc.dg/builtins-67.c on Solaris 8/9

Message ID 201110131426.39238.ebotcazou@adacore.com
State New
Headers show

Commit Message

Eric Botcazou Oct. 13, 2011, 12:26 p.m. UTC
[To the right list this time]

The test fails with a link error, as 'round' and 'rint' are only C99.

Fixed thusly, tested on SPARC/Solaris 8, applied on the mainline as obvious.


2011-10-13  Eric Botcazou  <ebotcazou@adacore.com>

	* gcc.dg/builtins-67.c: Guard iround and irint with HAVE_C99_RUNTIME.
diff mbox

Patch

Index: gcc.dg/builtins-67.c
===================================================================
--- gcc.dg/builtins-67.c	(revision 179844)
+++ gcc.dg/builtins-67.c	(working copy)
@@ -58,14 +58,14 @@  long long llceilf (float a) { return (lo
 long long llceill (long double a) { return (long long) ceill (a); }
 #endif
 
-int iround (double a) { return (int) round (a); }
 #ifdef HAVE_C99_RUNTIME
+int iround (double a) { return (int) round (a); }
 int iroundf (float a) { return (int) roundf (a); }
 int iroundl (long double a) { return (int) roundl (a); }
 #endif
 
-int irint (double a) { return (int) rint (a); }
 #ifdef HAVE_C99_RUNTIME
+int irint (double a) { return (int) rint (a); }
 int irintf (float a) { return (int) rintf (a); }
 int irintl (long double a) { return (int) rintl (a); }
 #endif