$diff the_book_2015 the_book_2018

Hello,

I ordered a paper copy of The Book, but realized after that it covers Rust 2015 - the missing 2018 bubble in Ferris pincer gave it away :crab: ...

I looked up the differences but cannot understand if it is major updates (a new impl Traits seems kind of big...) and I should order the updated version or if The book 2015 is sufficient for 99% of core concepts?

What do you advise?

Rust is backwards compatible, so the things in the book still work today, but there will be a bunch of stuff missing in your book.
You can find an up-to-date version of the book online: The Rust Programming Language - The Rust Programming Language

2 Likes

Most edition difference is covered in the Edition Guide: Introduction - The Rust Edition Guide

7 Likes

Thank you both! I saw this comparison between the two editions, but still I can't determine if the bunch of stuff is sufficiently important to send back the book and get a new one :slight_smile: (and wait two weeks :stuck_out_tongue:)

So with your background and everything you know, would you start learning from the older book?

If you don't mind the wait and can get a refund it's probably worth it sending the old one back and getting a new one. However the the old book is still good enough to get you started and you can come back to the new changes when you're more familiar with Rust.

3 Likes

We have a high-level summary of the differences between the two books on the front page of The Rust Programming Language - The Rust Programming Language --

This iteration of the book contains a number of changes to reflect those improvements:

  • Chapter 7, “Managing Growing Projects with Packages, Crates, and Modules,” has been mostly rewritten. The module system and the way paths work in the 2018 Edition were made more consistent.
  • Chapter 10 has new sections titled “Traits as Parameters” and “Returning Types that Implement Traits” that explain the new impl Trait syntax.
  • Chapter 11 has a new section titled “Using Result<T, E> in Tests” that shows how to write tests that use the ? operator.
  • The “Advanced Lifetimes” section in Chapter 19 was removed because compiler improvements have made the constructs in that section even rarer.
  • The previous Appendix D, “Macros,” has been expanded to include procedural macros and was moved to the “Macros” section in Chapter 19.
  • Appendix A, “Keywords,” also explains the new raw identifiers feature that enables code written in the 2015 Edition and the 2018 Edition to interoperate.
  • Appendix D is now titled “Useful Development Tools” and covers recently released tools that help you write Rust code.
  • We fixed a number of small errors and imprecise wording throughout the book. Thank you to the readers who reported them!

Hope that helps!

9 Likes

Thank you @carols10cents, and everyone :purple_heart: :grinning: :brown_heart:.
I saw those changes but I am incapable to understand how major there are (is there a dealbreaker somewhere :thinking:). In the end I got the new version, and will follow online for the time being.

And btw: How do you do when everyone comes up with a good solution? MUST I choose a solution?


Look what arrived at last. I feel more than ready after tinkering around a lot with embedded and the sokoban game!

5 Likes

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.