Xylight (Photon dev) to Programmer [email protected] • 1 year agoI don't want to use ternarieslemmy.xylight.devimagemessage-square18fedilinkarrow-up1148arrow-down111
arrow-up1137arrow-down1imageI don't want to use ternarieslemmy.xylight.devXylight (Photon dev) to Programmer [email protected] • 1 year agomessage-square18fedilink
minus-squareOro [she/they]linkfedilink9•edit-21 year agoThe whole idea of expressions is very nice, and I can’t imagine using ternary expressions anywhere after learning Rust. Also implicit returns ❤️
minus-square@[email protected]linkfedilink1•1 year agoI never got to like implicit anything. Not even returns. Ever.
minus-square@[email protected]linkfedilinkEnglish1•1 year agoYou get used to it pretty quickly. After a while you wonder how you ever lives without it. Explicit returns feel like ending an if with endif. The end of the conditional’s scope is implied by the end of the block by } or whatever.
The whole idea of expressions is very nice, and I can’t imagine using ternary expressions anywhere after learning Rust.
Also implicit returns ❤️
I never got to like implicit anything.
Not even returns. Ever.
You get used to it pretty quickly. After a while you wonder how you ever lives without it. Explicit returns feel like ending an
if
withendif
. The end of the conditional’s scope is implied by the end of the block by}
or whatever.