Article | REF: H3098 V2

Rust Programming Language

Author: Laurent BLOCH

Publication date: June 10, 2022, Review date: February 29, 2024

You do not have access to this resource.
Click here to request your free trial access!

Already subscribed? Log in!


Overview

Français

ABSTRACT

The Rust programming language is intended to write high performance software, through a low-level, hardware-near, operating system-near design. From this perspective, Rust is quite similar to the C language. Rust may also enable parallel and distributed programming, as well as functional programming. In comparison with C, Rust provides heightened run-time security through an innovative memory management system and a mandatory strong typing system. Rust comes with no run-time environment, which contributes to higher efficiency, in comparison with languages like Java. Cargo, Rust's build system and package manager, is helpful to build large and complex software.

Read this article from a comprehensive knowledge base, updated and supplemented with articles reviewed by scientific committees.

Read the article

AUTHOR

 INTRODUCTION

The Rust programming language was designed with three objectives in mind: security, speed, and concurrent and parallel programming:

  • security is achieved through data typing, the memory model and precise rules for passing parameters between functions (data possession and borrowing model);

  • speed is achieved by the proximity of language objects to machine objects, and by the absence of a runtime environment to load at startup;

  • concurrent and parallel programming is facilitated by asynchronous processing, inter-task data sharing, message passing and rendezvous functions, which enable concurrent or parallel tasks to be programmed without directly using the operating system's primitive functions.

The preliminary version of Rust was released in 2010 by the Mozilla Foundation, which publishes the Firefox browser; initially it was a personal project (developed in OCaml) of foundation employee Graydon Hoare; the first stable version was released in 2015. It's an open-source program developed with the participation of users. The compiler produces an intermediate representation in LLVM code.

This language can be described as combining the qualities of C and Ada. It borrows most of its syntax from C, with the addition of Ada-like forms, for example for writing (and compiling) the specification and implementation of a function separately. Like C, Rust has no runtime environment, and in particular no garbage collector (GC, an automatic memory management system); its elementary objects remain close to those of the machine, which contributes to predictable performance that can approach that of assembler. Rust also provides higher-level constructs, such as UTF-8 strings.

Like Ada, Rust implements strong and constraining typing, which is sometimes demanding for the programmer, but provides a high degree of program reliability once it has been successfully compiled. Like Ada, Rust provides functions for programming concurrent or parallel tasks independently of the operating system. The language also provides features for writing generic code and data polymorphism, always respecting the type system. Functional and object-oriented programming are also available.

These characteristics make Rust a suitable language for programming operating system functions and, as such, it is now accepted for contributions to the Linux kernel. But it is also used for all kinds of other projects, such as the graphics rendering and parallelism engines in the Firefox browser, parts of the Discord online sharing system, and parts of Microsoft's Azure and Amazon's AWS cloud platforms.

The standard Rust language...

You do not have access to this resource.

Exclusive to subscribers. 97% yet to be discovered!

You do not have access to this resource.
Click here to request your free trial access!

Already subscribed? Log in!


The Ultimate Scientific and Technical Reference

A Comprehensive Knowledge Base, with over 1,200 authors and 100 scientific advisors
+ More than 10,000 articles and 1,000 how-to sheets, over 800 new or updated articles every year
From design to prototyping, right through to industrialization, the reference for securing the development of your industrial projects

KEYWORDS

state of art   |   computer programming   |   system software   |   parallelism   |   modularity   |   ownership


This article is included in

Software technologies and System architectures

This offer includes:

Knowledge Base

Updated and enriched with articles validated by our scientific committees

Services

A set of exclusive tools to complement the resources

Practical Path

Operational and didactic, to guarantee the acquisition of transversal skills

Doc & Quiz

Interactive articles with quizzes, for constructive reading

Subscribe now!

Ongoing reading
Rust (programming language)