This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Explicitly cast to MANTISSATYPE since some compilers worry.
authorJarkko Hietaniemi <jhi@iki.fi>
Sun, 24 Aug 2014 01:43:17 +0000 (21:43 -0400)
committerJarkko Hietaniemi <jhi@iki.fi>
Sun, 24 Aug 2014 01:43:17 +0000 (21:43 -0400)
sv.c

diff --git a/sv.c b/sv.c
index 1900fa9..e5e1620 100644 (file)
--- a/sv.c
+++ b/sv.c
@@ -10802,7 +10802,7 @@ S_hextract(pTHX_ const NV nv, int* exponent, U8* vhex, U8* vend)
      * nv (as opposed to the long double method), but instead the UV
      * retrieved with the frexp+ldexp invocation. */
 #  if MANTISSASIZE * 8 > NV_MANT_DIG
-    MANTISSATYPE mantissa = Perl_ldexp(norm, NV_MANT_DIG);
+    MANTISSATYPE mantissa = (MANTISSATYPE)Perl_ldexp(norm, NV_MANT_DIG);
     int limit_byte = (NV_MANT_DIG - 1) / 8;
 #  else
     /* There will be low-order precision loss.  Try to salvage as many