pradosoft / prado

Prado - Component Framework for PHP
Other
187 stars 70 forks source link

TBitHelper:: floatToFpXX Better Compliance to PHP binary format of NAN #937

Closed belisoful closed 1 year ago

belisoful commented 1 year ago

float IEEE format INF vs NAN depends on if the mantissa is 0 or not. Any value of mantissa is NAN and is valid for NAN. But PHP picks a specific value for NAN that we mimic here as a standard.