Rust团队发布了Rust 1.100.0稳定版本 1。其中,历时十年且此前尝试5次失败的Never类型(!)在该版本中正式稳定 1。该版本还引入了用于在作用域退出时运行闭包的 core::mem::DropGuard,以及用于构造零大小类型的 std::mem::conjure_zst 1。此外,allocator_api的核心部分也已稳定,允许定义自定义分配器 1。
在工具链方面,Cargo新增了报告未使用依赖项的功能,并优化了缓存目录结构以减少碰撞 1。为了缓解供应链攻击风险,Cargo推出了“最小发布年龄”(min-publish-age)特性,通过设置依赖冷却期防止恶意包被立即采用 1。
The Rust team has released version 1.100.0, a stable update that formally stabilizes the Never type (!) after a decade of development efforts 1. This milestone feature had previously failed in five earlier attempts before its successful inclusion in this release 1. The new version also introduces significant core library capabilities, including core::mem::DropGuard for executing closures upon scope exit, std::mem::conjure_zst for constructing zero-sized types, and the stabilization of key parts of the allocator_api to allow for custom allocator definitions 1.
In addition to language and library changes, the Cargo toolchain receives critical security and usability improvements. A new "min-publish-age" feature is introduced to mitigate supply chain attacks by preventing malicious packages from being immediately adopted 1. Cargo now also reports unused dependencies to help developers clean up their projects, while optimizations to the cache directory structure aim to reduce collisions 1.
评论
还没有评论,欢迎留下第一条。