Info
This post is auto-generated from RSS feed The Rust Programming Language Forum - Latest topics. Source: Edition and Version: Thoughts and Request for Feedback
Edition and Version: Thoughts and Request for Feedback
โ Rust ๐ 2025-07-17 ๐ค surdeus ๐๏ธ 2Iโd like to check whether this understanding is sound, and whether there are any other important aspects worth knowing.
In the reference for cargo.toml
/ manifest there is the distinction between Version and Edition that I overlooked as a newcomer. Reading the individual descriptions for version, and edition didn't fully clarify the distinction for me.
However, I found the forum discussion, which I'd summarise as follows:
An example of a breaking change (Edition) is given in The Rust Editions Guide where they explain how async
would have broken code like let async = 1
. So it's a change included in an edition. Code using lower editions can't use that functionality.
Code that isn't breaking, like the recent let chains would not be a breaking change.
Hence, projects using edition 2015 can use version 1.88 and let else
chains.
I initially wrote this as a question about "Why not to use the major slot in rust-version to include such breaking changes?" But the answer is: the rust-version allows for any edition to use the non-breaking changes. Using a single version identifier would block some projects from using those non breaking changes.
Another interesting bit in the guide cited above is that neither version nor edition changes are ecosystem-breaking; any crate can use any version / edition combination without issues.
1 post - 1 participant
๐ท๏ธ rust_feed