3 ms·
The list of changes is tiny compared to the 2018 edition. The module system was a big change, and the macro changes caused quite a bit of breakage. Both were i
by the_duke 6y ago
The list of changes is tiny compared to the 2018 edition.
The module system was a big change, and the macro changes caused quite a bit of breakage. Both were important.
The changes here are nice to have, especially the partial struct borrowing. The prelude additions are convenient, but not terribly relevant anymore for me since rust-analyzer gained support for automatic trait imports. The new resolver is really helpful, but can also be changed in Cargo.toml. The new edition will just have the new resolver as the default.
This amount of changes would not lead to a breaking release in other languages. Which is a good thing!
Rust has been excellent about maintaining backwards compatability. The 2015 edition still works just fine on new compilers. Questionable changes are regularly tested against all crates on crates.io to prevent regressions. Developers also proactively submit fixes to crates for tiny breaking compiler/std fixes before they land.
The evolution of Rust has been very significant and impactful, while still remaining responsible and executed with a lot of competence, supported by good tooling.
I assume this edition is almost as much about maintaining institutional knowledge on how to do an edition as it is about the actual breaking features. It's quite easy to forget a lot of things over 6 years, so doing it regularly is important.
- jsmith45 6y agoIf they do the same as with Rust 2018, the actual list of changes in the Rust Edition Guide will be much larger, because they will list all of the major non-breaking changes since 2018 as part of 2021, even though most of them are available in all editions and have been ever since whatever version introduced them. The idea being that the editions guide documents "What is new since the day of release of the previous edition", in addition to documenting the changes specific to the new edition (which are generally breaking changes, or they would be made available to all editions). But still, the list of breaking changes here is quite small, and mostly some edge cases that will not impact the overwhelming majority of code.