/>
X
Business

Programming languages: The new version of Rust arrives with this long-awaited feature

The Rust release team has released version 1.53.0 of the well-liked programming language.
Written by Liam Tung, Contributing Writer on

Rust 1.53 has arrived and the release contains several changes to Rust libraries, including the IntoIterator trait for arrays, as well as updates to the compiler. 

According to the Rust release team, IntoIterator for arrays was a long-awaited feature but was not implemented before because of backward compatibility problems. 

This means you can now iterate over arrays by value: as Rust Library Team lead Mara Bos pointed out on Twitter, before IntoIterator for arrays arrived, "you could iterate over &[1,2,3] and &mut [1,2,3], but not over [1,2,3] directly."

SEE: 10 ways to prevent developer burnout (free PDF) (TechRepublic)

"The reason we didn't add it sooner was backwards compatibility," she explained.

"Technically we consider this type of breakage (adding a trait impl) 'minor' and acceptable. But there was too much code that would be broken by it."

The update follows the recent announcement that the Rust "2021 edition" should arrive in October and will make significant improvements to how Rust feels in practice. 

Identifiers in Rust can now also contain non-ascii characters. All valid identifier characters in Unicode as defined in UAX #31 can now be used except emoji.

With new characters now supported, the Rust compiler will warn about potentially confusing situations involving different scripts, such as identifiers that look very similar. 

This releases also contains dozens of stabilized application protocol interfaces and some changes to the Rust compiler.

SEE: What is Agile software development? Everything you need to know about delivering better code, faster

Other than the new release, there are bigger changes ahead for the language as its gets wider adoption by large tech firms, such as Google, which is backing the effort to make Rust a second language for Linux kernel development to C. 

The Internet Security Research Group (ISRG) this week announced it had hired a full-time developer to work on the Rust for Linux project with financial backing from Google. 

Google hopes the project will eliminate entire classes of security issues affecting Linux kernel code. It's also undertaking a similar Rust project for the Android Open Source Project code

Editorial standards

Related

Programming languages: How Google is using Rust to reduce memory safety vulnerabilities in Android
Rust

Programming languages: How Google is using Rust to reduce memory safety vulnerabilities in Android

Google rushes out Chrome browser fix for new zero-day flaw
hands-typing-on-a-laptop

Google rushes out Chrome browser fix for new zero-day flaw

Google shares details of newly found commercial spyware threats
hacking

Google shares details of newly found commercial spyware threats