Support NaN and Infinity