Use ldexpl() instead of ldexp()

This will fix "warning: conversion from ‘long double’ to
‘double’ may change value [-Wfloat-conversion]".
This commit is contained in:
Urs Fleisch
2025-06-22 07:49:37 +02:00
parent 148cc9a921
commit eb749ac55b

View File

@ -237,7 +237,7 @@ long double toFloat80(const ByteVector &v, size_t offset)
debug("toFloat80() - can't handle the infinity or NaN. Returning 0.");
return 0.0;
}
val = ::ldexp(static_cast<long double>(fraction), exponent - 16383 - 63);
val = ::ldexpl(static_cast<long double>(fraction), exponent - 16383 - 63);
}
if(negative)