jscript: Properly test if double may be converted to int32.