X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl.h;h=2b4465c6016b59709d7ce08db3b05860768a604b;hb=9f1b1f2d9ab55954ee07a14c4ab04bd3dd1f99d5;hp=ab59e0236051303d0873543e8b839834a22ee009;hpb=e3de763fefffba137325d332b66195fbf603e080;p=p5sagit%2Fp5-mst-13.2.git diff --git a/perl.h b/perl.h index ab59e02..2b4465c 100644 --- a/perl.h +++ b/perl.h @@ -1145,8 +1145,15 @@ typedef NVTYPE NV; # endif # define NV_DIG LDBL_DIG # ifdef HAS_SQRTL -# define Perl_modf modfl -# define Perl_frexp frexpl + /* libsunmath doesn't have modfl and frexpl as of mid-March 2000 */ + /* XXX Configure probe for modfl and frexpl needed XXX */ +# if defined(__sun) && defined(__svr4) +# define Perl_modf(x,y) ((long double)modf((double)(x),(double*)(y))) +# define Perl_frexp(x) ((long double)frexp((double)(x))) +# else +# define Perl_modf modfl +# define Perl_frexp frexpl +# endif # define Perl_cos cosl # define Perl_sin sinl # define Perl_sqrt sqrtl @@ -3082,9 +3089,6 @@ typedef struct am_table_short AMTS; # if !defined(Strtol) && defined(HAS_STRTOLL) # define Strtol strtoll # endif -# if !defined(Strtol) && defined(HAS_ATOLL) -# define Strtol atoll -# endif /* is there atoq() anywhere? */ #endif #if !defined(Strtol) && defined(HAS_STRTOL) @@ -3093,8 +3097,12 @@ typedef struct am_table_short AMTS; #ifndef Atol /* It would be more fashionable to use Strtol() to define atol() * (as is done for Atoul(), see below) but for backward compatibility - * we just assume and use atol(). */ -# define Atol atol + * we just assume atol(). */ +# if defined(USE_64_BIT_INT) && defined(IV_IS_QUAD) && QUADKIND == QUAD_IS_LONG_LONG && defined(HAS_ATOLL) +# define Atol atoll +# else +# define Atol atol +# endif #endif #if !defined(Strtoul) && defined(USE_64_BIT_INT) && defined(UV_IS_QUAD) && QUADKIND == QUAD_IS_LONG_LONG @@ -3113,7 +3121,7 @@ typedef struct am_table_short AMTS; # define Strtoul strtoul #endif #ifndef Atoul -# define Atoul Strtoul(s, (char **)NULL, 10) +# define Atoul(s) Strtoul(s, (char **)NULL, 10) #endif #if !defined(PERLIO_IS_STDIO) && defined(HASATTRIBUTE)