Rust 1.38 release: Pipelined compilation for Cargo & more

According to statistics from GitHub, Rust is one of the fastest growing programming languages! The latest update for Rust includes a few changes to the library and pipelined compilation. See what’s added in the 1.38.0 stable release and how it can help cut down compilation speed in certain instances. Let’s take a closer look at the details.
According to GitHub, Rust is the 5th fastest growing programming language. More and more developers are coding in Rust, submitting PRs, contributing to open source, and creating new projects.
Rust-lang v1.38.0 stable arrived on September 26, 2019. Check out what’s new in the programming language, including pipelined compilation and a few library changes.
Feature highlight: Pipelined compilation
With this new release, Cargo will now automatically begin building dependent crates as soon as the metadata is ready.
Since you don’t need to wait for the dependencies to be fully built when compiling a crate, this may help improve some compilation speeds.
According to the announcement blog, this will likely not have a major effect on builds for single creates. However, Rust found an increase of 10-20% compilation speed for some crate graphs. Click here to find out more about testing pipelined rustc compilation out.
Check out this tool created for exploring crate graph build times. Be sure to have a look at the PR for enabling pipelined compilation by default.
SEE ALSO: How To Make Loveliness: an HTML treasure hunt
New lints for incorrect uses of mem::{uninitialized, zeroed}
We’re happy to announce the release of Rust 1.38.0, featuring pipelined compilation! Check out all the new features in our blog post:https://t.co/UN5NN4beju
— Rust Language (@rustlang) September 26, 2019
In a future release, mem::uninitialized
will be deprecated. Although not deprecated yet, this release limits some of its incorrect uses in order to prevent unsafe usage. Incorrect usage will result in a warning in order to help identify incorrect code.
However, this update does not include every unsound usage. Thus, in order to play it safe, users should move their code to MaybeUninit
instead.
#[deprecated]
attribute change
Now, the #[deprecated]
attribute can be used on macros.
#[global_allocator]
attribute change
The #[global_allocator]
attribute can now be used in submodules.
Library changes
This version includes a variety of changes made to the library. Taken from the release notes on GitHub, these changes include:
ascii::EscapeDefault
now implementsClone
andDisplay
.- Derive macros for prelude traits (e.g.
Clone
,Debug
,Hash
) are now available at the same path as the trait. (e.g. TheClone
derive macro is available atstd::clone::Clone
). This also makes all built-in macros available instd
/core
root. e.g.std::include_bytes!
. str::Chars
now implementsDebug
.slice::{concat, connect, join}
now accepts&[T]
in addition to&T
.*const T
and*mut T
now implementmarker::Unpin
.Arc<[T]>
andRc<[T]>
now implementFromIterator<T>
.- Added euclidean remainder and division operations (
div_euclid
,rem_euclid
) to all numeric primitives. Additionallychecked
,overflowing
, andwrapping
versions are available for all integer primitives. thread::AccessError
now implementsClone
,Copy
,Eq
,Error
, andPartialEq
.iter::{StepBy, Peekable, Take}
now implementDoubleEndedIterator
.
What features or changes do you want to see in future releases?
For more information about the newest update and a full list of changes, view the Rust 1.38.0 blog post, or browse the release notes on GitHub.