3 ms·
My favorite is still the Rust Container Cheat Sheet[0] from the Rust Performance Book[1]. Great overview on just one page - that's what I call a cheat sheet. E
by alpaca128 6y ago
My favorite is still the Rust Container Cheat Sheet[0] from the Rust Performance Book[1]. Great overview on just one page - that's what I call a cheat sheet.
Edit: Also recommended: The Little Book of Rust Macros[2]
[0] https://docs.google.com/presentation/d/1q-c7UAyrUlM-eZyTo1pd8SZ0qwA_wYxmPZVOQkoDmH4/edit#slide=id.p https://docs.google.com/presentation/d/1q-c7UAyrUlM-eZyTo1pd...
[1] https://nnethercote.github.io/perf-book/title-page.html https://nnethercote.github.io/perf-book/title-page.html
[2] https://veykril.github.io/tlborm/introduction.html https://veykril.github.io/tlborm/introduction.html
- est31 6y agoAnother container cheat sheet: https://i.redd.it/220xo2f6wci51.png https://i.redd.it/220xo2f6wci51.png https://oldreddit.com/r/rust/comments/idwlqu/rust_memory_container_cheatsheet_publish_on_github/ https://oldreddit.com/r/rust/comments/idwlqu/rust_memory_con...
- alpaca128 6y agoThanks, that looks helpful too. Note your second link seems to be missing a dot between "old" and "reddit".
- est31 6y ago> Note your second link seems to be missing a dot between "old" and "reddit". Oh indeed. I visited the link while logged in, but to share links I make the pre-redesign explicit. I guess a mistake occured during that. Can't edit the post any more, but the fixed link is: https://old.reddit.com/r/rust/comments/idwlqu/rust_memory_container_cheatsheet_publish_on_github/ https://old.reddit.com/r/rust/comments/idwlqu/rust_memory_co...
- raphlinus 6y agoThanks, appreciate the shout-out. I'll give a little background how that came about. At the time, I was promoting the use of Rust within Fuchsia. The team was largely composed of badass C++ programmers, who of course were very familiar with reasoning about programs in terms of exactly how things were laid out in memory. The official Rust documentation was at a more abstract level with respect to a lot of this stuff, in many case careful not to overspecify because a lot of the details of memory layout are not normative and may in fact change. In explaining the most common and important Rust data types, I found these kinds of diagrams useful, and it grew into the page you see there.