Rust 1.84 Adds Strict Provenance APIs
Written by Kay Ewbank   
Thursday, 16 January 2025

Rust 1.84 has been released with changes including a move to a new trait solver and a set of Strict Provenance APIs.

Rust is popular for situations including being embedded in other languages, writing programs with specific space and time requirements, and writing low-level code.

rust foundation logo

Rust is developing rapidly as the regular updates show. The changes to this release start with the addition of strict provenance APIs. These are designed to deal with the fact that in Rust, pointers have provenance; to fully characterize pointer-related undefined behavior in Rust, you have to know not only the address the pointer points to, but also track which other pointer(s) it is "derived from". This isn't usually something programmers need to worry about, but when casting pointers to integers and back, the provenance of the resulting pointer is under specified. With this release, Rust is adding a set of APIs that can in many cases replace the use of integer-pointer-casts, and therefore avoid the ambiguities inherent to such casts.

The Rust developers say the new APIs should simplify code so it is easier for the compiler to analyze, and more understandable for developers too.

The second change is a step on Rust's move to a new implementation for the trait solver. The next-generation trait solver is a re-implementation of a core component of Rust's type system. It checks whether trait-bounds hold, and is also used by many other parts of the type system, such as normalization. In this release, the new solver is used for checking coherence of trait impls.

The third improvement of note is a stabilization of the minimum supported Rust version (MSRV) aware resolver. The developers say that MSRV-aware version selection reduces the work for maintainers in supporting older toolchains because they no longer need to manually select older versions for each dependency. 

This release also has minor improvements to Rust itself, Cargo and Clippy.

Version 1.84 of Rust is available now.

rust foundation logo

More Information

Rust Foundation Website

Related Articles

Rust 1.83 Improves Const Context Code Handling

Rust 1.82 Improves Apple Support

RustConf Keynotes Announced

Is Rust Safe?

Rust Foundation Announces Safety-Critical Consortium

Rust 1.72 Stabilizes APIs

To be informed about new articles on I Programmer, sign up for our weekly newsletter, subscribe to the RSS feed and follow us on Twitter, Facebook or Linkedin.

Banner


Can You Solve The GCHQ Christmas Challenge 2024
20/12/2024

The GCHQ Christmas Challenge has become a pre-Christmas tradition. While it is primarily targeted at school students working in teams, GCHQ encourages both children and adults to give it a try.



Learn To Code With Scrimba
27/12/2024

Scrimba is an online interactive coding platform that aims to make learning to code fun and accessible. It offers courses on web development, including HTML, CSS, JavaScript and React and also has an  [ ... ]


More News

espbook

 

Comments




or email your comment to: comments@i-programmer.info