by killercup · 11y ago · 0 comments
I like to think that Rust wants you to be familiar with C and ML syntax and philosophies before getting comfortable :)
The array type syntax you quoted is a bit like Haskell's `[Char]` syntax with a fixed-length property bolted on. You are right, though, that semicolon looks a bit weird. I guess using commas was not an option because the same syntax on the right hand side of the `=` means `[0, 0]`, i.e. two elements which are 0.
No comments yet.