rubyspec/rubyspec — Issue #110: Array#pack should not test (or relax the expected value for) packing a NaN value
Author: BanzaiMan
Created: 2012-01-12 02:28:44+00:00
State: open

As discussed on https://bugs.ruby-lang.org/issues/5884, the value returned by `[0.0/0.0].pack("g")` and the like is indeterminate. We should either get rid of the existing specs, or relax the expected values so that either of the two possible NaN's (as defined in IEEE 754) can be returned.

MRI tests check only that `Array#pack` and `String#unpack` make a correct round trip.