-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Description
Here equality of NaN_1 to NaN fails
using SentinelArrays
NaN_1 = reinterpret(Float64, 0xffffd10000000000)
NaN_2 = reinterpret(Float64, 0x7ff8000000000000)
SentinelArray([NaN_1, 1.1], NaN, missing) # [NaN, 1.1]
SentinelArray([NaN_2, 2.2], NaN, missing) # [missing, 2.2]
Guessing: here https://github.com/JuliaData/SentinelArrays.jl/blob/v1.4.5/src/SentinelArrays.jl#L184-L185 defines to use === as comparison. Docstring for NaN says
Always use isnan or isequal for checking for NaN. Using x === NaN may give unexpected results
Julia 1.10.5, SentinelArrays v1.4.5
Metadata
Metadata
Assignees
Labels
No labels