Programming language: Rust 1.55 is open at the top

By: MRT Desk

Published on:

Programming language: Rust 1.55 is open at the top

The Rust team has published version 1.55 of the programming language every six weeks. The release stabilizes this at the language level X..-Pattern for unsigned integer values ​​and includes an addition for the enumeration of I / O errors.

Under the hood, the standard library from Rust has recently started using the Eisel-Lemire algorithm for parsing floating point numbers. On the one hand, it should work more efficiently and, on the other hand, it should deliver more correct results. The previous parsing algorithm also led to an extreme slowdown in borderline cases. The implementation is based on the Crate, i.e. the Rust package, fast-float-rust onsupervised by Daniel Lemire.

With the open range pattern, the current version stabilizes a convenience function that describes a range that is open to the top for integer values:

match x as u32 {
  0 => println!("Null"),
  1.. => println!("positive Zahl"),
}

The new spelling is an abbreviation for 1..={integer}::MAX as an indication of the range from the desired number to the maximum integer value.

The release also extends the enumeration std::io::ErrorKind, which describes types of I / O errors to the entry ErrorKind::Uncategorized. The new value is only shown as an internal variant and should remain hidden. This means that it is not intended for explicit use in your own programs, but as a clear differentiation from ErrorKind::Other. The latter value is used to indicate your own I / O errors via std::io::Error, but at the same time it was also the system’s answer to errors that were not categorized.

The new entry enables a clear distinction, whereby developers use their own code in der Pattern-Syntax provided underscore _ should use to process the uncategorized cases.

On October 13th spins on the betterCode () Rust everything about the programming language Rust. The from heise Developer and dpunkt.verlag The online conference is primarily aimed at developers who have experience in other languages ​​such as C, C ++ or Java and who have an eye on Rust for new or to supplement existing projects.

The program spans the whole spectrum from the basics to microservices to practical use in security-critical applications. A look at the upcoming edition Rust 2021 is also included.

Finally, version 1.55 clears the compiler error messages for commands like cargo test and cargo check --all-targets that build the same crate in different configurations. Previously, the parallel compilation processes for the individual targets spewed up potentially the same warnings and errors. The current release deduplicates the entries so that the compiler only reports the same problem once.

Overall, as with version 1.54, the innovations are manageable. However, the team has big plans for this year with the new edition Rust 2021, which is scheduled to start as the next release on October 21. The public test phase for the third edition after Rust 2015 and Rust 2018 has been running since mid-July.

More details about Rust 1.55 can be found refer to the Rust blog. The full list of changes and new features can be found in den Release Notes. As usual, developers who have already installed Rust can download the current release from rustup update stable download. For those who are new to Rust, this is the rustup tool on the download page available separately. Rust 1.55 can also be called up directly from the heise download page.


(rme)

Article Source