dustyweb has quit [Remote host closed the connection]
dustyweb has joined #sandstorm
dustyweb has quit [Remote host closed the connection]
dustyweb has joined #sandstorm
griff__ has quit [Quit: griff__]
griff__ has joined #sandstorm
griff__ has quit [Quit: griff__]
griff__ has joined #sandstorm
<simpson>
Redirect from #erights: How are the exceptional floats encoded? I think -0.0, Infinity, and -Infinity all encode to unique forms. How about NaN?
<simpson>
The context is canonicalizing buffers as a prelude to encryption and signing.
<isd>
capnproto doesn't do any normalization of floats whatsoever. The canonicalization algorithm can't even tell what's a float vs. an integer (all you can tell without a schema is "not pointer")
<isd>
So, good chance if you put NaNs in your message they may not come out the the same bytes.
<isd>
*to the
<isd>
I'm... not convinced this is worth worrying about. Relying on equality of floats is going to result in brittle software in general.