TechnologyProgramming language

Rust

Systems programming language that guarantees memory safety without a garbage collector through its ownership model, first stable in 2015.

Rust is a compiled systems programming language designed for performance and reliability. Its central idea is ownership: every value has a single owner, and the compiler's borrow checker enforces rules about how references are shared and changed. These checks prevent whole classes of bugs in safe code, including use-after-free errors and data races, without the runtime cost of garbage collection. Rust also offers pattern matching, algebraic data types, traits and Cargo, its build tool and package manager.

Graydon Hoare began Rust as a personal project in 2006, and Mozilla began sponsoring it in 2009, later using it in the Servo browser engine and in parts of Firefox. Version 1.0 was released in May 2015 with a commitment to backward compatibility. After Mozilla's 2020 layoffs affected the team, the independent Rust Foundation was formed in 2021 with founding members including Amazon Web Services, Google, Huawei, Microsoft and Mozilla. The compiler is distributed under the MIT and Apache 2.0 licenses.

Because a large share of serious security vulnerabilities in big C and C++ codebases stem from memory errors, Rust has attracted interest from operating system, browser and infrastructure developers, as well as from government agencies promoting memory-safe languages. Support for Rust drivers was merged into the Linux kernel in 2022. Its tradeoffs include a steep learning curve, long compile times and the need for unsafe code when interfacing with hardware or C libraries. It has topped developer surveys as a most-admired language for years.

Key points

  • Rust's ownership and borrowing rules prevent many memory bugs at compile time.
  • Graydon Hoare started Rust in 2006, and version 1.0 was released in 2015.
  • The Rust Foundation, formed in 2021, supports the language independently of Mozilla.
  • Linux added initial support for Rust kernel code in 2022.

Related entries

Organization

Rust Foundation

ProgrammingFOSS

Nonprofit foundation established in 2021 to support the Rust programming language, its maintainers and its shared infrastructure.

Organization

Mozilla

FOSSIdeas and Culture

Nonprofit-led organization, begun in 1998 from Netscape's open-source release, that develops the Firefox browser and advocates for an open internet.

Glossary term

Automatic memory management in which a language runtime finds and reclaims memory occupied by objects a program can no longer use.

Glossary term

Type Safety

Programming

Degree to which a programming language prevents type errors, in which a value is used as if it were a different, incompatible kind of data.

Glossary term

Concurrency

Programming

Ability of a program or system to make progress on several tasks during overlapping time periods, whether or not they literally run simultaneously.

Technology

C++

ProgrammingVideo Games

General-purpose programming language created by Bjarne Stroustrup as an extension of C, combining low-level control with high-level abstractions.

Technology

WebAssembly

Programming

Portable binary instruction format that lets code compiled from languages like C, C++ and Rust run safely at near-native speed in web browsers.

Technology

Linux

FOSSHardware

Free and open-source Unix-like kernel created by Linus Torvalds in 1991 that underpins Android, most servers and many embedded devices.

Referenced by

Other entries that discuss or point to Rust.