TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Planning the Rust 2021 Edition

78 点作者 qw3rty01大约 4 年前

4 条评论

the_duke大约 4 年前
The list of changes is tiny compared to the 2018 edition.<p>The module system was a big change, and the macro changes caused quite a bit of breakage. Both were important.<p>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.<p>This amount of changes would not lead to a breaking release in other languages. Which is a good thing!<p>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&#x2F;std fixes before they land.<p>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.<p>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&#x27;s quite easy to forget a lot of things over 6 years, so doing it regularly is important.
评论 #26356514 未加载
brundolf大约 4 年前
It&#x27;s amazing to see how few backwards-incompatible changes have come out of <i>three years</i> of language evolution. Really speaks to how mature Rust has become.
评论 #26349203 未加载
xiphias2大约 4 年前
This list is boring, which is a great thing.<p>Evolving infrastructure around the language is much more important than evolving the language at this point.
评论 #26349671 未加载
Narann大约 4 年前
What is the difference between Rust XXXX edition and Rust X.X version?<p>I suspect it&#x27;s simply a limitation of features to let the compiler version improve but have an explicit list of supported&#x2F;unsupported feature every 4 years to avoid the fragmentation.<p>But I can&#x27;t find information about this on the article.
评论 #26356316 未加载