Re: BUG #2162: Same as bug #1679 - finite() - unresolved symbol - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #2162: Same as bug #1679 - finite() - unresolved symbol
Date
Msg-id 2266.1137094106@sss.pgh.pa.us
Whole thread Raw
In response to Re: BUG #2162: Same as bug #1679 - finite() - unresolved symbol  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-bugs
Peter Eisentraut <peter_e@gmx.net> writes:
> Am Donnerstag, 12. Januar 2006 09:57 schrieb Tom Lane:
>> In principle an aggressive compiler could still determine that the
>> global variable is modified nowhere else in the executable.

> I think to do that the compiler would have to prove what the dynamic linker
> will do at run time.

Yeah.  The idea of casting a function pointer to (double *) seems mighty
ugly, and in the absence of evidence that we need it, I think it's
better to stick with less surprising code.  I've committed changes to
make the tests look like this:

AC_TRY_LINK([
#include <math.h>
double glob_double;
],
            [return finite(glob_double) ? 0 : 1;],
            [AC_DEFINE(HAVE_FINITE, 1, [Define to 1 if you have finite().])
AC_MSG_RESULT(yes)],
            [AC_MSG_RESULT(no)])


            regards, tom lane

pgsql-bugs by date:

Previous
From: Jaime Casanova
Date:
Subject: Re: BUG #2166: attempted to update invisible tuple
Next
From: Tom Lane
Date:
Subject: Re: BUG #2166: attempted to update invisible tuple