damn, Golang is picky! https://octodon.social/media/rPvteRvL9otauckN9fk
man idk, Rust is putting up way more of a fight than Golang did for me... I guess that's kind of by design though. https://octodon.social/media/yjYuGa_nH0PH-WbDscA
@schlink `match` in Rust is much more than a switch statement; it can be used for error handling, object destructuring, and custom pattern matching.
Rust's Iterator class is very advanced, providing functions similar to Ruby's Enumerable like `any`, `all`, `find`, `partition`, and for your blog post, `sum`: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.sum
@schlink I'm reaching out to see if we can get that error message improved. In my personal experience I've been impressed by the number of errors that included a suggested fix 😻 https://twitter.com/seanlinsley/status/932040007069720576
@seanlinsley cool!
Sum seems to work just as advertised, but separately I'm running into some logic problems with the actual tic-tac-toe game, fyi
@schlink I forget if it was an issue that you ran into, but the just-released new version makes it so `*` (de-reference) isn't needed for `+=` https://blog.rust-lang.org/2017/11/22/Rust-1.22.html
@seanlinsley ha alright, alright I'll make an edit for `match`.
And dammmnnnn re: sum. That's slick. Did not see that.