Programming language release RUST 1.62

The release of the general purpose programming language Rust 1.62, founded by the Mozilla project, now developed under the auspices of the independent non -profit organization Rust Foundation. The language is focused on safe memory work and provides means to achieve a high parallelism of the tasks, while dispensing with the use of the garbage collector and Runtime (Runtime comes down to basic initialization and accompanying the standard library).

Memitory working methods in RUST save the developer from errors when manipulating with signs and protect against problems arising due to low-level memory, such as an appeal to the memory area after its release, the extension of the zero signs, exit beyond the buffer, etc. .P. To distribute libraries, ensure the assembly and management of dependence, the Cargo package manager develops. To place the libraries, the repository is supported by crates.io .

Safe memory work is ensured in RUST during compilation through references checking, tracking the ownership of objects, taking into account the lifetime of objects (visibility) and assessment of the correctness of access to memory during the performance of the code. RUST also provides means to protect against integer overflow, requires mandatory initialization of variables before use, better processes errors in a standard library, applies the concept of irreplaceability (Immutable) links and default variables, offers strong static typification to minimize logical errors.

The main innovations :

  • In the Cargo package manager, the Add command is proposed, which allows you to add new dependencies from the command line to the Cargo.toml manifesto or change available dependencies. The team also allows you to indicate individual properties and versions, for example: Cargo Add Serde -Features Derive Cargo Add Nom@5
  • added The possibility of using “#[derive (default)]” from
    Transitions (enum), in which using the attribute “#[Default]” the default option is determined. #[Derive (Default)] Enum Maybe { #[Default] Nothing, someting (t),}
  • Linux platform is involved more compact and fast implementation of the MUTEX synchronization mechanism, based on the use of FITEX provided by the Linux nucleus. Unlike the previously used implementation based on the Pthreads library, only 5 bytes are consumed in the new version to store the MUTEX condition instead of 40. Similarly, Condvar and Rwlock lock mechanisms are translated on FUTEX.
  • Implemented the second level of support for the target platform X86_64-Unknown-None, designed to form executable files capable of working without the operating system. For example, the specified target platform can be used when writing components of the nucleus. The second level of support involves the assembly guarantee.
/Media reports.