Taking a tip from the Java code base, try using .CompareTo
and test for the zero comparison. This assumes the .CompareTo
function takes in to account floating point equality in an accurate manner. For instance,
System.Math.PI.CompareTo(System.Math.PI) == 0
This predicate should return true
.