Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Rust Essentials

You're reading from   Rust Essentials A quick guide to writing fast, safe, and concurrent systems and applications

Arrow left icon
Product type Paperback
Published in Nov 2017
Publisher
ISBN-13 9781788390019
Length 264 pages
Edition 2nd Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Ivo Balbaert Ivo Balbaert
Author Profile Icon Ivo Balbaert
Ivo Balbaert
Arrow right icon
View More author details
Toc

Table of Contents (13) Chapters Close

Preface 1. Starting with Rust FREE CHAPTER 2. Using Variables and Types 3. Using Functions and Control Structures 4. Structuring Data and Matching Patterns 5. Higher Order Functions and Error-Handling 6. Using Traits and OOP in Rust 7. Ensuring Memory Safety and Pointers 8. Organizing Code and Macros 9. Concurrency - Coding for Multicore Execution 10. Programming at the Boundaries 11. Exploring the Standard Library 12. The Ecosystem of Crates

The stability of Rust and its evolution

Rust started out with version 1.0.0, and, at the time of writing, the current version is 1.20.0. Version numbers follow the semantic versioning principle (see http://semver.org/ for further information):

  • Patch release: For bug fixes and other minor changes, increment the last number, for example 1.18.1
  • Minor release: For new features which don't break existing features, increment the middle number, for example 1.19.0
  • Major release: For changes which break backwards compatibility, increment the first number, for example 2.0.0

So, no breaking changes will occur during the current 1.n.m cycle versions, as this cycle is backward compatible; Rust projects which are developed in the older versions of this cycle will still compile in a more recent version. However, to be able to work with new features which are only contained in the more recent version, it is mandatory to compile your code to that specific version.

Rust has a very dynamic cycle of progression. Work is performed on three releases (called channels or builds simultaneously)--nightly, beta, and stable, and they follow a strict six-week release cycle like web browsers:

  • The stable channel is the current stable release, which is advocated for Rust projects that are being used in production.
  • The beta channel is where new features are deemed stable enough to be tested out in bigger, non-deployed projects.
  • The nightly channel build contains the latest experimental features; it is produced from the master branch every 24 hours. You would use it only for experimentation.

The beta and stable channel builds are only updated as new features are backported to their branch. With this arrangement, Rust allows users to access new features and bug fixes quickly.

Here is a concrete example: 1.18 was released on 18th June, 2017, the 1.19-beta was released at the same time, and the master development branch was advanced to 1.20. Six weeks later, on 30th July, Rust 1.19 will come out of beta and become a stable release, 1.20 will be promoted to 1.21-beta, and the master will become the eventual 1.21.

Some features in an experimental stage can only work when the code contains an attribute #[feature]. These may not be used on the stable release channel, only on a beta or nightly release; an example is the box syntax (see chapter 2\code\references.rs).

You have been reading a chapter from
Rust Essentials - Second Edition
Published in: Nov 2017
Publisher:
ISBN-13: 9781788390019
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime