The only piece of surface-level syntax that I'm really truly bothered by is the closure syntax:
fn_with_a_callback_1(|param| param + 2);
fn_with_a_callback_2(|param| {
println!("{}", param);
});
- The fact that the | | is the same character on each side- The lack of directionality from the args -> to the body
- The lack of any kind of overlap with the normal function syntax fn foo()
Especially compared with something like JavaScript which has a really lovely lambda syntax, this one's hard to look at. I'm sure there were good reasons around ambiguity with other syntaxes or something, but... eesh.