|
| 1 | +--- |
| 2 | +layout: post |
| 3 | +title: "Announcing Rust 1.31.1" |
| 4 | +author: The Rust Release Team |
| 5 | +--- |
| 6 | + |
| 7 | +The Rust team is happy to announce a new version of Rust, 1.31.1. Rust is a |
| 8 | +systems programming language focused on safety, speed, and concurrency. |
| 9 | + |
| 10 | +If you have a previous version of Rust installed via rustup, getting Rust |
| 11 | +1.31.1 is as easy as: |
| 12 | + |
| 13 | +``` |
| 14 | +$ rustup update stable |
| 15 | +``` |
| 16 | + |
| 17 | +If you don't have it already, you can [get `rustup`][install] from the |
| 18 | +appropriate page on our website, and check out the [detailed release notes for |
| 19 | +1.31.1][notes] on GitHub. |
| 20 | + |
| 21 | +[install]: https://www.rust-lang.org/install.html |
| 22 | +[notes]: https://github.com/rust-lang/rust/blob/master/RELEASES.md#version-1311-2018-12-20 |
| 23 | + |
| 24 | +## What's in 1.31.1 stable |
| 25 | + |
| 26 | +This patch release fixes a build failure on `powerpc-unknown-netbsd` by |
| 27 | +way of [an update to the `libc` |
| 28 | +crate](https://github.com/rust-lang/rust/pull/56562) used by the compiler. |
| 29 | + |
| 30 | +Additionally, the Rust Language Server was updated to fix two critical bugs. |
| 31 | +First, [hovering over the type with documentation above single-line |
| 32 | +attributes led to 100% CPU |
| 33 | +usage:](https://github.com/rust-lang/rls/pull/1170) |
| 34 | + |
| 35 | +```rust |
| 36 | +/// Some documentation |
| 37 | +#[derive(Debug)] // Multiple, single-line |
| 38 | +#[allow(missing_docs)] // atributes |
| 39 | +pub struct MyStruct { /* ... */ } |
| 40 | +``` |
| 41 | + |
| 42 | +[Go to definition was fixed for std types](https://github.com/rust-lang/rls/pull/1171): |
| 43 | +Before, using the RLS on `HashMap`, for example, tried to open this file |
| 44 | + |
| 45 | +```text |
| 46 | +~/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/libstd/collections/hash/map.rs |
| 47 | +``` |
| 48 | + |
| 49 | +and now RLS goes to the correct location (for Rust 1.31, note the extra `src`): |
| 50 | + |
| 51 | +```text |
| 52 | +~/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/src/libstd/collections/hash/map.rs |
| 53 | +``` |
0 commit comments