tatterdemalion@programming.dev to Programmer Humor@programming.devEnglish · 1 year agoOh yea, that's the good stuff huffs glueprogramming.devimagemessage-square36fedilinkarrow-up1156
arrow-up1156imageOh yea, that's the good stuff huffs glueprogramming.devtatterdemalion@programming.dev to Programmer Humor@programming.devEnglish · 1 year agomessage-square36fedilink
minus-squareGissaMittJobb@lemmy.mllinkfedilinkarrow-up0·1 year agoSince all of the expressions just wrap a None, I wouldn’t be surprised if the transmutes basically get compiled to 0, making the assertion at the end assert_eq!(0 * 0, 0).
minus-squaretatterdemalion@programming.devOPlinkfedilinkarrow-up1·edit-21 year agoNah these are the actual integer representations. Otherwise you would have Some(None) == Some(Some(None)) which is way too Javascripty for Rust folks.
Since all of the expressions just wrap a
None
, I wouldn’t be surprised if the transmutes basically get compiled to0
, making the assertion at the endassert_eq!(0 * 0, 0)
.Nah these are the actual integer representations. Otherwise you would have
Some(None) == Some(Some(None))
which is way too Javascripty for Rust folks.