We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3463a3d commit 5d3b97bCopy full SHA for 5d3b97b
test/lambdaisland/deep_diff2/diff_test.cljc
@@ -199,7 +199,8 @@
199
;; (not= ##NaN ##NaN), which messes up test results
200
;; https://stackoverflow.com/questions/16983955/check-for-nan-in-clojurescript
201
(defn NaN? [node]
202
- #?(:clj false
+;; Need to confirm that it's a Double first.
203
+ #?(:clj (and (instance? Double node) (Double/isNaN node))
204
:cljs
205
(and (= (.call js/toString node) (str "[object Number]"))
206
(js/eval (str node " != +" node )))))
0 commit comments