Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The way I like to think about the expression / statement divide in Rust is that everything is an expression, and the semicolon is an operator akin to `ignore` in F#; it takes any operands, disposes of them, and returns the unit type `()`.

Rust in general is just such a pleasant language. It can be a bit tedious to work with sometimes, but that's usually because the problem in question is tedious in and of itself, and you didn't even notice all of the little screw-ups that could occur until you saw how Rust dealt with it.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: