use more idiomatic NegativeInfinity and NaN