Before you run it, try to guess the value of wat. val n = 0.0/0.0 val set = Set(n, n) val wat = (set ++ set).size
@d6 Yes. How did you work it out? ;) Looks like a subtlety in comparisons sometimes being done boxed, other times unboxed...
-
-
@propensive@d6 isn't basically what@extempore2 describe in his numerous rants? -
@aloiscochard@d6@extempore2 Don't think so, but maybe I missed it, or I'm misinterpreting. This seems specific to NaNs.
End of conversation
New conversation -
-
-
@propensive I was pretty sure Set(n,n).size was 2 and I figured Set's ++ might have an ill-advised eq hack. -
@propensive I tested this, you can see it with: val other = Set(n,n) (set++set).size==2 (set++other).size==4 (set+n).size==3 - Show replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.