In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/c06e9e3e91dfb6869cd574591879d5f27aee366c?hp=bcfcd7d8d54edbbd1a6d43b2413593cab4a9d746>
- Log ----------------------------------------------------------------- commit c06e9e3e91dfb6869cd574591879d5f27aee366c Author: Jarkko Hietaniemi <[email protected]> Date: Sat Sep 13 07:57:12 2014 -0400 Use HAS_ISFINITE for Perl_isfinitel. M perl.h commit 7dc3eb737fb34d2d43c4a47e2d2602903d202097 Author: Jarkko Hietaniemi <[email protected]> Date: Sat Sep 13 07:55:27 2014 -0400 HAS_C99 comment tweak. M perl.h commit 93cec936ebced505ed56696d217c9ccdd342601f Author: Jarkko Hietaniemi <[email protected]> Date: Sat Sep 13 07:38:59 2014 -0400 Need to have frexpl for long doubles. M sv.c ----------------------------------------------------------------------- Summary of changes: perl.h | 9 ++++++--- sv.c | 4 +++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/perl.h b/perl.h index 29c739b..39ce4ca 100644 --- a/perl.h +++ b/perl.h @@ -28,9 +28,12 @@ # include "config.h" #endif -/* Note that with gcc -std=c89 the __STDC_VERSION__ is *not* defined +/* NOTE 1: that with gcc -std=c89 the __STDC_VERSION__ is *not* defined * because the __STDC_VERSION__ became a thing only with C90. Therefore, - * with gcc, HAS_C99 will never become true as long as we use -std=c89. */ + * with gcc, HAS_C99 will never become true as long as we use -std=c89. + + * NOTE 2: headers lie. Do not expect that if HAS_C99 gets to be true, + * all the C99 features are there and are correct. */ #if (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) || \ defined(_STDC_C99) # define HAS_C99 1 @@ -2311,7 +2314,7 @@ int isnan(double d); #if defined(HAS_LONG_DOUBLE) && !defined(Perl_isfinitel) /* If isfinite() is a macro and looks like we have C99, * we assume it's the type-aware C99 isfinite(). */ -# if defined(isfinite) && defined(HAS_C99) +# if defined(HAS_ISFINITE) && defined(isfinite) && defined(HAS_C99) # define Perl_isfinitel(x) isfinite(x) # elif defined(HAS_ISFINITEL) # define Perl_isfinitel(x) isfinitel(x) diff --git a/sv.c b/sv.c index 1ae347a..7791067 100644 --- a/sv.c +++ b/sv.c @@ -11069,7 +11069,9 @@ Perl_sv_vcatpvfn_flags(pTHX_ SV *const sv, const char *const pat, const STRLEN p * the time it is not (most compilers these days recognize * "long double", even if only as a synonym for "double"). */ -#if defined(HAS_LONG_DOUBLE) && LONG_DOUBLESIZE > DOUBLESIZE +#if defined(HAS_LONG_DOUBLE) && \ + LONG_DOUBLESIZE > DOUBLESIZE && \ + defined(HAS_FREXPL) long double fv; # define FV_ISFINITE Perl_isfinitel # define FV_FREXP frexpl -- Perl5 Master Repository
