Series: The Rust Annals

Vol. I Issue 27 nlopes.dev

Announcing Rust 1.26

Routine minor release with standard library DX improvements and Cargo backend optimizations, lacking major language or milestone significance.

Library stabilizations

We stabilized fs::read_to_string, a convenience over File::open and io::Read::read_to_string for easily reading an entire file into memory at once:

use std::fs;
use std::net::SocketAddr;

let foo: SocketAddr = fs::read_to_string("address.txt")?.parse()?;

You can now format numbers as hexadecimal with Debug formatting:

assert!(format!("{:02x?}", b"Foo\0") == "[46, 6f, 6f, 00]")

Trailing commas are now supported by all macros in the standard library.

See the detailed release notes for more.

Cargo features

Cargo didn’t receive many big new features this release but rather saw a steady stream of stability and performance improvements. Cargo should now resolve lock files even faster, backtrack more intelligently, and require manual cargo update invocations less. Cargo’s binary now also shares the same version as rustc.

See the detailed release notes for more.

18 contributors to this release.

Reproduced from the Rust blog under its publication licence. Typeset in Literata.