1Version 1.96.1 (2026-06-30)
2===========================
3
4<a id="1.96.1"></a>
5
6- [Cargo: fix timeout/retry behavior](https://github.com/rust-lang/cargo/pull/17131)
7- [Cargo: apply patches for CVE-2025-15661, CVE-2026-55199, and CVE-2026-55200 to libssh2](https://github.com/rust-lang/cargo/pull/17140)
8- [rustc: fix miscompilation in MIR optimization](https://github.com/rust-lang/rust/pull/158214)
9
10Version 1.96.0 (2026-05-28)
11==========================
12
13<a id="1.96.0-Language"></a>
14
15Language
16--------
17- [Allow passing `expr` metavariable to `cfg`](https://github.com/rust-lang/rust/pull/146961)
18- [Always coerce never types in tuple expressions](https://github.com/rust-lang/rust/pull/147834)
19- [Avoid incorrect inference guidance of function arguments in rare cases](https://github.com/rust-lang/rust/pull/150316)
20- [Support s390x vector registers in inline assembly](https://github.com/rust-lang/rust/pull/154184)
21- [Allow using constants of type `ManuallyDrop` as patterns (fixing a regression introduced in 1.94.0)](https://github.com/rust-lang/rust/pull/154891)
22
23<a id="1.96.0-Compiler"></a>
24
25Compiler
26--------
27- [Enable link relaxation feature for LoongArch Linux targets](https://github.com/rust-lang/rust/pull/153427)
28- [Update `riscv64gc-unknown-fuchsia` baseline to RVA22 + vector](https://github.com/rust-lang/rust/pull/155072)
29
30<a id="1.96.0-Libraries"></a>
31
32Libraries
33---------
34- [Support iterating over ranges of `NonZero` integers](https://github.com/rust-lang/rust/pull/127534)
35- [refactor 'valid for read/write' definition: exclude null; add that as an exception on individual methods instead](https://github.com/rust-lang/rust/pull/152615)
36- [Fix SGX delayed host lookup via ToSocketAddr](https://github.com/rust-lang/rust/pull/152851)
37
38<a id="1.96.0-Stabilized-APIs"></a>
39
40Stabilized APIs
41---------------
42
43- [`assert_matches!`](https://doc.rust-lang.org/stable/std/macro.assert_matches.html)
44- [`debug_assert_matches!`](https://doc.rust-lang.org/stable/std/macro.debug_assert_matches.html)
45- [`From<T> for AssertUnwindSafe<T>`](https://doc.rust-lang.org/stable/std/panic/struct.AssertUnwindSafe.html#impl-From%3CT%3E-for-AssertUnwindSafe%3CT%3E)
46- [`From<T> for LazyCell<T, F>`](https://doc.rust-lang.org/stable/std/cell/struct.LazyCell.html#impl-From%3CT%3E-for-LazyCell%3CT,+F%3E)
47- [`From<T> for LazyLock<T, F>`](https://doc.rust-lang.org/stable/std/sync/struct.LazyLock.html#impl-From%3CT%3E-for-LazyLock%3CT,+F%3E)
48- [`core::range::RangeToInclusive`](https://doc.rust-lang.org/stable/core/range/struct.RangeToInclusive.html)
49- [`core::range::RangeToInclusiveIter`](https://doc.rust-lang.org/stable/core/range/struct.RangeToInclusiveIter.html)
50- [`core::range::RangeFrom`](https://doc.rust-lang.org/stable/core/ops/struct.RangeFrom.html)
51- [`core::range::RangeFromIter`](https://doc.rust-lang.org/stable/core/ops/struct.RangeFromIter.html)
52- [`core::range::Range`](https://doc.rust-lang.org/stable/std/range/struct.Range.html)
53- [`core::range::RangeIter`](https://doc.rust-lang.org/stable/std/range/struct.RangeIter.html)
54
55<a id="1.96.0-Cargo"></a>
56
57Cargo
58-----
59- [Allow a dependency to specify both a git repository and an alternate registry.](https://github.com/rust-lang/cargo/pull/16810/) Just like with crates.io, the git repository will be used locally, but the registry version will be used when published.
60- [Added `target.'cfg(..)'.rustdocflags` support in configuration.](https://github.com/rust-lang/cargo/pull/16846)
61- Fixed [CVE-2026-5222](https://blog.rust-lang.org/2026/05/25/cve-2026-5222/) and [CVE-2026-5223](https://blog.rust-lang.org/2026/05/25/cve-2026-5223/).
62
63<a id="1.96-Rustdoc"></a>
64
65Rustdoc
66-----
67- [Deprecation notes are now rendered like any other documentation](https://github.com/rust-lang/rust/pull/149931). Previously they used the css `white-space: pre-wrap;` property and stripped any `<p>` elements from the rendered html, however this caused issues and unintuitive behavior. The new behavior should be more predictable, however some multi-line deprecation notes will now be rendered as as single lines. If this is undesirable, you can use the standard markdown method of forcing a linebreak, which is two spaces followed by a newline (`"\n"`).
68- [Don't emit rustdoc `missing_doc_code_examples` lint on impl items](https://github.com/rust-lang/rust/pull/154048)
69- [Separate methods and associated functions in sidebar](https://github.com/rust-lang/rust/pull/154644)
70
71<a id="1.96.0-Compatibility-Notes"></a>
72
73Compatibility Notes
74-------------------
75- [Fix layout of `#[repr(Int)]` enums in some edge cases involving fields of uninhabited zero-sized types](https://github.com/rust-lang/rust/pull/146989)
76- [Prevent unsize-coercing into `Pin<Foo>` where `Foo` doesn't implement `Deref`. Some such coercions were previously allowed, but produce a type with no useful public API.](https://github.com/rust-lang/rust/pull/149218)
77- [rustc: Stop passing `--allow-undefined` on wasm targets](https://github.com/rust-lang/rust/pull/149868)
78- [Gate the accidentally stabilized `#![reexport_test_harness_main]` attribute](https://github.com/rust-lang/rust/pull/152210)
79- [Error on return-position-impl-trait-in-traits whose types are too private](https://github.com/rust-lang/rust/pull/152543)
80- [Report the `uninhabited_static` lint in dependencies and make it deny-by-default](https://github.com/rust-lang/rust/pull/152853)
81- [Distributed builds now contain non-split debuginfo for windows-gnu](https://github.com/rust-lang/rust/pull/152870)
82 This appears to improve the quality of backtraces. This change has no effect on the defaults for the output of rustc/cargo on these targets.
83- [Check const generic arguments are correctly typed in more positions](https://github.com/rust-lang/rust/pull/152931)
84- [Remove `-Csoft-float`](https://github.com/rust-lang/rust/pull/152973)
85- [Importing structs with `::{self [as name]}`, e.g., `struct S {}; use S::{self as Other};`, is now no longer permitted because `{self}` imports require a module parent.](https://github.com/rust-lang/rust/pull/152996)
86- [For `export_name`, `link_name`, and `link_section` attributes, if multiple of the same attribute is present, the first one now takes precedence.](https://github.com/rust-lang/rust/pull/153041)
87- [Update the minimum external LLVM to 21](https://github.com/rust-lang/rust/pull/153684)
88- On `avr` targets, C's `double` type is 32-bit by default, so [change `c_double` to `f32` on `avr` targets to match](https://github.com/rust-lang/rust/pull/154647). This is a breaking change, but necessary to make `c_double` match C's double.
89- [`BTreeMap::append()` was optimized, which may now cause panics for types with incorrect `Ord` impls](https://github.com/rust-lang/rust/pull/153107)
90
91<a id="1.96.0-Internal-Changes"></a>
92
93Internal Changes
94----------------
95
96These changes do not affect any public interfaces of Rust, but they represent
97significant improvements to the performance or internals of rustc and related
98tools.
99
100- [JSON targets: `aarch64` softfloat targets now have to have `rustc_abi` set to `"softfloat"`](https://github.com/rust-lang/rust/pull/152941)
101- [target specs: stricter checks for LLVM ABI values, and correlate that with `cfg(target_abi)`](https://github.com/rust-lang/rust/pull/153769)
102
103
104Version 1.95.0 (2026-04-16)
105===========================
106
107<a id="1.95-Language"></a>
108
109Language
110--------
111- [Stabilize `if let` guards on match arms](https://github.com/rust-lang/rust/pull/141295)
112- [`irrefutable_let_patterns` lint no longer lints on let chains](https://github.com/rust-lang/rust/pull/146832)
113- [Support importing path-segment keywords with renaming](https://github.com/rust-lang/rust/pull/146972)
114- [Stabilize inline assembly for PowerPC and PowerPC64](https://github.com/rust-lang/rust/pull/147996)
115- [const-eval: be more consistent in the behavior of padding during typed copies](https://github.com/rust-lang/rust/pull/148967)
116- [Const blocks are no longer evaluated to determine if expressions involving fallible operations can implicitly be constant-promoted.](https://github.com/rust-lang/rust/pull/150557). Expressions whose ability to implicitly be promoted would depend on the result of a const block are no longer implicitly promoted.
117- [Make operational semantics of pattern matching independent of crate and module](https://github.com/rust-lang/rust/pull/150681)
118
119
120<a id="1.95-Compiler"></a>
121
122Compiler
123--------
124
125- [Stabilize `--remap-path-scope` for controlling the scoping of how paths get remapped in the resulting binary](https://github.com/rust-lang/rust/pull/147611)
126- [Apply patches for CVE-2026-6042 and CVE-2026-40200 to vendored musl](https://github.com/rust-lang/rust/pull/155171)
127
128<a id="1.95-Platform-Support"></a>
129
130Platform Support
131----------------
132- [Promote `powerpc64-unknown-linux-musl` to Tier 2 with host tools](https://github.com/rust-lang/rust/pull/149962)
133- [Promote `aarch64-apple-tvos` to Tier 2](https://github.com/rust-lang/rust/pull/152021)
134- [Promote `aarch64-apple-tvos-sim` to Tier 2](https://github.com/rust-lang/rust/pull/152021)
135- [Promote `aarch64-apple-watchos` to Tier 2](https://github.com/rust-lang/rust/pull/152021)
136- [Promote `aarch64-apple-watchos-sim` to Tier 2](https://github.com/rust-lang/rust/pull/152021)
137- [Promote `aarch64-apple-visionos` to Tier 2](https://github.com/rust-lang/rust/pull/152021)
138- [Promote `aarch64-apple-visionos-sim` to Tier 2](https://github.com/rust-lang/rust/pull/152021)
139
140
141Refer to Rust's [platform support page][platform-support-doc]
142for more information on Rust's tiered platform support.
143
144[platform-support-doc]: https://doc.rust-lang.org/rustc/platform-support.html
145
146<a id="1.95-Libraries"></a>
147
148Libraries
149---------
150- [`thread::scope`: document how join interacts with TLS destructors](https://github.com/rust-lang/rust/pull/149482)
151- [Speed up `str::contains` on aarch64 targets with `neon` target feature enabled by default](https://github.com/rust-lang/rust/pull/152176)
152
153
154<a id="1.95-Stabilized-APIs"></a>
155
156Stabilized APIs
157---------------
158
159- [`MaybeUninit<[T; N]>: From<[MaybeUninit<T>; N]>`](https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#impl-From%3CMaybeUninit%3C%5BT;+N%5D%3E%3E-for-%5BMaybeUninit%3CT%3E;+N%5D)
160- [`MaybeUninit<[T; N]>: AsRef<[MaybeUninit<T>; N]>`](https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#impl-AsRef%3C%5BMaybeUninit%3CT%3E;+N%5D%3E-for-MaybeUninit%3C%5BT;+N%5D%3E)
161- [`MaybeUninit<[T; N]>: AsRef<[MaybeUninit<T>]>`](https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#impl-AsRef%3C%5BMaybeUninit%3CT%3E%5D%3E-for-MaybeUninit%3C%5BT;+N%5D%3E)
162- [`MaybeUninit<[T; N]>: AsMut<[MaybeUninit<T>; N]>`](https://doc.rust-lang.org/beta/std/mem/union.MaybeUninit.html#impl-AsMut%3C%5BMaybeUninit%3CT%3E;+N%5D%3E-for-MaybeUninit%3C%5BT;+N%5D%3E)
163- [`MaybeUninit<[T; N]>: AsMut<[MaybeUninit<T>]>`](https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#impl-AsMut%3C%5BMaybeUninit%3CT%3E%5D%3E-for-MaybeUninit%3C%5BT;+N%5D%3E)
164- [`[MaybeUninit<T>; N]: From<MaybeUninit<[T; N]>>`](https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#impl-From%3C%5BMaybeUninit%3CT%3E;+N%5D%3E-for-MaybeUninit%3C%5BT;+N%5D%3E)
165- [`Cell<[T; N]>: AsRef<[Cell<T>; N]>`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#impl-AsRef%3C%5BCell%3CT%3E;+N%5D%3E-for-Cell%3C%5BT;+N%5D%3E)
166- [`Cell<[T; N]>: AsRef<[Cell<T>]>`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#impl-AsRef%3C%5BCell%3CT%3E%5D%3E-for-Cell%3C%5BT;+N%5D%3E)
167- [`Cell<[T]>: AsRef<[Cell<T>]>`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#impl-AsRef%3C%5BCell%3CT%3E%5D%3E-for-Cell%3C%5BT%5D%3E)
168- [`bool: TryFrom<{integer}>`](https://doc.rust-lang.org/stable/std/primitive.bool.html#impl-TryFrom%3Cu128%3E-for-bool)
169- [`AtomicPtr::update`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicPtr.html#method.update)
170- [`AtomicPtr::try_update`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicPtr.html#method.try_update)
171- [`AtomicBool::update`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicBool.html#method.update)
172- [`AtomicBool::try_update`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicBool.html#method.try_update)
173- [`AtomicIn::update`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicIsize.html#method.update)
174- [`AtomicIn::try_update`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicIsize.html#method.try_update)
175- [`AtomicUn::update`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicUsize.html#method.update)
176- [`AtomicUn::try_update`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicUsize.html#method.try_update)
177- [`cfg_select!`](https://doc.rust-lang.org/stable/std/macro.cfg_select.html)
178- [`mod core::range`](https://doc.rust-lang.org/stable/core/range/index.html)
179- [`core::range::RangeInclusive`](https://doc.rust-lang.org/stable/core/range/struct.RangeInclusive.html)
180- [`core::range::RangeInclusiveIter`](https://doc.rust-lang.org/stable/core/range/struct.RangeInclusiveIter.html)
181- [`core::hint::cold_path`](https://doc.rust-lang.org/stable/core/hint/fn.cold_path.html)
182- [`<*const T>::as_ref_unchecked`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.as_ref_unchecked)
183- [`<*mut T>::as_ref_unchecked`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.as_ref_unchecked-1)
184- [`<*mut T>::as_mut_unchecked`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.as_mut_unchecked)
185- [`Vec::push_mut`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.push_mut)
186- [`Vec::insert_mut`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.insert_mut)
187- [`VecDeque::push_front_mut`](https://doc.rust-lang.org/stable/std/collections/struct.VecDeque.html#method.push_front_mut)
188- [`VecDeque::push_back_mut`](https://doc.rust-lang.org/stable/std/collections/struct.VecDeque.html#method.push_back_mut)
189- [`VecDeque::insert_mut`](https://doc.rust-lang.org/stable/std/collections/struct.VecDeque.html#method.insert_mut)
190- [`LinkedList::push_front_mut`](https://doc.rust-lang.org/stable/std/collections/struct.LinkedList.html#method.push_front_mut)
191- [`LinkedList::push_back_mut`](https://doc.rust-lang.org/stable/std/collections/struct.LinkedList.html#method.push_back_mut)
192- [`Layout::dangling_ptr`](https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.dangling_ptr)
193- [`Layout::repeat`](https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.repeat)
194- [`Layout::repeat_packed`](https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.repeat_packed)
195- [`Layout::extend_packed`](https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.extend_packed)
196
197These previously stable APIs are now stable in const contexts:
198
199- [`fmt::from_fn`](https://doc.rust-lang.org/stable/std/fmt/fn.from_fn.html)
200- [`ControlFlow::is_break`](https://doc.rust-lang.org/stable/core/ops/enum.ControlFlow.html#method.is_break)
201- [`ControlFlow::is_continue`](https://doc.rust-lang.org/stable/core/ops/enum.ControlFlow.html#method.is_continue)
202
203<a id="1.95-Rustdoc"></a>
204
205Rustdoc
206-----
207- [In search results, rank unstable items lower](https://github.com/rust-lang/rust/pull/149460)
208- [Add new "hide deprecated items" setting in rustdoc](https://github.com/rust-lang/rust/pull/151091)
209
210<a id="1.95-Compatibility-Notes"></a>
211
212Compatibility Notes
213-------------------
214- [Array coercions may now result in less inference constraints than before](https://github.com/rust-lang/rust/pull/140283)
215- Importing `$crate` without renaming, i.e. `use $crate::{self};`, is now no longer permitted due to stricter error checking for `self` imports.
216- [const-eval: be more consistent in the behavior of padding during typed copies.](https://github.com/rust-lang/rust/pull/148967)
217 In very rare cases, this may cause compilation errors due to bytes from parts of a pointer ending up in the padding bytes of a `const` or `static`.
218- [A future-incompatibility warning lint `ambiguous_glob_imported_traits` is now reported when using an ambiguously glob imported trait](https://github.com/rust-lang/rust/pull/149058)
219- [Check lifetime bounds of types mentioning only type parameters](https://github.com/rust-lang/rust/pull/149389)
220- [Report more visibility-related ambiguous import errors](https://github.com/rust-lang/rust/pull/149596)
221- [Deprecate `Eq::assert_receiver_is_total_eq` and emit future compatibility warnings on manual impls](https://github.com/rust-lang/rust/pull/149978)
222- [powerpc64: Use the ELF ABI version set in target spec instead of guessing](https://github.com/rust-lang/rust/pull/150468) (fixes the ELF ABI used by the OpenBSD target)
223- Matching on a `#[non_exhaustive]` enum [now reads the discriminant, even if the enum has only one variant](https://github.com/rust-lang/rust/pull/150681). This can cause closures to capture values that they previously wouldn't.
224- `mut ref` and `mut ref mut` patterns, part of the unstable [Match Ergonomics 2024 RFC](https://github.com/rust-lang/rust/issues/123076), were accidentally allowed on stable within struct pattern field shorthand. These patterns are now correctly feature-gated as unstable in this position.
225- [Add future-compatibility warning for derive helper attributes which conflict with built-in attributes](https://github.com/rust-lang/rust/pull/151152)
226- [JSON target specs](https://doc.rust-lang.org/rustc/targets/custom.html) have been destabilized and now require `-Z unstable-options` to use. Previously, they could not be used without the standard library, which has no stable build mechanism. In preparation for the `build-std` project adding that support, JSON target specs are being proactively gated to ensure they remain unstable even if `build-std` is stabilized. Cargo now includes the `-Z json-target-spec` CLI flag to automatically pass `-Z unstable-options` to the compiler when needed. See [#150151](https://github.com/rust-lang/rust/pull/150151), [#151534](https://github.com/rust-lang/rust/pull/150151), and [rust-lang/cargo#16557](https://github.com/rust-lang/cargo/pull/16557).
227- [The arguments of `#[feature]` attributes on invalid targets are now checked](https://github.com/rust-lang/rust/issues/153764)
228
229<a id="1.95-Internal-Changes"></a>
230
231Internal Changes
232----------------
233
234These changes do not affect any public interfaces of Rust, but they represent
235significant improvements to the performance or internals of rustc and related
236tools.
237
238- [Update to LLVM 22](https://github.com/rust-lang/rust/pull/150722)
239
240
241Version 1.94.1 (2026-03-26)
242===========================
243
244<a id="1.94.1"></a>
245
246* [Fix `std::thread::spawn` on wasm32-wasip1-threads](https://github.com/rust-lang/rust/pull/153634)
247* [Remove new methods added to `std::os::windows::fs::OpenOptionsExt`](https://github.com/rust-lang/rust/pull/153491)
248 The new methods were unstable, but the trait itself is not sealed and so
249 cannot be extended with non-default methods.
250* [Clippy: fix ICE in `match_same_arms`](https://github.com/rust-lang/rust-clippy/pull/16685)
251* [Cargo: update tar to 0.4.45](https://github.com/rust-lang/cargo/pull/16769)
252 This resolves CVE-2026-33055 and CVE-2026-33056. Users of crates.io are not affected.
253 See [blog](https://blog.rust-lang.org/2026/03/21/cve-2026-33056/) for more details.
254
255Version 1.94.0 (2026-03-05)
256==========================
257
258<a id="1.94.0-Language"></a>
259
260Language
261--------
262- [Impls and impl items inherit `dead_code` lint level of the corresponding traits and trait items](https://github.com/rust-lang/rust/pull/144113)
263- [Stabilize additional 29 RISC-V target features including large portions of the RVA22U64 / RVA23U64 profiles](https://github.com/rust-lang/rust/pull/145948)
264- [Add warn-by-default `unused_visibilities` lint for visibility on `const _` declarations](https://github.com/rust-lang/rust/pull/147136)
265- [Update to Unicode 17](https://github.com/rust-lang/rust/pull/148321)
266- [Avoid incorrect lifetime errors for closures](https://github.com/rust-lang/rust/pull/148329)
267
268<a id="1.94.0-Platform-Support"></a>
269
270Platform Support
271----------------
272
273- [Add `riscv64im-unknown-none-elf` as a tier 3 target](https://github.com/rust-lang/rust/pull/148790)
274
275Refer to Rust's [platform support page][platform-support-doc]
276for more information on Rust's tiered platform support.
277
278[platform-support-doc]: https://doc.rust-lang.org/rustc/platform-support.html
279
280<a id="1.94.0-Libraries"></a>
281
282Libraries
283---------
284
285- [Relax `T: Ord` bound for some `BinaryHeap<T>` methods.](https://github.com/rust-lang/rust/pull/149408)
286
287<a id="1.94.0-Stabilized-APIs"></a>
288
289Stabilized APIs
290---------------
291
292- [`<[T]>::array_windows`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.array_windows)
293- [`<[T]>::element_offset`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.element_offset)
294- [`LazyCell::get`](https://doc.rust-lang.org/stable/std/cell/struct.LazyCell.html#method.get)
295- [`LazyCell::get_mut`](https://doc.rust-lang.org/stable/std/cell/struct.LazyCell.html#method.get_mut)
296- [`LazyCell::force_mut`](https://doc.rust-lang.org/stable/std/cell/struct.LazyCell.html#method.force_mut)
297- [`LazyLock::get`](https://doc.rust-lang.org/stable/std/sync/struct.LazyLock.html#method.get)
298- [`LazyLock::get_mut`](https://doc.rust-lang.org/stable/std/sync/struct.LazyLock.html#method.get_mut)
299- [`LazyLock::force_mut`](https://doc.rust-lang.org/stable/std/sync/struct.LazyLock.html#method.force_mut)
300- [`impl TryFrom<char> for usize`](https://doc.rust-lang.org/stable/std/convert/trait.TryFrom.html#impl-TryFrom%3Cchar%3E-for-usize)
301- [`std::iter::Peekable::next_if_map`](https://doc.rust-lang.org/stable/std/iter/struct.Peekable.html#method.next_if_map)
302- [`std::iter::Peekable::next_if_map_mut`](https://doc.rust-lang.org/stable/std/iter/struct.Peekable.html#method.next_if_map_mut)
303- [x86 `avx512fp16` intrinsics](https://github.com/rust-lang/rust/issues/127213)
304 (excluding those that depend directly on the unstable `f16` type)
305- [AArch64 NEON fp16 intrinsics](https://github.com/rust-lang/rust/issues/136306)
306 (excluding those that depend directly on the unstable `f16` type)
307- [`f32::consts::EULER_GAMMA`](https://doc.rust-lang.org/stable/std/f32/consts/constant.EULER_GAMMA.html)
308- [`f64::consts::EULER_GAMMA`](https://doc.rust-lang.org/stable/std/f64/consts/constant.EULER_GAMMA.html)
309- [`f32::consts::GOLDEN_RATIO`](https://doc.rust-lang.org/stable/std/f32/consts/constant.GOLDEN_RATIO.html)
310- [`f64::consts::GOLDEN_RATIO`](https://doc.rust-lang.org/stable/std/f64/consts/constant.GOLDEN_RATIO.html)
311
312
313These previously stable APIs are now stable in const contexts:
314
315- [`f32::mul_add`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.mul_add)
316- [`f64::mul_add`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.mul_add)
317
318
319<a id="1.94.0-Cargo"></a>
320
321Cargo
322-----
323
324- Stabilize the config include key. The top-level include config key allows loading additional config files, enabling better organization, sharing, and management of Cargo configurations across projects and environments. [docs](https://doc.rust-lang.org/nightly/cargo/reference/config.html#including-extra-configuration-files) [#16284](https://github.com/rust-lang/cargo/pull/16284)
325- Stabilize the pubtime field in registry index. This records when a crate version was published and enables time-based dependency resolution in the future. Note that crates.io will gradually backfill existing packages when a new version is published. Not all crates have pubtime yet. [#16369](https://github.com/rust-lang/cargo/pull/16369) [#16372](https://github.com/rust-lang/cargo/pull/16372)
326- Cargo now parses [TOML v1.1](https://toml.io/en/v1.1.0) for manifests and configuration files. Note that using these features in Cargo.toml will raise your development MSRV, but the published manifest remains compatible with older parsers. [#16415](https://github.com/rust-lang/cargo/pull/16415)
327- [Make `CARGO_BIN_EXE_<crate>` available at runtime ](https://github.com/rust-lang/cargo/pull/16421/)
328
329<a id="1.94.0-Compatibility-Notes"></a>
330
331Compatibility Notes
332-------------------
333- [Forbid freely casting lifetime bounds of `dyn`-types](https://github.com/rust-lang/rust/pull/136776)
334- [Make closure capturing have consistent and correct behaviour around patterns](https://github.com/rust-lang/rust/pull/138961)
335 Some finer details of how precise closure captures get affected by pattern matching have been changed. In some cases, this can cause a non-move closure that was previously capturing an entire variable by move, to now capture only part of that variable by move, and other parts by borrow. This can cause the borrow checker to complain where it previously didn't, or cause `Drop` to run at a different point in time.
336- [Standard library macros are now imported via prelude, not via injected `#[macro_use]`](https://github.com/rust-lang/rust/pull/139493)
337 This will raise an error if macros of the same name are glob imported.
338 For example if a crate defines their own `matches` macro and then glob imports that,
339 it's now ambiguous whether the custom or standard library `matches` is meant and
340 an explicit import of the name is required to resolve the ambiguity.
341 One exception is `core::panic` and `std::panic`, if their import is ambiguous
342 a new warning ([`ambiguous_panic_imports`](https://github.com/rust-lang/rust/issues/147319)) is raised.
343 This may raise a new warning ([`ambiguous_panic_imports`](https://github.com/rust-lang/rust/issues/147319)) on `#![no_std]` code glob importing the std crate.
344 Both `core::panic!` and `std::panic!` are then in scope and which is used is ambiguous.
345- [Don't strip shebang in expression-context `include!(…)`s](https://github.com/rust-lang/rust/pull/146377)
346 This can cause previously working includes to no longer compile if they included files which started with a shebang.
347- [Ambiguous glob reexports are now also visible cross-crate](https://github.com/rust-lang/rust/pull/147984)
348 This unifies behavior between local and cross-crate errors on these exports, which may introduce new ambiguity errors.
349- [Don't normalize where-clauses before checking well-formedness](https://github.com/rust-lang/rust/pull/148477)
350- [Introduce a future compatibility warning on codegen attributes on body-free trait methods](https://github.com/rust-lang/rust/pull/148756)
351 These attributes currently have no effect in this position.
352- [On Windows `std::time::SystemTime::checked_sub_duration` will return `None` for times before the Windows epoch (1/1/1601)](https://github.com/rust-lang/rust/pull/148825)
353- [Lifetime identifiers such as `'a` are now NFC normalized](https://github.com/rust-lang/rust/pull/149192).
354- [Overhaul filename handling for cross-compiler consistency](https://github.com/rust-lang/rust/pull/149709)
355 Any paths emitted by compiler now always respect the relative-ness of the paths and `--remap-path-prefix` given originally.
356 One side-effect of this change is that paths emitted for local crates in Cargo (path dependencies and workspace members) are no longer absolute but relative when emitted as part of a diagnostic in a downstream crate.
357
358<a id="1.94.0-Internal-Changes"></a>
359
360Internal Changes
361----------------
362
363These changes do not affect any public interfaces of Rust, but they represent
364significant improvements to the performance or internals of rustc and related
365tools.
366
367- [Switch to `annotate-snippets` for error emission](https://github.com/rust-lang/rust/pull/150032)
368 This should preserve mostly the same outputs in rustc error messages.
369
370Version 1.93.1 (2026-02-12)
371===========================
372
373<a id="1.93.1"></a>
374
375- [Don't try to recover keyword as non-keyword identifier](https://github.com/rust-lang/rust/pull/150590), fixing an ICE that especially [affected rustfmt](https://github.com/rust-lang/rustfmt/issues/6739).
376- [Fix `clippy::panicking_unwrap` false-positive on field access with implicit deref](https://github.com/rust-lang/rust-clippy/pull/16196).
377- [Revert "Update wasm-related dependencies in CI"](https://github.com/rust-lang/rust/pull/152259), fixing file descriptor leaks on the `wasm32-wasip2` target.
378
379Version 1.93.0 (2026-01-22)
380==========================
381
382<a id="1.93.0-Language"></a>
383
384Language
385--------
386- [Stabilize several s390x `vector`-related target features and the `is_s390x_feature_detected!` macro](https://github.com/rust-lang/rust/pull/145656)
387- [Stabilize declaration of C-style variadic functions for the `system` ABI](https://github.com/rust-lang/rust/pull/145954)
388- [Emit error when using some keyword as a `cfg` predicate](https://github.com/rust-lang/rust/pull/146978)
389- [Stabilize `asm_cfg`](https://github.com/rust-lang/rust/pull/147736)
390- [During const-evaluation, support copying pointers byte-by-byte](https://github.com/rust-lang/rust/pull/148259)
391- [LUB coercions now correctly handle function item types, and functions with differing safeties](https://github.com/rust-lang/rust/pull/148602)
392- [Allow `const` items that contain mutable references to `static` (which is *very* unsafe, but not *always* UB)](https://github.com/rust-lang/rust/pull/148746)
393- [Add warn-by-default `const_item_interior_mutations` lint to warn against calls which mutate interior mutable `const` items](https://github.com/rust-lang/rust/pull/148407)
394- [Add warn-by-default `function_casts_as_integer` lint](https://github.com/rust-lang/rust/pull/141470)
395
396
397<a id="1.93.0-Compiler"></a>
398
399Compiler
400--------
401- [Stabilize `-Cjump-tables=bool`](https://github.com/rust-lang/rust/pull/145974). The flag was previously called `-Zno-jump-tables`.
402
403<a id="1.93.0-Platform-Support"></a>
404
405Platform Support
406----------------
407
408- [Promote `riscv64a23-unknown-linux-gnu` to Tier 2 (without host tools)](https://github.com/rust-lang/rust/pull/148435)
409
410Refer to Rust's [platform support page][platform-support-doc]
411for more information on Rust's tiered platform support.
412
413[platform-support-doc]: https://doc.rust-lang.org/rustc/platform-support.html
414
415<a id="1.93.0-Libraries"></a>
416
417Libraries
418---------
419- [Stop internally using `specialization` on the `Copy` trait as it is unsound in the presence of lifetime dependent `Copy` implementations. This may result in some performance regressions as some standard library APIs may now call `Clone::clone` instead of performing bitwise copies](https://github.com/rust-lang/rust/pull/135634)
420- [Allow the global allocator to use thread-local storage and `std::thread::current()`](https://github.com/rust-lang/rust/pull/144465)
421- [Make `BTree::append` not update existing keys when appending an entry which already exists](https://github.com/rust-lang/rust/pull/145628)
422- [Don't require `T: RefUnwindSafe` for `vec::IntoIter<T>: UnwindSafe`](https://github.com/rust-lang/rust/pull/145665)
423
424
425<a id="1.93.0-Stabilized-APIs"></a>
426
427Stabilized APIs
428---------------
429
430- [`<[MaybeUninit<T>]>::assume_init_drop`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.assume_init_drop)
431- [`<[MaybeUninit<T>]>::assume_init_ref`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.assume_init_ref)
432- [`<[MaybeUninit<T>]>::assume_init_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.assume_init_mut)
433- [`<[MaybeUninit<T>]>::write_copy_of_slice`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.write_copy_of_slice)
434- [`<[MaybeUninit<T>]>::write_clone_of_slice`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.write_clone_of_slice)
435- [`String::into_raw_parts`](https://doc.rust-lang.org/stable/std/string/struct.String.html#method.into_raw_parts)
436- [`Vec::into_raw_parts`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.into_raw_parts)
437- [`<iN>::unchecked_neg`](https://doc.rust-lang.org/stable/std/primitive.isize.html#method.unchecked_neg)
438- [`<iN>::unchecked_shl`](https://doc.rust-lang.org/stable/std/primitive.isize.html#method.unchecked_shl)
439- [`<iN>::unchecked_shr`](https://doc.rust-lang.org/stable/std/primitive.isize.html#method.unchecked_shr)
440- [`<uN>::unchecked_shl`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.unchecked_shl)
441- [`<uN>::unchecked_shr`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.unchecked_shr)
442- [`<[T]>::as_array`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_array)
443- [`<[T]>::as_mut_array`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_mut_array)
444- [`<*const [T]>::as_array`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.as_array)
445- [`<*mut [T]>::as_mut_array`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.as_mut_array)
446- [`VecDeque::pop_front_if`](https://doc.rust-lang.org/stable/std/collections/struct.VecDeque.html#method.pop_front_if)
447- [`VecDeque::pop_back_if`](https://doc.rust-lang.org/stable/std/collections/struct.VecDeque.html#method.pop_back_if)
448- [`Duration::from_nanos_u128`](https://doc.rust-lang.org/stable/std/time/struct.Duration.html#method.from_nanos_u128)
449- [`char::MAX_LEN_UTF8`](https://doc.rust-lang.org/stable/std/primitive.char.html#associatedconstant.MAX_LEN_UTF8)
450- [`char::MAX_LEN_UTF16`](https://doc.rust-lang.org/stable/std/primitive.char.html#associatedconstant.MAX_LEN_UTF16)
451- [`std::fmt::from_fn`](https://doc.rust-lang.org/stable/std/fmt/fn.from_fn.html)
452- [`std::fmt::FromFn`](https://doc.rust-lang.org/stable/std/fmt/struct.FromFn.html)
453
454
455<a id="1.93.0-Cargo"></a>
456
457Cargo
458-----
459- [Enable CARGO_CFG_DEBUG_ASSERTIONS in build scripts based on profile](https://github.com/rust-lang/cargo/pull/16160/)
460- [In `cargo tree`, support long forms for `--format` variables](https://github.com/rust-lang/cargo/pull/16204/)
461- [Add `--workspace` to `cargo clean`](https://github.com/rust-lang/cargo/pull/16263/)
462
463<a id="1.93.0-Rustdoc"></a>
464
465Rustdoc
466-----
467- [Remove `#![doc(document_private_items)]`](https://github.com/rust-lang/rust/pull/146495)
468- [Include attribute and derive macros in search filters for "macros"](https://github.com/rust-lang/rust/pull/148176)
469- [Include extern crates in search filters for `import`](https://github.com/rust-lang/rust/pull/148301)
470- [Validate usage of crate-level doc attributes](https://github.com/rust-lang/rust/pull/149197). This means if any of `html_favicon_url`, `html_logo_url`, `html_playground_url`, `issue_tracker_base_url`, or `html_no_source` either has a missing value, an unexpected value, or a value of the wrong type, rustdoc will emit the deny-by-default lint `rustdoc::invalid_doc_attributes`.
471
472
473<a id="1.93.0-Compatibility-Notes"></a>
474
475Compatibility Notes
476-------------------
477- [Introduce `pin_v2` into the builtin attributes namespace](https://github.com/rust-lang/rust/pull/139751)
478- [Update bundled musl to 1.2.5](https://github.com/rust-lang/rust/pull/142682)
479- [On Emscripten, the unwinding ABI used when compiling with `panic=unwind` was changed from the JS exception handling ABI to the wasm exception handling ABI.](https://github.com/rust-lang/rust/pull/147224) If linking C/C++ object files with Rust objects, `-fwasm-exceptions` must be passed to the linker now. On nightly Rust, it is possible to get the old behavior with `-Zwasm-emscripten-eh=false -Zbuild-std`, but it will be removed in a future release.
480- The `#[test]` attribute, used to define tests, was previously ignored in various places where it had no meaning (e.g on trait methods or types). Putting the `#[test]` attribute in these places is no longer ignored, and will now result in an error; this may also result in errors when generating rustdoc. [Error when `test` attribute is applied to structs](https://github.com/rust-lang/rust/pull/147841)
481- Cargo now sets the `CARGO_CFG_DEBUG_ASSERTIONS` environment variable in more situations. This will cause crates depending on `static-init` versions 1.0.1 to 1.0.3 to fail compilation with "failed to resolve: use of unresolved module or unlinked crate `parking_lot`". See [the linked issue](https://github.com/rust-lang/rust/issues/150646#issuecomment-3718964342) for details.
482- [User written types in the `offset_of!` macro are now checked to be well formed.](https://github.com/rust-lang/rust/issues/150465/)
483- `cargo publish` no longer emits `.crate` files as a final artifact for user access when the `build.build-dir` config is unset
484- [Upgrade the `deref_nullptr` lint from warn-by-default to deny-by-default](https://github.com/rust-lang/rust/pull/148122)
485- [Add future-incompatibility warning for `...` function parameters without a pattern outside of `extern` blocks](https://github.com/rust-lang/rust/pull/143619)
486- [Introduce future-compatibility warning for `repr(C)` enums whose discriminant values do not fit into a `c_int` or `c_uint`](https://github.com/rust-lang/rust/pull/147017)
487- [Introduce future-compatibility warning against ignoring `repr(C)` types as part of `repr(transparent)`](https://github.com/rust-lang/rust/pull/147185)
488
489
490Version 1.92.0 (2025-12-11)
491==========================
492
493<a id="1.92.0-Language"></a>
494
495Language
496--------
497- [Document `MaybeUninit` representation and validity](https://github.com/rust-lang/rust/pull/140463)
498- [Allow `&raw [mut | const]` for union field in safe code](https://github.com/rust-lang/rust/pull/141469)
499- [Prefer item bounds of associated types over where-bounds for auto-traits and `Sized`](https://github.com/rust-lang/rust/pull/144064)
500- [Do not materialize `X` in `[X; 0]` when `X` is unsizing a const](https://github.com/rust-lang/rust/pull/145277)
501- [Support combining `#[track_caller]` and `#[no_mangle]` (requires every declaration specifying `#[track_caller]` as well)](https://github.com/rust-lang/rust/pull/145724)
502- [Make never type lints `never_type_fallback_flowing_into_unsafe` and `dependency_on_unit_never_type_fallback` deny-by-default](https://github.com/rust-lang/rust/pull/146167)
503- [Allow specifying multiple bounds for same associated item, except in trait objects](https://github.com/rust-lang/rust/pull/146593)
504- [Slightly strengthen higher-ranked region handling in coherence](https://github.com/rust-lang/rust/pull/146725)
505- [The `unused_must_use` lint no longer warns on `Result<(), Uninhabited>` (for instance, `Result<(), !>`), or `ControlFlow<Uninhabited, ()>`](https://github.com/rust-lang/rust/pull/147382). This avoids having to check for an error that can never happen.
506
507<a id="1.92.0-Compiler"></a>
508
509Compiler
510--------
511- [Make `mips64el-unknown-linux-muslabi64` link dynamically](https://github.com/rust-lang/rust/pull/146858)
512- [Remove current code for embedding command-line args in PDB](https://github.com/rust-lang/rust/pull/147022)
513 Command-line information is typically not needed by debugging tools, and the removed code
514 was causing problems for incremental builds even on targets that don't use PDB debuginfo.
515
516<a id="1.92.0-Libraries"></a>
517
518Libraries
519---------
520- [Specialize `Iterator::eq{_by}` for `TrustedLen` iterators](https://github.com/rust-lang/rust/pull/137122)
521- [Simplify `Extend` for tuples](https://github.com/rust-lang/rust/pull/138799)
522- [Added details to `Debug` for `EncodeWide`](https://github.com/rust-lang/rust/pull/140153).
523- [`iter::Repeat::last`](https://github.com/rust-lang/rust/pull/147258) and [`count`](https://github.com/rust-lang/rust/pull/146410) will now panic, rather than looping infinitely.
524
525<a id="1.92.0-Stabilized-APIs"></a>
526
527Stabilized APIs
528---------------
529
530- [`NonZero<u{N}>::div_ceil`](https://doc.rust-lang.org/stable/std/num/struct.NonZero.html#method.div_ceil)
531- [`Location::file_as_c_str`](https://doc.rust-lang.org/stable/std/panic/struct.Location.html#method.file_as_c_str)
532- [`RwLockWriteGuard::downgrade`](https://doc.rust-lang.org/stable/std/sync/struct.RwLockWriteGuard.html#method.downgrade)
533- [`Box::new_zeroed`](https://doc.rust-lang.org/stable/std/boxed/struct.Box.html#method.new_zeroed)
534- [`Box::new_zeroed_slice`](https://doc.rust-lang.org/stable/std/boxed/struct.Box.html#method.new_zeroed_slice)
535- [`Rc::new_zeroed`](https://doc.rust-lang.org/stable/std/rc/struct.Rc.html#method.new_zeroed)
536- [`Rc::new_zeroed_slice`](https://doc.rust-lang.org/stable/std/rc/struct.Rc.html#method.new_zeroed_slice)
537- [`Arc::new_zeroed`](https://doc.rust-lang.org/stable/std/sync/struct.Arc.html#method.new_zeroed)
538- [`Arc::new_zeroed_slice`](https://doc.rust-lang.org/stable/std/sync/struct.Arc.html#method.new_zeroed_slice)
539- [`btree_map::Entry::insert_entry`](https://doc.rust-lang.org/stable/std/collections/btree_map/enum.Entry.html#method.insert_entry)
540- [`btree_map::VacantEntry::insert_entry`](https://doc.rust-lang.org/stable/std/collections/btree_map/struct.VacantEntry.html#method.insert_entry)
541- [`impl Extend<proc_macro::Group> for proc_macro::TokenStream`](https://doc.rust-lang.org/stable/proc_macro/struct.TokenStream.html#impl-Extend%3CGroup%3E-for-TokenStream)
542- [`impl Extend<proc_macro::Literal> for proc_macro::TokenStream`](https://doc.rust-lang.org/stable/proc_macro/struct.TokenStream.html#impl-Extend%3CLiteral%3E-for-TokenStream)
543- [`impl Extend<proc_macro::Punct> for proc_macro::TokenStream`](https://doc.rust-lang.org/stable/proc_macro/struct.TokenStream.html#impl-Extend%3CPunct%3E-for-TokenStream)
544- [`impl Extend<proc_macro::Ident> for proc_macro::TokenStream`](https://doc.rust-lang.org/stable/proc_macro/struct.TokenStream.html#impl-Extend%3CIdent%3E-for-TokenStream)
545
546These previously stable APIs are now stable in const contexts:
547
548- [`<[_]>::rotate_left`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.rotate_left)
549- [`<[_]>::rotate_right`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.rotate_right)
550
551<a id="1.92.0-Cargo"></a>
552
553Cargo
554-----
555- [Added a new chapter](https://github.com/rust-lang/cargo/issues/16119) to the Cargo book, ["Optimizing Build Performance"](https://doc.rust-lang.org/stable/cargo/guide/build-performance.html).
556
557<a id="1.92.0-Rustdoc"></a>
558
559Rustdoc
560-----
561- [If a trait item appears in rustdoc search, hide the corresponding impl items](https://github.com/rust-lang/rust/pull/145898). Previously a search for "last" would show both `Iterator::last` as well as impl methods like `std::vec::IntoIter::last`. Now these impl methods will be hidden, freeing up space for inherent methods like `BTreeSet::last`.
562- [Relax rules for identifiers in search](https://github.com/rust-lang/rust/pull/147860). Previously you could only search for identifiers that were valid in rust code, now searches only need to be valid as part of an identifier. For example, you can now perform a search that starts with a digit.
563
564<a id="1.92.0-Compatibility-Notes"></a>
565
566Compatibility Notes
567-------------------
568* [Fix backtraces with `-C panic=abort` on Linux by generating unwind tables by default](https://github.com/rust-lang/rust/pull/143613). Build with `-C force-unwind-tables=no` to keep omitting unwind tables.
569- As part of the larger effort refactoring compiler built-in attributes and their diagnostics, [the future-compatibility lint `invalid_macro_export_arguments` is upgraded to deny-by-default and will be reported in dependencies too.](https://github.com/rust-lang/rust/pull/143857)
570- [Update the minimum external LLVM to 20](https://github.com/rust-lang/rust/pull/145071)
571- [Prevent downstream `impl DerefMut for Pin<LocalType>`](https://github.com/rust-lang/rust/pull/145608)
572- [Don't apply temporary lifetime extension rules to the arguments of non-extended `pin!` and formatting macros](https://github.com/rust-lang/rust/pull/145838)
573
574
575Version 1.91.1 (2025-11-10)
576===========================
577
578<a id="1.91.1"></a>
579
580- [Enable file locking support in illumos](https://github.com/rust-lang/rust/pull/148322). This fixes Cargo not locking the build directory on illumos.
581- [Fix `wasm_import_module` attribute cross-crate](https://github.com/rust-lang/rust/pull/148363). This fixes linker errors on WASM targets.
582
583Version 1.91.0 (2025-10-30)
584==========================
585
586<a id="1.91.0-Language"></a>
587
588Language
589--------
590
591- [Lower pattern bindings in the order they're written and base drop order on primary bindings' order](https://github.com/rust-lang/rust/pull/143764)
592- [Stabilize declaration of C-style variadic functions for `sysv64`, `win64`, `efiapi`, and `aapcs` ABIs](https://github.com/rust-lang/rust/pull/144066).
593 This brings these ABIs in line with the C ABI: variadic functions can be declared in extern blocks but not defined.
594- [Add `dangling_pointers_from_locals` lint to warn against dangling pointers from local variables](https://github.com/rust-lang/rust/pull/144322)
595- [Upgrade `semicolon_in_expressions_from_macros` from warn to deny](https://github.com/rust-lang/rust/pull/144369)
596- [Stabilize LoongArch32 inline assembly](https://github.com/rust-lang/rust/pull/144402)
597- [Add warn-by-default `integer_to_ptr_transmutes` lint against integer-to-pointer transmutes](https://github.com/rust-lang/rust/pull/144531)
598- [Stabilize `sse4a` and `tbm` target features](https://github.com/rust-lang/rust/pull/144542)
599- [Add `target_env = "macabi"` and `target_env = "sim"` cfgs](https://github.com/rust-lang/rust/pull/139451) as replacements for the `target_abi` cfgs with the same values.
600
601<a id="1.91.0-Compiler"></a>
602
603Compiler
604--------
605
606- [Don't warn on never-to-any `as` casts as unreachable](https://github.com/rust-lang/rust/pull/144804)
607
608<a id="1.91.0-Platform-Support"></a>
609
610Platform Support
611----------------
612
613- [Promote `aarch64-pc-windows-gnullvm` and `x86_64-pc-windows-gnullvm` to Tier 2 with host tools.](https://github.com/rust-lang/rust/pull/143031)
614 Note: llvm-tools and MSI installers are missing but will be added in future releases.
615- [Promote `aarch64-pc-windows-msvc` to Tier 1](https://github.com/rust-lang/rust/pull/145682)
616
617Refer to Rust's [platform support page][platform-support-doc]
618for more information on Rust's tiered platform support.
619
620[platform-support-doc]: https://doc.rust-lang.org/rustc/platform-support.html
621
622<a id="1.91.0-Libraries"></a>
623
624Libraries
625---------
626
627- [Print thread ID in panic message](https://github.com/rust-lang/rust/pull/115746)
628- [Fix overly restrictive lifetime in `core::panic::Location::file` return type](https://github.com/rust-lang/rust/pull/132087)
629- [Guarantee parameter order for `_by()` variants of `min` / `max`/ `minmax` in `std::cmp`](https://github.com/rust-lang/rust/pull/139357)
630- [Document assumptions about `Clone` and `Eq` traits](https://github.com/rust-lang/rust/pull/144330/)
631- [`std::thread`: Return error if setting thread stack size fails](https://github.com/rust-lang/rust/pull/144210)
632 This used to panic within the standard library.
633
634<a id="1.91.0-Stabilized-APIs"></a>
635
636Stabilized APIs
637---------------
638
639- [`Path::file_prefix`](https://doc.rust-lang.org/stable/std/path/struct.Path.html#method.file_prefix)
640- [`AtomicPtr::fetch_ptr_add`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicPtr.html#method.fetch_ptr_add)
641- [`AtomicPtr::fetch_ptr_sub`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicPtr.html#method.fetch_ptr_sub)
642- [`AtomicPtr::fetch_byte_add`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicPtr.html#method.fetch_byte_add)
643- [`AtomicPtr::fetch_byte_sub`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicPtr.html#method.fetch_byte_sub)
644- [`AtomicPtr::fetch_or`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicPtr.html#method.fetch_or)
645- [`AtomicPtr::fetch_and`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicPtr.html#method.fetch_and)
646- [`AtomicPtr::fetch_xor`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicPtr.html#method.fetch_xor)
647- [`{integer}::strict_add`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.strict_add)
648- [`{integer}::strict_sub`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.strict_sub)
649- [`{integer}::strict_mul`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.strict_mul)
650- [`{integer}::strict_div`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.strict_div)
651- [`{integer}::strict_div_euclid`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.strict_div_euclid)
652- [`{integer}::strict_rem`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.strict_rem)
653- [`{integer}::strict_rem_euclid`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.strict_rem_euclid)
654- [`{integer}::strict_neg`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.strict_neg)
655- [`{integer}::strict_shl`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.strict_shl)
656- [`{integer}::strict_shr`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.strict_shr)
657- [`{integer}::strict_pow`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.strict_pow)
658- [`i{N}::strict_add_unsigned`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.strict_add_unsigned)
659- [`i{N}::strict_sub_unsigned`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.strict_sub_unsigned)
660- [`i{N}::strict_abs`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.strict_abs)
661- [`u{N}::strict_add_signed`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.strict_add_signed)
662- [`u{N}::strict_sub_signed`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.strict_sub_signed)
663- [`PanicHookInfo::payload_as_str`](https://doc.rust-lang.org/stable/std/panic/struct.PanicHookInfo.html#method.payload_as_str)
664- [`core::iter::chain`](https://doc.rust-lang.org/stable/core/iter/fn.chain.html)
665- [`u{N}::checked_signed_diff`](https://doc.rust-lang.org/stable/std/primitive.u16.html#method.checked_signed_diff)
666- [`core::array::repeat`](https://doc.rust-lang.org/stable/core/array/fn.repeat.html)
667- [`PathBuf::add_extension`](https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#method.add_extension)
668- [`PathBuf::with_added_extension`](https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#method.with_added_extension)
669- [`Duration::from_mins`](https://doc.rust-lang.org/stable/std/time/struct.Duration.html#method.from_mins)
670- [`Duration::from_hours`](https://doc.rust-lang.org/stable/std/time/struct.Duration.html#method.from_hours)
671- [`impl PartialEq<str> for PathBuf`](https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#impl-PartialEq%3Cstr%3E-for-PathBuf)
672- [`impl PartialEq<String> for PathBuf`](https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#impl-PartialEq%3CString%3E-for-PathBuf)
673- [`impl PartialEq<str> for Path`](https://doc.rust-lang.org/stable/std/path/struct.Path.html#impl-PartialEq%3Cstr%3E-for-Path)
674- [`impl PartialEq<String> for Path`](https://doc.rust-lang.org/stable/std/path/struct.Path.html#impl-PartialEq%3CString%3E-for-Path)
675- [`impl PartialEq<PathBuf> for String`](https://doc.rust-lang.org/stable/std/string/struct.String.html#impl-PartialEq%3CPathBuf%3E-for-String)
676- [`impl PartialEq<Path> for String`](https://doc.rust-lang.org/stable/std/string/struct.String.html#impl-PartialEq%3CPath%3E-for-String)
677- [`impl PartialEq<PathBuf> for str`](https://doc.rust-lang.org/stable/std/primitive.str.html#impl-PartialEq%3CPathBuf%3E-for-str)
678- [`impl PartialEq<Path> for str`](https://doc.rust-lang.org/stable/std/primitive.str.html#impl-PartialEq%3CPath%3E-for-str)
679- [`Ipv4Addr::from_octets`](https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.from_octets)
680- [`Ipv6Addr::from_octets`](https://doc.rust-lang.org/stable/std/net/struct.Ipv6Addr.html#method.from_octets)
681- [`Ipv6Addr::from_segments`](https://doc.rust-lang.org/stable/std/net/struct.Ipv6Addr.html#method.from_segments)
682- [`impl<T> Default for Pin<Box<T>> where Box<T>: Default, T: ?Sized`](https://doc.rust-lang.org/stable/std/default/trait.Default.html#impl-Default-for-Pin%3CBox%3CT%3E%3E)
683- [`impl<T> Default for Pin<Rc<T>> where Rc<T>: Default, T: ?Sized`](https://doc.rust-lang.org/stable/std/default/trait.Default.html#impl-Default-for-Pin%3CRc%3CT%3E%3E)
684- [`impl<T> Default for Pin<Arc<T>> where Arc<T>: Default, T: ?Sized`](https://doc.rust-lang.org/stable/std/default/trait.Default.html#impl-Default-for-Pin%3CArc%3CT%3E%3E)
685- [`Cell::as_array_of_cells`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#method.as_array_of_cells)
686- [`u{N}::carrying_add`](https://doc.rust-lang.org/stable/std/primitive.u64.html#method.carrying_add)
687- [`u{N}::borrowing_sub`](https://doc.rust-lang.org/stable/std/primitive.u64.html#method.borrowing_sub)
688- [`u{N}::carrying_mul`](https://doc.rust-lang.org/stable/std/primitive.u64.html#method.carrying_mul)
689- [`u{N}::carrying_mul_add`](https://doc.rust-lang.org/stable/std/primitive.u64.html#method.carrying_mul_add)
690- [`BTreeMap::extract_if`](https://doc.rust-lang.org/stable/std/collections/struct.BTreeMap.html#method.extract_if)
691- [`BTreeSet::extract_if`](https://doc.rust-lang.org/stable/std/collections/struct.BTreeSet.html#method.extract_if)
692- [`impl Debug for windows::ffi::EncodeWide<'_>`](https://doc.rust-lang.org/stable/std/os/windows/ffi/struct.EncodeWide.html#impl-Debug-for-EncodeWide%3C'_%3E)
693- [`str::ceil_char_boundary`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.ceil_char_boundary)
694- [`str::floor_char_boundary`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.floor_char_boundary)
695- [`impl Sum for Saturating<u{N}>`](https://doc.rust-lang.org/stable/std/num/struct.Saturating.html#impl-Sum-for-Saturating%3Cu32%3E)
696- [`impl Sum<&Self> for Saturating<u{N}>`](https://doc.rust-lang.org/stable/std/num/struct.Saturating.html#impl-Sum%3C%26Saturating%3Cu32%3E%3E-for-Saturating%3Cu32%3E)
697- [`impl Product for Saturating<u{N}>`](https://doc.rust-lang.org/stable/std/num/struct.Saturating.html#impl-Product-for-Saturating%3Cu32%3E)
698- [`impl Product<&Self> for Saturating<u{N}>`](https://doc.rust-lang.org/stable/std/num/struct.Saturating.html#impl-Product%3C%26Saturating%3Cu32%3E%3E-for-Saturating%3Cu32%3E)
699
700These previously stable APIs are now stable in const contexts:
701
702- [`<[T; N]>::each_ref`](https://doc.rust-lang.org/stable/std/primitive.array.html#method.each_ref)
703- [`<[T; N]>::each_mut`](https://doc.rust-lang.org/stable/std/primitive.array.html#method.each_mut)
704- [`OsString::new`](https://doc.rust-lang.org/stable/std/ffi/struct.OsString.html#method.new)
705- [`PathBuf::new`](https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#method.new)
706- [`TypeId::of`](https://doc.rust-lang.org/stable/std/any/struct.TypeId.html#method.of)
707- [`ptr::with_exposed_provenance`](https://doc.rust-lang.org/stable/std/ptr/fn.with_exposed_provenance.html)
708- [`ptr::with_exposed_provenance_mut`](https://doc.rust-lang.org/stable/std/ptr/fn.with_exposed_provenance_mut.html)
709
710<a id="1.91.0-Cargo"></a>
711
712Cargo
713-----
714
715- 🎉 Stabilize `build.build-dir`.
716 This config sets the directory where intermediate build artifacts are stored.
717 These artifacts are produced by Cargo and rustc during the build process.
718 End users usually won't need to interact with them, and the layout inside
719 `build-dir` is an implementation detail that may change without notice.
720 ([config doc](https://doc.rust-lang.org/stable/cargo/reference/config.html#buildbuild-dir))
721 ([build cache doc](https://doc.rust-lang.org/stable/cargo/reference/build-cache.html))
722 [#15833](https://github.com/rust-lang/cargo/pull/15833)
723 [#15840](https://github.com/rust-lang/cargo/pull/15840)
724- The `--target` flag and the `build.target` configuration can now take literal
725 `"host-tuple"` string, which will internally be substituted by the host
726 machine's target triple.
727 [#15838](https://github.com/rust-lang/cargo/pull/15838)
728 [#16003](https://github.com/rust-lang/cargo/pull/16003)
729 [#16032](https://github.com/rust-lang/cargo/pull/16032)
730
731<a id="1.91.0-Rustdoc"></a>
732
733Rustdoc
734-----
735- [In search results, rank doc aliases lower than non-alias items with the same name](https://github.com/rust-lang/rust/pull/145100)
736- [Raw pointers now work in type-based search like references](https://github.com/rust-lang/rust/pull/145731). This means you can now search for things like `*const u8 ->`, and additionally functions that take or return raw pointers will now display their signature properly in search results.
737
738<a id="1.91.0-Compatibility-Notes"></a>
739
740Compatibility Notes
741-------------------
742
743- [Always require coroutine captures to be drop-live](https://github.com/rust-lang/rust/pull/144156)
744- [Apple: Always pass SDK root when linking with `cc`, and pass it via `SDKROOT` env var](https://github.com/rust-lang/rust/pull/131477). This should fix linking issues with `rustc` running inside Xcode. Libraries in `/usr/local/lib` may no longer be linked automatically, if you develop or use a crate that relies on this, you should explicitly set `cargo::rustc-link-search=/usr/local/lib` in a `build.rs` script.
745- [Relaxed bounds in associated type bound position like in `TraitRef<AssocTy: ?Sized>` are now correctly forbidden](https://github.com/rust-lang/rust/pull/135331)
746- [Add unstable `#[sanitize(xyz = "on|off")]` built-in attribute that shadows procedural macros with the same name](https://github.com/rust-lang/rust/pull/142681)
747- [Fix the drop checker being more permissive for bindings declared with let-else](https://github.com/rust-lang/rust/pull/143028)
748- [Be more strict when parsing attributes, erroring on many invalid attributes](https://github.com/rust-lang/rust/pull/144689)
749 - [Error on invalid `#[should_panic]` attributes](https://github.com/rust-lang/rust/pull/143808)
750 - [Error on invalid `#[link]` attributes](https://github.com/rust-lang/rust/pull/143193)
751- [Mark all deprecation lints in name resolution as deny-by-default and also report in dependencies](https://github.com/rust-lang/rust/pull/143929)
752- The lint `semicolon_in_expressions_from_macros`, for `macro_rules!` macros in expression position that expand to end in a semicolon (`;`), is now deny-by-default. It was already warn-by-default, and a future compatibility warning (FCW) that warned even in dependencies. This lint will become a hard error in the future.
753- [Trait impl modifiers (e.g., `unsafe`, `!`, `default`) in inherent impls are no longer syntactically valid](https://github.com/rust-lang/rust/pull/144386)
754- [Start reporting future breakage for `ill_formed_attribute_input` in dependencies](https://github.com/rust-lang/rust/pull/144544)
755- [Restrict the scope of temporaries created by the macros `pin!`, `format_args!`, `write!`, and `writeln!` in `if let` scrutinees in Rust Edition 2024.](https://github.com/rust-lang/rust/pull/145342) This applies [Rust Edition 2024's `if let` temporary scope rules](https://doc.rust-lang.org/edition-guide/rust-2024/temporary-if-let-scope.html) to these temporaries, which previously could live past the `if` expression regardless of Edition.
756- [Invalid numeric literal suffixes in tuple indexing, tuple struct indexing, and struct field name positions are now correctly rejected](https://github.com/rust-lang/rust/pull/145463)
757- [Closures marked with the keyword `static` are now syntactically invalid](https://github.com/rust-lang/rust/pull/145604)
758- [Shebangs inside `--cfg` and `--check-cfg` arguments are no longer allowed](https://github.com/rust-lang/rust/pull/146211)
759- [Add future incompatibility lint for temporary lifetime shortening in Rust 1.92](https://github.com/rust-lang/rust/pull/147056)
760
761Cargo compatibility notes:
762
763- `cargo publish` no longer keeps `.crate` tarballs as final build artifacts
764 when `build.build-dir` is set. These tarballs were previously included due to
765 an oversight and are now treated as intermediate artifacts.
766 To get `.crate` tarballs as final artifacts, use `cargo package`.
767 In a future version, this change will apply regardless of `build.build-dir`.
768 [#15910](https://github.com/rust-lang/cargo/pull/15910)
769- Adjust Cargo messages to match rustc diagnostic style.
770 This changes some of the terminal colors used by Cargo messages.
771 [#15928](https://github.com/rust-lang/cargo/pull/15928)
772- Tools and projects relying on the
773 [internal details of Cargo's `build-dir`](https://doc.rust-lang.org/cargo/reference/build-cache.html)
774 may not work for users changing their `build-dir` layout.
775 For those doing so, we'd recommend proactively testing these cases
776 particularly as we are considering changing the default location of the `build-dir` in the future
777 ([cargo#16147](https://github.com/rust-lang/cargo/issues/16147)).
778 If you can't migrate off of Cargo's internal details,
779 we'd like to learn more about your use case as we prepare to change the layout of the `build-dir`
780 ([cargo#15010](https://github.com/rust-lang/cargo/issues/15010)).
781
782<a id="1.91.0-Internal-Changes"></a>
783
784Internal Changes
785----------------
786
787These changes do not affect any public interfaces of Rust, but they represent
788significant improvements to the performance or internals of rustc and related
789tools.
790
791- [Update to LLVM 21](https://github.com/rust-lang/rust/pull/143684)
792
793
794Version 1.90.0 (2025-09-18)
795===========================
796
797<a id="1.90-Language"></a>
798
799Language
800--------
801- [Split up the `unknown_or_malformed_diagnostic_attributes` lint](https://github.com/rust-lang/rust/pull/140717). This lint has been split up into four finer-grained lints, with `unknown_or_malformed_diagnostic_attributes` now being the lint group that contains these lints:
802 1. `unknown_diagnostic_attributes`: unknown to the current compiler
803 2. `misplaced_diagnostic_attributes`: placed on the wrong item
804 3. `malformed_diagnostic_attributes`: malformed attribute syntax or options
805 4. `malformed_diagnostic_format_literals`: malformed format string literal
806- [Allow constants whose final value has references to mutable/external memory, but reject such constants as patterns](https://github.com/rust-lang/rust/pull/140942)
807- [Allow volatile access to non-Rust memory, including address 0](https://github.com/rust-lang/rust/pull/141260)
808
809
810<a id="1.90-Compiler"></a>
811
812Compiler
813--------
814- [Use `lld` by default on `x86_64-unknown-linux-gnu`](https://github.com/rust-lang/rust/pull/140525).
815- [Tier 3 `musl` targets now link dynamically by default](https://github.com/rust-lang/rust/pull/144410). Affected targets:
816 - `mips64-unknown-linux-muslabi64`
817 - `powerpc64-unknown-linux-musl`
818 - `powerpc-unknown-linux-musl`
819 - `powerpc-unknown-linux-muslspe`
820 - `riscv32gc-unknown-linux-musl`
821 - `s390x-unknown-linux-musl`
822 - `thumbv7neon-unknown-linux-musleabihf`
823
824
825<a id="1.90-Platform-Support"></a>
826
827Platform Support
828----------------
829- [Demote `x86_64-apple-darwin` to Tier 2 with host tools](https://github.com/rust-lang/rust/pull/145252)
830
831
832Refer to Rust's [platform support page][platform-support-doc]
833for more information on Rust's tiered platform support.
834
835[platform-support-doc]: https://doc.rust-lang.org/rustc/platform-support.html
836
837<a id="1.90-Libraries"></a>
838
839Libraries
840---------
841- [Stabilize `u*::{checked,overflowing,saturating,wrapping}_sub_signed`](https://github.com/rust-lang/rust/issues/126043)
842- [Allow comparisons between `CStr`, `CString`, and `Cow<CStr>`](https://github.com/rust-lang/rust/pull/137268)
843- [Remove some unsized tuple impls since unsized tuples can't be constructed](https://github.com/rust-lang/rust/pull/138340)
844- [Set `MSG_NOSIGNAL` for `UnixStream`](https://github.com/rust-lang/rust/pull/140005)
845- [`proc_macro::Ident::new` now supports `$crate`.](https://github.com/rust-lang/rust/pull/141996)
846- [Guarantee the pointer returned from `Thread::into_raw` has at least 8 bytes of alignment](https://github.com/rust-lang/rust/pull/143859)
847
848
849<a id="1.90-Stabilized-APIs"></a>
850
851Stabilized APIs
852---------------
853
854- [`u{n}::checked_sub_signed`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.checked_sub_signed)
855- [`u{n}::overflowing_sub_signed`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.overflowing_sub_signed)
856- [`u{n}::saturating_sub_signed`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.saturating_sub_signed)
857- [`u{n}::wrapping_sub_signed`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.wrapping_sub_signed)
858- [`impl Copy for IntErrorKind`](https://doc.rust-lang.org/stable/std/num/enum.IntErrorKind.html#impl-Copy-for-IntErrorKind)
859- [`impl Hash for IntErrorKind`](https://doc.rust-lang.org/stable/std/num/enum.IntErrorKind.html#impl-Hash-for-IntErrorKind)
860- [`impl PartialEq<&CStr> for CStr`](https://doc.rust-lang.org/stable/std/ffi/struct.CStr.html#impl-PartialEq%3C%26CStr%3E-for-CStr)
861- [`impl PartialEq<CString> for CStr`](https://doc.rust-lang.org/stable/std/ffi/struct.CStr.html#impl-PartialEq%3CCString%3E-for-CStr)
862- [`impl PartialEq<Cow<CStr>> for CStr`](https://doc.rust-lang.org/stable/std/ffi/struct.CStr.html#impl-PartialEq%3CCow%3C'_,+CStr%3E%3E-for-CStr)
863- [`impl PartialEq<&CStr> for CString`](https://doc.rust-lang.org/stable/std/ffi/struct.CString.html#impl-PartialEq%3C%26CStr%3E-for-CString)
864- [`impl PartialEq<CStr> for CString`](https://doc.rust-lang.org/stable/std/ffi/struct.CString.html#impl-PartialEq%3CCStr%3E-for-CString)
865- [`impl PartialEq<Cow<CStr>> for CString`](https://doc.rust-lang.org/stable/std/ffi/struct.CString.html#impl-PartialEq%3CCow%3C'_,+CStr%3E%3E-for-CString)
866- [`impl PartialEq<&CStr> for Cow<CStr>`](https://doc.rust-lang.org/stable/std/borrow/enum.Cow.html#impl-PartialEq%3C%26CStr%3E-for-Cow%3C'_,+CStr%3E)
867- [`impl PartialEq<CStr> for Cow<CStr>`](https://doc.rust-lang.org/stable/std/borrow/enum.Cow.html#impl-PartialEq%3CCStr%3E-for-Cow%3C'_,+CStr%3E)
868- [`impl PartialEq<CString> for Cow<CStr>`](https://doc.rust-lang.org/stable/std/borrow/enum.Cow.html#impl-PartialEq%3CCString%3E-for-Cow%3C'_,+CStr%3E)
869
870
871These previously stable APIs are now stable in const contexts:
872
873- [`<[T]>::reverse`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.reverse)
874- [`f32::floor`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.floor)
875- [`f32::ceil`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.ceil)
876- [`f32::trunc`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.trunc)
877- [`f32::fract`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.fract)
878- [`f32::round`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.round)
879- [`f32::round_ties_even`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.round_ties_even)
880- [`f64::floor`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.floor)
881- [`f64::ceil`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.ceil)
882- [`f64::trunc`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.trunc)
883- [`f64::fract`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.fract)
884- [`f64::round`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.round)
885- [`f64::round_ties_even`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.round_ties_even)
886
887
888<a id="1.90-Cargo"></a>
889
890Cargo
891-----
892- [Add `http.proxy-cainfo` config for proxy certs](https://github.com/rust-lang/cargo/pull/15374/)
893- [Use `gix` for `cargo package`](https://github.com/rust-lang/cargo/pull/15534/)
894- [feat(publish): Stabilize multi-package publishing](https://github.com/rust-lang/cargo/pull/15636/)
895
896<a id="1.90-Rustdoc"></a>
897
898Rustdoc
899-----
900- [Add ways to collapse all impl blocks](https://github.com/rust-lang/rust/pull/141663). Previously the "Summary" button and "-" keyboard shortcut would never collapse `impl` blocks, now they do when shift is held
901- [Display unsafe attributes with `unsafe()` wrappers](https://github.com/rust-lang/rust/pull/143662)
902
903
904<a id="1.90-Compatibility-Notes"></a>
905
906Compatibility Notes
907-------------------
908- [Use `lld` by default on `x86_64-unknown-linux-gnu`](https://github.com/rust-lang/rust/pull/140525).
909 See also <https://blog.rust-lang.org/2025/09/01/rust-lld-on-1.90.0-stable/>.
910- [Make `core::iter::Fuse`'s `Default` impl construct `I::default()` internally as promised in the docs instead of always being empty](https://github.com/rust-lang/rust/pull/140985)
911- [Set `MSG_NOSIGNAL` for `UnixStream`](https://github.com/rust-lang/rust/pull/140005)
912 This may change program behavior but results in the same behavior as other primitives (e.g., stdout, network sockets).
913 Programs relying on signals to terminate them should update handling of sockets to handle errors on write by exiting.
914- [On Unix `std::env::home_dir` will use the fallback if the `HOME` environment variable is empty](https://github.com/rust-lang/rust/pull/141840)
915- We now [reject unsupported `extern "{abi}"`s consistently in all positions](https://github.com/rust-lang/rust/pull/142134). This primarily affects the use of implementing traits on an `extern "{abi}"` function pointer, like `extern "stdcall" fn()`, on a platform that doesn't support that, like aarch64-unknown-linux-gnu. Direct usage of these unsupported ABI strings by declaring or defining functions was already rejected, so this is only a change for consistency.
916- [const-eval: error when initializing a static writes to that static](https://github.com/rust-lang/rust/pull/143084)
917- [Check that the `proc_macro_derive` macro has correct arguments when applied to the crate root](https://github.com/rust-lang/rust/pull/143607)
918
919
920Version 1.89.0 (2025-08-07)
921==========================
922
923<a id="1.89.0-Language"></a>
924
925Language
926--------
927- [Stabilize explicitly inferred const arguments (`feature(generic_arg_infer)`)](https://github.com/rust-lang/rust/pull/141610)
928- [Add a warn-by-default `mismatched_lifetime_syntaxes` lint.](https://github.com/rust-lang/rust/pull/138677)
929 This lint detects when the same lifetime is referred to by different syntax categories between function arguments and return values, which can be confusing to read, especially in unsafe code.
930 This lint supersedes the warn-by-default `elided_named_lifetimes` lint.
931- [Expand `unpredictable_function_pointer_comparisons` to also lint on function pointer comparisons in external macros](https://github.com/rust-lang/rust/pull/134536)
932- [Make the `dangerous_implicit_autorefs` lint deny-by-default](https://github.com/rust-lang/rust/pull/141661)
933- [Stabilize the avx512 target features](https://github.com/rust-lang/rust/pull/138940)
934- [Stabilize `kl` and `widekl` target features for x86](https://github.com/rust-lang/rust/pull/140766)
935- [Stabilize `sha512`, `sm3` and `sm4` target features for x86](https://github.com/rust-lang/rust/pull/140767)
936- [Stabilize LoongArch target features `f`, `d`, `frecipe`, `lasx`, `lbt`, `lsx`, and `lvz`](https://github.com/rust-lang/rust/pull/135015)
937- [Remove `i128` and `u128` from `improper_ctypes_definitions`](https://github.com/rust-lang/rust/pull/137306)
938- [Stabilize `repr128` (`#[repr(u128)]`, `#[repr(i128)]`)](https://github.com/rust-lang/rust/pull/138285)
939- [Allow `#![doc(test(attr(..)))]` everywhere](https://github.com/rust-lang/rust/pull/140560)
940- [Extend temporary lifetime extension to also go through tuple struct and tuple variant constructors](https://github.com/rust-lang/rust/pull/140593)
941- [`extern "C"` functions on the `wasm32-unknown-unknown` target now have a standards compliant ABI](https://blog.rust-lang.org/2025/04/04/c-abi-changes-for-wasm32-unknown-unknown/)
942
943<a id="1.89.0-Compiler"></a>
944
945Compiler
946--------
947- [Default to non-leaf frame pointers on aarch64-linux](https://github.com/rust-lang/rust/pull/140832)
948- [Enable non-leaf frame pointers for Arm64EC Windows](https://github.com/rust-lang/rust/pull/140862)
949- [Set Apple frame pointers by architecture](https://github.com/rust-lang/rust/pull/141797)
950
951
952<a id="1.89.0-Platform-Support"></a>
953
954Platform Support
955----------------
956- [Add new Tier-3 targets `loongarch32-unknown-none` and `loongarch32-unknown-none-softfloat`](https://github.com/rust-lang/rust/pull/142053)
957- [`x86_64-apple-darwin` is in the process of being demoted to Tier 2 with host tools](https://github.com/rust-lang/rfcs/pull/3841)
958
959Refer to Rust's [platform support page][platform-support-doc]
960for more information on Rust's tiered platform support.
961
962[platform-support-doc]: https://doc.rust-lang.org/rustc/platform-support.html
963
964<a id="1.89.0-Libraries"></a>
965
966Libraries
967---------
968- [Specify the base path for `file!`](https://github.com/rust-lang/rust/pull/134442)
969- [Allow storing `format_args!()` in a variable](https://github.com/rust-lang/rust/pull/140748)
970- [Add `#[must_use]` to `[T; N]::map`](https://github.com/rust-lang/rust/pull/140957)
971- [Implement `DerefMut` for `Lazy{Cell,Lock}`](https://github.com/rust-lang/rust/pull/129334)
972- [Implement `Default` for `array::IntoIter`](https://github.com/rust-lang/rust/pull/141574)
973- [Implement `Clone` for `slice::ChunkBy`](https://github.com/rust-lang/rust/pull/138016)
974- [Implement `io::Seek` for `io::Take`](https://github.com/rust-lang/rust/pull/138023)
975
976
977<a id="1.89.0-Stabilized-APIs"></a>
978
979Stabilized APIs
980---------------
981
982- [`NonZero<char>`](https://doc.rust-lang.org/stable/std/num/struct.NonZero.html)
983- Many intrinsics for x86, not enumerated here
984 - [AVX512 intrinsics](https://github.com/rust-lang/rust/issues/111137)
985 - [`SHA512`, `SM3` and `SM4` intrinsics](https://github.com/rust-lang/rust/issues/126624)
986- [`File::lock`](https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.lock)
987- [`File::lock_shared`](https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.lock_shared)
988- [`File::try_lock`](https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.try_lock)
989- [`File::try_lock_shared`](https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.try_lock_shared)
990- [`File::unlock`](https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.unlock)
991- [`NonNull::from_ref`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.from_ref)
992- [`NonNull::from_mut`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.from_mut)
993- [`NonNull::without_provenance`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.without_provenance)
994- [`NonNull::with_exposed_provenance`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.with_exposed_provenance)
995- [`NonNull::expose_provenance`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.expose_provenance)
996- [`OsString::leak`](https://doc.rust-lang.org/stable/std/ffi/struct.OsString.html#method.leak)
997- [`PathBuf::leak`](https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#method.leak)
998- [`Result::flatten`](https://doc.rust-lang.org/stable/std/result/enum.Result.html#method.flatten)
999- [`std::os::linux::net::TcpStreamExt::quickack`](https://doc.rust-lang.org/stable/std/os/linux/net/trait.TcpStreamExt.html#tymethod.quickack)
1000- [`std::os::linux::net::TcpStreamExt::set_quickack`](https://doc.rust-lang.org/stable/std/os/linux/net/trait.TcpStreamExt.html#tymethod.set_quickack)
1001
1002These previously stable APIs are now stable in const contexts:
1003
1004- [`<[T; N]>::as_mut_slice`](https://doc.rust-lang.org/stable/std/primitive.array.html#method.as_mut_slice)
1005- [`<[u8]>::eq_ignore_ascii_case`](https://doc.rust-lang.org/stable/std/primitive.slice.html#impl-%5Bu8%5D/method.eq_ignore_ascii_case)
1006- [`str::eq_ignore_ascii_case`](https://doc.rust-lang.org/stable/std/primitive.str.html#impl-str/method.eq_ignore_ascii_case)
1007
1008
1009<a id="1.89.0-Cargo"></a>
1010
1011Cargo
1012-----
1013- [`cargo fix` and `cargo clippy --fix` now default to the same Cargo target selection as other build commands.](https://github.com/rust-lang/cargo/pull/15192/) Previously it would apply to all targets (like binaries, examples, tests, etc.). The `--edition` flag still applies to all targets.
1014- [Stabilize doctest-xcompile.](https://github.com/rust-lang/cargo/pull/15462/) Doctests are now tested when cross-compiling. Just like other tests, it will use the [`runner` setting](https://doc.rust-lang.org/cargo/reference/config.html#targettriplerunner) to run the tests. If you need to disable tests for a target, you can use the [ignore doctest attribute](https://doc.rust-lang.org/rustdoc/write-documentation/documentation-tests.html#ignoring-targets) to specify the targets to ignore.
1015
1016
1017<a id="1.89.0-Rustdoc"></a>
1018
1019Rustdoc
1020-----
1021- [On mobile, make the sidebar full width and linewrap](https://github.com/rust-lang/rust/pull/139831). This makes long section and item names much easier to deal with on mobile.
1022
1023
1024<a id="1.89.0-Compatibility-Notes"></a>
1025
1026Compatibility Notes
1027-------------------
1028- [Make `missing_fragment_specifier` an unconditional error](https://github.com/rust-lang/rust/pull/128425)
1029- [Enabling the `neon` target feature on `aarch64-unknown-none-softfloat` causes a warning](https://github.com/rust-lang/rust/pull/135160) because mixing code with and without that target feature is not properly supported by LLVM
1030- [Sized Hierarchy: Part I](https://github.com/rust-lang/rust/pull/137944)
1031 - Introduces a small breaking change affecting `?Sized` bounds on impls on recursive types which contain associated type projections. It is not expected to affect any existing published crates. Can be fixed by refactoring the involved types or opting into the `sized_hierarchy` unstable feature. See the [FCP report](https://github.com/rust-lang/rust/pull/137944#issuecomment-2912207485) for a code example.
1032- The warn-by-default `elided_named_lifetimes` lint is [superseded by the warn-by-default `mismatched_lifetime_syntaxes` lint.](https://github.com/rust-lang/rust/pull/138677)
1033- [Error on recursive opaque types earlier in the type checker](https://github.com/rust-lang/rust/pull/139419)
1034- [Type inference side effects from requiring element types of array repeat expressions are `Copy` are now only available at the end of type checking](https://github.com/rust-lang/rust/pull/139635)
1035- [The deprecated accidentally-stable `std::intrinsics::{copy,copy_nonoverlapping,write_bytes}` are now proper intrinsics](https://github.com/rust-lang/rust/pull/139916). There are no debug assertions guarding against UB, and they cannot be coerced to function pointers.
1036- [Remove long-deprecated `std::intrinsics::drop_in_place`](https://github.com/rust-lang/rust/pull/140151)
1037- [Make well-formedness predicates no longer coinductive](https://github.com/rust-lang/rust/pull/140208)
1038- [Remove hack when checking impl method compatibility](https://github.com/rust-lang/rust/pull/140557)
1039- [Remove unnecessary type inference due to built-in trait object impls](https://github.com/rust-lang/rust/pull/141352)
1040- [Lint against "stdcall", "fastcall", and "cdecl" on non-x86-32 targets](https://github.com/rust-lang/rust/pull/141435)
1041- [Future incompatibility warnings relating to the never type (`!`) are now reported in dependencies](https://github.com/rust-lang/rust/pull/141937)
1042- [Ensure `std::ptr::copy_*` intrinsics also perform the static self-init checks](https://github.com/rust-lang/rust/pull/142575)
1043- [`extern "C"` functions on the `wasm32-unknown-unknown` target now have a standards compliant ABI](https://blog.rust-lang.org/2025/04/04/c-abi-changes-for-wasm32-unknown-unknown/)
1044
1045<a id="1.89.0-Internal-Changes"></a>
1046
1047Internal Changes
1048----------------
1049
1050These changes do not affect any public interfaces of Rust, but they represent
1051significant improvements to the performance or internals of rustc and related
1052tools.
1053
1054- [Correctly un-remap compiler sources paths with the `rustc-dev` component](https://github.com/rust-lang/rust/pull/142377)
1055
1056
1057Version 1.88.0 (2025-06-26)
1058==========================
1059
1060<a id="1.88.0-Language"></a>
1061
1062Language
1063--------
1064- [Stabilize `#![feature(let_chains)]` in the 2024 edition.](https://github.com/rust-lang/rust/pull/132833)
1065 This feature allows `&&`-chaining `let` statements inside `if` and `while`, allowing intermixture with boolean expressions. The patterns inside the `let` sub-expressions can be irrefutable or refutable.
1066- [Stabilize `#![feature(naked_functions)]`.](https://github.com/rust-lang/rust/pull/134213)
1067 Naked functions allow writing functions with no compiler-generated epilogue and prologue, allowing full control over the generated assembly for a particular function.
1068- [Stabilize `#![feature(cfg_boolean_literals)]`.](https://github.com/rust-lang/rust/pull/138632)
1069 This allows using boolean literals as `cfg` predicates, e.g. `#[cfg(true)]` and `#[cfg(false)]`.
1070- [Fully de-stabilize the `#[bench]` attribute](https://github.com/rust-lang/rust/pull/134273). Usage of `#[bench]` without `#![feature(custom_test_frameworks)]` already triggered a deny-by-default future-incompatibility lint since Rust 1.77, but will now become a hard error.
1071- [Add warn-by-default `dangerous_implicit_autorefs` lint against implicit autoref of raw pointer dereference.](https://github.com/rust-lang/rust/pull/123239)
1072 The lint [will be bumped to deny-by-default](https://github.com/rust-lang/rust/pull/141661) in the next version of Rust.
1073- [Add `invalid_null_arguments` lint to prevent invalid usage of null pointers.](https://github.com/rust-lang/rust/pull/119220)
1074 This lint is uplifted from `clippy::invalid_null_ptr_usage`.
1075- [Change trait impl candidate preference for builtin impls and trivial where-clauses.](https://github.com/rust-lang/rust/pull/138176)
1076- [Check types of generic const parameter defaults](https://github.com/rust-lang/rust/pull/139646)
1077
1078<a id="1.88.0-Compiler"></a>
1079
1080Compiler
1081--------
1082- [Stabilize `-Cdwarf-version` for selecting the version of DWARF debug information to generate.](https://github.com/rust-lang/rust/pull/136926)
1083
1084
1085<a id="1.88.0-Platform-Support"></a>
1086
1087Platform Support
1088----------------
1089- [Demote `i686-pc-windows-gnu` to Tier 2.](https://blog.rust-lang.org/2025/05/26/demoting-i686-pc-windows-gnu/)
1090
1091
1092Refer to Rust's [platform support page][platform-support-doc]
1093for more information on Rust's tiered platform support.
1094
1095[platform-support-doc]: https://doc.rust-lang.org/rustc/platform-support.html
1096
1097<a id="1.88.0-Libraries"></a>
1098
1099Libraries
1100---------
1101- [Remove backticks from `#[should_panic]` test failure message.](https://github.com/rust-lang/rust/pull/136160)
1102- [Guarantee that `[T; N]::from_fn` is generated in order of increasing indices.](https://github.com/rust-lang/rust/pull/139099), for those passing it a stateful closure.
1103- [The libtest flag `--nocapture` is deprecated in favor of the more consistent `--no-capture` flag.](https://github.com/rust-lang/rust/pull/139224)
1104- [Guarantee that `{float}::NAN` is a quiet NaN.](https://github.com/rust-lang/rust/pull/139483)
1105
1106
1107<a id="1.88.0-Stabilized-APIs"></a>
1108
1109Stabilized APIs
1110---------------
1111
1112- [`Cell::update`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#method.update)
1113- [`impl Default for *const T`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#impl-Default-for-*const+T)
1114- [`impl Default for *mut T`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#impl-Default-for-*mut+T)
1115- [`HashMap::extract_if`](https://doc.rust-lang.org/stable/std/collections/struct.HashMap.html#method.extract_if)
1116- [`HashSet::extract_if`](https://doc.rust-lang.org/stable/std/collections/struct.HashSet.html#method.extract_if)
1117- [`hint::select_unpredictable`](https://doc.rust-lang.org/stable/std/hint/fn.select_unpredictable.html)
1118- [`proc_macro::Span::line`](https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.line)
1119- [`proc_macro::Span::column`](https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.column)
1120- [`proc_macro::Span::start`](https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.start)
1121- [`proc_macro::Span::end`](https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.end)
1122- [`proc_macro::Span::file`](https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.file)
1123- [`proc_macro::Span::local_file`](https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.local_file)
1124- [`<[T]>::as_chunks`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_chunks)
1125- [`<[T]>::as_chunks_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_chunks_mut)
1126- [`<[T]>::as_chunks_unchecked`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_chunks_unchecked)
1127- [`<[T]>::as_chunks_unchecked_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_chunks_unchecked_mut)
1128- [`<[T]>::as_rchunks`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_rchunks)
1129- [`<[T]>::as_rchunks_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_rchunks_mut)
1130- [`mod ffi::c_str`](https://doc.rust-lang.org/stable/std/ffi/c_str/index.html)
1131
1132These previously stable APIs are now stable in const contexts:
1133
1134- [`NonNull<T>::replace`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.replace)
1135- [`<*mut T>::replace`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.replace)
1136- [`std::ptr::swap_nonoverlapping`](https://doc.rust-lang.org/stable/std/ptr/fn.swap_nonoverlapping.html)
1137- [`Cell::replace`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#method.replace)
1138- [`Cell::get`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#method.get)
1139- [`Cell::get_mut`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#method.get_mut)
1140- [`Cell::from_mut`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#method.from_mut)
1141- [`Cell::as_slice_of_cells`](https://doc.rust-lang.org/stable/std/cell/struct.Cell.html#method.as_slice_of_cells)
1142
1143
1144<a id="1.88.0-Cargo"></a>
1145
1146Cargo
1147-----
1148- [Stabilize automatic garbage collection.](https://github.com/rust-lang/cargo/pull/14287/)
1149- [use `zlib-rs` for gzip compression in rust code](https://github.com/rust-lang/cargo/pull/15417/)
1150
1151<a id="1.88.0-Rustdoc"></a>
1152
1153Rustdoc
1154-----
1155- [Doctests can be ignored based on target names using `ignore-*` attributes.](https://github.com/rust-lang/rust/pull/137096)
1156- [Stabilize the `--test-runtool` and `--test-runtool-arg` CLI options to specify a program (like qemu) and its arguments to run a doctest.](https://github.com/rust-lang/rust/pull/137096)
1157
1158<a id="1.88.0-Compatibility-Notes"></a>
1159
1160Compatibility Notes
1161-------------------
1162- [Finish changing the internal representation of pasted tokens](https://github.com/rust-lang/rust/pull/124141). Certain invalid declarative macros that were previously accepted in obscure circumstances are now correctly rejected by the compiler. Use of a `tt` fragment specifier can often fix these macros.
1163- [Fully de-stabilize the `#[bench]` attribute](https://github.com/rust-lang/rust/pull/134273). Usage of `#[bench]` without `#![feature(custom_test_frameworks)]` already triggered a deny-by-default future-incompatibility lint since Rust 1.77, but will now become a hard error.
1164- [Fix borrow checking some always-true patterns.](https://github.com/rust-lang/rust/pull/139042)
1165 The borrow checker was overly permissive in some cases, allowing programs that shouldn't have compiled.
1166- [Update the minimum external LLVM to 19.](https://github.com/rust-lang/rust/pull/139275)
1167- [Make it a hard error to use a vector type with a non-Rust ABI without enabling the required target feature.](https://github.com/rust-lang/rust/pull/139309)
1168
1169Version 1.87.0 (2025-05-15)
1170==========================
1171
1172<a id="1.87.0-Language"></a>
1173
1174Language
1175--------
1176- [Stabilize `asm_goto` feature](https://github.com/rust-lang/rust/pull/133870)
1177- [Allow parsing open beginning ranges (`..EXPR`) after unary operators `!`, `-`, and `*`](https://github.com/rust-lang/rust/pull/134900).
1178- [Don't require method impls for methods with `Self: Sized` bounds in `impl`s for unsized types](https://github.com/rust-lang/rust/pull/135480)
1179- [Stabilize `feature(precise_capturing_in_traits)` allowing `use<...>` bounds on return position `impl Trait` in `trait`s](https://github.com/rust-lang/rust/pull/138128)
1180
1181<a id="1.87.0-Compiler"></a>
1182
1183Compiler
1184--------
1185- [x86: make SSE2 required for i686 targets and use it to pass SIMD types](https://github.com/rust-lang/rust/pull/135408)
1186
1187<a id="1.87.0-Platform-Support"></a>
1188
1189Platform Support
1190----------------
1191- [Remove `i586-pc-windows-msvc` target](https://github.com/rust-lang/rust/pull/137957)
1192
1193Refer to Rust's [platform support page][platform-support-doc]
1194for more information on Rust's tiered platform support.
1195
1196[platform-support-doc]: https://doc.rust-lang.org/rustc/platform-support.html
1197
1198<a id="1.87.0-Libraries"></a>
1199
1200Libraries
1201---------
1202- [Stabilize the anonymous pipe API](https://github.com/rust-lang/rust/issues/127154)
1203- [Add support for unbounded left/right shift operations](https://github.com/rust-lang/rust/issues/129375)
1204- [Print pointer metadata in `Debug` impl of raw pointers](https://github.com/rust-lang/rust/pull/135080)
1205- [`Vec::with_capacity` guarantees it allocates with the amount requested, even if `Vec::capacity` returns a different number.](https://github.com/rust-lang/rust/pull/135933)
1206- Most `std::arch` intrinsics which don't take pointer arguments can now be called from safe code if the caller has the appropriate target features already enabled (https://github.com/rust-lang/stdarch/pull/1714, https://github.com/rust-lang/stdarch/pull/1716, https://github.com/rust-lang/stdarch/pull/1717)
1207- [Undeprecate `env::home_dir`](https://github.com/rust-lang/rust/pull/137327)
1208- [Denote `ControlFlow` as `#[must_use]`](https://github.com/rust-lang/rust/pull/137449)
1209- [Macros such as `assert_eq!` and `vec!` now support `const {...}` expressions](https://github.com/rust-lang/rust/pull/138162)
1210
1211<a id="1.87.0-Stabilized-APIs"></a>
1212
1213Stabilized APIs
1214---------------
1215
1216- [`Vec::extract_if`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.extract_if)
1217- [`vec::ExtractIf`](https://doc.rust-lang.org/stable/std/vec/struct.ExtractIf.html)
1218- [`LinkedList::extract_if`](https://doc.rust-lang.org/stable/std/collections/struct.LinkedList.html#method.extract_if)
1219- [`linked_list::ExtractIf`](https://doc.rust-lang.org/stable/std/collections/linked_list/struct.ExtractIf.html)
1220- [`<[T]>::split_off`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_off)
1221- [`<[T]>::split_off_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_off_mut)
1222- [`<[T]>::split_off_first`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_off_first)
1223- [`<[T]>::split_off_first_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_off_first_mut)
1224- [`<[T]>::split_off_last`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_off_last)
1225- [`<[T]>::split_off_last_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_off_last_mut)
1226- [`String::extend_from_within`](https://doc.rust-lang.org/stable/alloc/string/struct.String.html#method.extend_from_within)
1227- [`os_str::Display`](https://doc.rust-lang.org/stable/std/ffi/os_str/struct.Display.html)
1228- [`OsString::display`](https://doc.rust-lang.org/stable/std/ffi/struct.OsString.html#method.display)
1229- [`OsStr::display`](https://doc.rust-lang.org/stable/std/ffi/struct.OsStr.html#method.display)
1230- [`io::pipe`](https://doc.rust-lang.org/stable/std/io/fn.pipe.html)
1231- [`io::PipeReader`](https://doc.rust-lang.org/stable/std/io/struct.PipeReader.html)
1232- [`io::PipeWriter`](https://doc.rust-lang.org/stable/std/io/struct.PipeWriter.html)
1233- [`impl From<PipeReader> for OwnedHandle`](https://doc.rust-lang.org/stable/std/os/windows/io/struct.OwnedHandle.html#impl-From%3CPipeReader%3E-for-OwnedHandle)
1234- [`impl From<PipeWriter> for OwnedHandle`](https://doc.rust-lang.org/stable/std/os/windows/io/struct.OwnedHandle.html#impl-From%3CPipeWriter%3E-for-OwnedHandle)
1235- [`impl From<PipeReader> for Stdio`](https://doc.rust-lang.org/stable/std/process/struct.Stdio.html)
1236- [`impl From<PipeWriter> for Stdio`](https://doc.rust-lang.org/stable/std/process/struct.Stdio.html#impl-From%3CPipeWriter%3E-for-Stdio)
1237- [`impl From<PipeReader> for OwnedFd`](https://doc.rust-lang.org/stable/std/os/fd/struct.OwnedFd.html#impl-From%3CPipeReader%3E-for-OwnedFd)
1238- [`impl From<PipeWriter> for OwnedFd`](https://doc.rust-lang.org/stable/std/os/fd/struct.OwnedFd.html#impl-From%3CPipeWriter%3E-for-OwnedFd)
1239- [`Box<MaybeUninit<T>>::write`](https://doc.rust-lang.org/stable/std/boxed/struct.Box.html#method.write)
1240- [`impl TryFrom<Vec<u8>> for String`](https://doc.rust-lang.org/stable/std/string/struct.String.html#impl-TryFrom%3CVec%3Cu8%3E%3E-for-String)
1241- [`<*const T>::offset_from_unsigned`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.offset_from_unsigned)
1242- [`<*const T>::byte_offset_from_unsigned`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.byte_offset_from_unsigned)
1243- [`<*mut T>::offset_from_unsigned`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.offset_from_unsigned-1)
1244- [`<*mut T>::byte_offset_from_unsigned`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.byte_offset_from_unsigned-1)
1245- [`NonNull::offset_from_unsigned`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.offset_from_unsigned)
1246- [`NonNull::byte_offset_from_unsigned`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.byte_offset_from_unsigned)
1247- [`<uN>::cast_signed`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.cast_signed)
1248- [`NonZero::<uN>::cast_signed`](https://doc.rust-lang.org/stable/std/num/struct.NonZero.html#method.cast_signed-5).
1249- [`<iN>::cast_unsigned`](https://doc.rust-lang.org/stable/std/primitive.isize.html#method.cast_unsigned).
1250- [`NonZero::<iN>::cast_unsigned`](https://doc.rust-lang.org/stable/std/num/struct.NonZero.html#method.cast_unsigned-5).
1251- [`<uN>::is_multiple_of`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.is_multiple_of)
1252- [`<uN>::unbounded_shl`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.unbounded_shl)
1253- [`<uN>::unbounded_shr`](https://doc.rust-lang.org/stable/std/primitive.usize.html#method.unbounded_shr)
1254- [`<iN>::unbounded_shl`](https://doc.rust-lang.org/stable/std/primitive.isize.html#method.unbounded_shl)
1255- [`<iN>::unbounded_shr`](https://doc.rust-lang.org/stable/std/primitive.isize.html#method.unbounded_shr)
1256- [`<iN>::midpoint`](https://doc.rust-lang.org/stable/std/primitive.isize.html#method.midpoint)
1257- [`<str>::from_utf8`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.from_utf8)
1258- [`<str>::from_utf8_mut`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.from_utf8_mut)
1259- [`<str>::from_utf8_unchecked`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.from_utf8_unchecked)
1260- [`<str>::from_utf8_unchecked_mut`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.from_utf8_unchecked_mut)
1261
1262These previously stable APIs are now stable in const contexts:
1263
1264- [`core::str::from_utf8_mut`](https://doc.rust-lang.org/stable/std/str/fn.from_utf8_mut.html)
1265- [`<[T]>::copy_from_slice`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.copy_from_slice)
1266- [`SocketAddr::set_ip`](https://doc.rust-lang.org/stable/std/net/enum.SocketAddr.html#method.set_ip)
1267- [`SocketAddr::set_port`](https://doc.rust-lang.org/stable/std/net/enum.SocketAddr.html#method.set_port),
1268- [`SocketAddrV4::set_ip`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV4.html#method.set_ip)
1269- [`SocketAddrV4::set_port`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV4.html#method.set_port),
1270- [`SocketAddrV6::set_ip`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV6.html#method.set_ip)
1271- [`SocketAddrV6::set_port`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV6.html#method.set_port)
1272- [`SocketAddrV6::set_flowinfo`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV6.html#method.set_flowinfo)
1273- [`SocketAddrV6::set_scope_id`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV6.html#method.set_scope_id)
1274- [`char::is_digit`](https://doc.rust-lang.org/stable/std/primitive.char.html#method.is_digit)
1275- [`char::is_whitespace`](https://doc.rust-lang.org/stable/std/primitive.char.html#method.is_whitespace)
1276- [`<[[T; N]]>::as_flattened`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_flattened)
1277- [`<[[T; N]]>::as_flattened_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_flattened_mut)
1278- [`String::into_bytes`](https://doc.rust-lang.org/stable/std/string/struct.String.html#method.into_bytes)
1279- [`String::as_str`](https://doc.rust-lang.org/stable/std/string/struct.String.html#method.as_str)
1280- [`String::capacity`](https://doc.rust-lang.org/stable/std/string/struct.String.html#method.capacity)
1281- [`String::as_bytes`](https://doc.rust-lang.org/stable/std/string/struct.String.html#method.as_bytes)
1282- [`String::len`](https://doc.rust-lang.org/stable/std/string/struct.String.html#method.len)
1283- [`String::is_empty`](https://doc.rust-lang.org/stable/std/string/struct.String.html#method.is_empty)
1284- [`String::as_mut_str`](https://doc.rust-lang.org/stable/std/string/struct.String.html#method.as_mut_str)
1285- [`String::as_mut_vec`](https://doc.rust-lang.org/stable/std/string/struct.String.html#method.as_mut_vec)
1286- [`Vec::as_ptr`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.as_ptr)
1287- [`Vec::as_slice`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.as_slice)
1288- [`Vec::capacity`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.capacity)
1289- [`Vec::len`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.len)
1290- [`Vec::is_empty`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.is_empty)
1291- [`Vec::as_mut_slice`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.as_mut_slice)
1292- [`Vec::as_mut_ptr`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.as_mut_ptr)
1293
1294<a id="1.87.0-Cargo"></a>
1295
1296Cargo
1297-----
1298- [Add terminal integration via ANSI OSC 9;4 sequences](https://github.com/rust-lang/cargo/pull/14615/)
1299- [chore: bump openssl to v3](https://github.com/rust-lang/cargo/pull/15232/)
1300- [feat(package): add --exclude-lockfile flag](https://github.com/rust-lang/cargo/pull/15234/)
1301
1302<a id="1.87.0-Compatibility-Notes"></a>
1303
1304Compatibility Notes
1305-------------------
1306- [Rust now raises an error for macro invocations inside the `#![crate_name]` attribute](https://github.com/rust-lang/rust/pull/127581)
1307- [Unstable fields are now always considered to be inhabited](https://github.com/rust-lang/rust/pull/133889)
1308- [Macro arguments of unary operators followed by open beginning ranges may now be matched differently](https://github.com/rust-lang/rust/pull/134900)
1309- [Make `Debug` impl of raw pointers print metadata if present](https://github.com/rust-lang/rust/pull/135080)
1310- [Warn against function pointers using unsupported ABI strings in dependencies](https://github.com/rust-lang/rust/pull/135767)
1311- [Associated types on `dyn` types are no longer deduplicated](https://github.com/rust-lang/rust/pull/136458)
1312- [Forbid attributes on `..` inside of struct patterns (`let Struct { #[attribute] .. }) =`](https://github.com/rust-lang/rust/pull/136490)
1313- [Make `ptr_cast_add_auto_to_object` lint into hard error](https://github.com/rust-lang/rust/pull/136764)
1314- Many `std::arch` intrinsics are now safe to call in some contexts, there may now be new `unused_unsafe` warnings in existing codebases.
1315- [Limit `width` and `precision` formatting options to 16 bits on all targets](https://github.com/rust-lang/rust/pull/136932)
1316- [Turn order dependent trait objects future incompat warning into a hard error](https://github.com/rust-lang/rust/pull/136968)
1317- [Denote `ControlFlow` as `#[must_use]`](https://github.com/rust-lang/rust/pull/137449)
1318- [Windows: The standard library no longer links `advapi32`, except on win7.](https://github.com/rust-lang/rust/pull/138233) Code such as C libraries that were relying on this assumption may need to explicitly link advapi32.
1319- [Proc macros can no longer observe expanded `cfg(true)` attributes.](https://github.com/rust-lang/rust/pull/138844)
1320- [Start changing the internal representation of pasted tokens](https://github.com/rust-lang/rust/pull/124141). Certain invalid declarative macros that were previously accepted in obscure circumstances are now correctly rejected by the compiler. Use of a `tt` fragment specifier can often fix these macros.
1321- [Don't allow flattened format_args in const.](https://github.com/rust-lang/rust/pull/139624)
1322
1323<a id="1.87.0-Internal-Changes"></a>
1324
1325Internal Changes
1326----------------
1327
1328These changes do not affect any public interfaces of Rust, but they represent
1329significant improvements to the performance or internals of rustc and related
1330tools.
1331
1332- [Update to LLVM 20](https://github.com/rust-lang/rust/pull/135763)
1333
1334
1335Version 1.86.0 (2025-04-03)
1336==========================
1337
1338<a id="1.86.0-Language"></a>
1339
1340Language
1341--------
1342- [Stabilize upcasting trait objects to supertraits.](https://github.com/rust-lang/rust/pull/134367)
1343- [Allow safe functions to be marked with the `#[target_feature]` attribute.](https://github.com/rust-lang/rust/pull/134090)
1344- [The `missing_abi` lint now warns-by-default.](https://github.com/rust-lang/rust/pull/132397)
1345- Rust now lints about double negations, to catch cases that might have intended to be a prefix decrement operator (`--x`) as written in other languages. This was previously a clippy lint, `clippy::double_neg`, and is [now available directly in Rust as `double_negations`.](https://github.com/rust-lang/rust/pull/126604)
1346- [More pointers are now detected as definitely not-null based on their alignment in const eval.](https://github.com/rust-lang/rust/pull/133700)
1347- [Empty `repr()` attribute applied to invalid items are now correctly rejected.](https://github.com/rust-lang/rust/pull/133925)
1348- [Inner attributes `#![test]` and `#![rustfmt::skip]` are no longer accepted in more places than intended.](https://github.com/rust-lang/rust/pull/134276)
1349
1350<a id="1.86.0-Compiler"></a>
1351
1352Compiler
1353--------
1354- [Debug-assert that raw pointers are non-null on access.](https://github.com/rust-lang/rust/pull/134424)
1355- [Change `-O` to mean `-C opt-level=3` instead of `-C opt-level=2` to match Cargo's defaults.](https://github.com/rust-lang/rust/pull/135439)
1356- [Fix emission of `overflowing_literals` under certain macro environments.](https://github.com/rust-lang/rust/pull/136393)
1357
1358<a id="1.86.0-Platform-Support"></a>
1359
1360Platform Support
1361----------------
1362- [Replace `i686-unknown-redox` target with `i586-unknown-redox`.](https://github.com/rust-lang/rust/pull/136698)
1363- [Increase baseline CPU of `i686-unknown-hurd-gnu` to Pentium 4.](https://github.com/rust-lang/rust/pull/136700)
1364- New tier 3 targets:
1365 - [`{aarch64-unknown,x86_64-pc}-nto-qnx710_iosock`](https://github.com/rust-lang/rust/pull/133631).
1366 For supporting Neutrino QNX 7.1 with `io-socket` network stack.
1367 - [`{aarch64-unknown,x86_64-pc}-nto-qnx800`](https://github.com/rust-lang/rust/pull/133631).
1368 For supporting Neutrino QNX 8.0 (`no_std`-only).
1369 - [`{x86_64,i686}-win7-windows-gnu`](https://github.com/rust-lang/rust/pull/134609).
1370 Intended for backwards compatibility with Windows 7. `{x86_64,i686}-win7-windows-msvc` are the Windows MSVC counterparts that already exist as Tier 3 targets.
1371 - [`amdgcn-amd-amdhsa`](https://github.com/rust-lang/rust/pull/134740).
1372 - [`x86_64-pc-cygwin`](https://github.com/rust-lang/rust/pull/134999).
1373 - [`{mips,mipsel}-mti-none-elf`](https://github.com/rust-lang/rust/pull/135074).
1374 Initial bare-metal support.
1375 - [`m68k-unknown-none-elf`](https://github.com/rust-lang/rust/pull/135085).
1376 - [`armv7a-nuttx-{eabi,eabihf}`, `aarch64-unknown-nuttx`, and `thumbv7a-nuttx-{eabi,eabihf}`](https://github.com/rust-lang/rust/pull/135757).
1377
1378Refer to Rust's [platform support page][platform-support-doc]
1379for more information on Rust's tiered platform support.
1380
1381<a id="1.86.0-Libraries"></a>
1382
1383Libraries
1384---------
1385- The type of `FromBytesWithNulError` in `CStr::from_bytes_with_nul(bytes: &[u8]) -> Result<&Self, FromBytesWithNulError>` was [changed from an opaque struct to an enum](https://github.com/rust-lang/rust/pull/134143), allowing users to examine why the conversion failed.
1386- [Remove `RustcDecodable` and `RustcEncodable`.](https://github.com/rust-lang/rust/pull/134272)
1387- [Deprecate libtest's `--logfile` option.](https://github.com/rust-lang/rust/pull/134283)
1388- [On recent versions of Windows, `std::fs::remove_file` will now remove read-only files.](https://github.com/rust-lang/rust/pull/134679)
1389
1390<a id="1.86.0-Stabilized-APIs"></a>
1391
1392Stabilized APIs
1393---------------
1394
1395- [`{float}::next_down`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.next_down)
1396- [`{float}::next_up`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.next_up)
1397- [`<[_]>::get_disjoint_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.get_disjoint_mut)
1398- [`<[_]>::get_disjoint_unchecked_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.get_disjoint_unchecked_mut)
1399- [`slice::GetDisjointMutError`](https://doc.rust-lang.org/stable/std/slice/enum.GetDisjointMutError.html)
1400- [`HashMap::get_disjoint_mut`](https://doc.rust-lang.org/std/collections/hash_map/struct.HashMap.html#method.get_disjoint_mut)
1401- [`HashMap::get_disjoint_unchecked_mut`](https://doc.rust-lang.org/std/collections/hash_map/struct.HashMap.html#method.get_disjoint_unchecked_mut)
1402- [`NonZero::count_ones`](https://doc.rust-lang.org/stable/std/num/struct.NonZero.html#method.count_ones)
1403- [`Vec::pop_if`](https://doc.rust-lang.org/std/vec/struct.Vec.html#method.pop_if)
1404- [`sync::Once::wait`](https://doc.rust-lang.org/stable/std/sync/struct.Once.html#method.wait)
1405- [`sync::Once::wait_force`](https://doc.rust-lang.org/stable/std/sync/struct.Once.html#method.wait_force)
1406- [`sync::OnceLock::wait`](https://doc.rust-lang.org/stable/std/sync/struct.OnceLock.html#method.wait)
1407
1408These APIs are now stable in const contexts:
1409
1410- [`hint::black_box`](https://doc.rust-lang.org/stable/std/hint/fn.black_box.html)
1411- [`io::Cursor::get_mut`](https://doc.rust-lang.org/stable/std/io/struct.Cursor.html#method.get_mut)
1412- [`io::Cursor::set_position`](https://doc.rust-lang.org/stable/std/io/struct.Cursor.html#method.set_position)
1413- [`str::is_char_boundary`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.is_char_boundary)
1414- [`str::split_at`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.split_at)
1415- [`str::split_at_checked`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.split_at_checked)
1416- [`str::split_at_mut`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.split_at_mut)
1417- [`str::split_at_mut_checked`](https://doc.rust-lang.org/stable/std/primitive.str.html#method.split_at_mut_checked)
1418
1419<a id="1.86.0-Cargo"></a>
1420
1421Cargo
1422-----
1423- [When merging, replace rather than combine configuration keys that refer to a program path and its arguments.](https://github.com/rust-lang/cargo/pull/15066/)
1424- [Error if both `--package` and `--workspace` are passed but the requested package is missing.](https://github.com/rust-lang/cargo/pull/15071/) This was previously silently ignored, which was considered a bug since missing packages should be reported.
1425- [Deprecate the token argument in `cargo login` to avoid shell history leaks.](https://github.com/rust-lang/cargo/pull/15057/)
1426- [Simplify the implementation of `SourceID` comparisons.](https://github.com/rust-lang/cargo/pull/14980/) This may potentially change behavior if the canonicalized URL compares differently in alternative registries.
1427
1428<a id="1.86.0-Rustdoc"></a>
1429
1430Rustdoc
1431-----
1432- [Add a sans-serif font setting.](https://github.com/rust-lang/rust/pull/133636)
1433
1434<a id="1.86.0-Compatibility-Notes"></a>
1435
1436Compatibility Notes
1437-------------------
1438- [The `wasm_c_abi` future compatibility warning is now a hard error.](https://github.com/rust-lang/rust/pull/133951)
1439 Users of `wasm-bindgen` should upgrade to at least version 0.2.89, otherwise compilation will fail.
1440- [Remove long-deprecated no-op attributes `#![no_start]` and `#![crate_id]`.](https://github.com/rust-lang/rust/pull/134300)
1441- [The future incompatibility lint `cenum_impl_drop_cast` has been made into a hard error.](https://github.com/rust-lang/rust/pull/135964) This means it is now an error to cast a field-less enum to an integer if the enum implements `Drop`.
1442- [SSE2 is now required for "i686" 32-bit x86 hard-float targets; disabling it causes a warning that will become a hard error eventually.](https://github.com/rust-lang/rust/pull/137037)
1443 To compile for pre-SSE2 32-bit x86, use a "i586" target instead.
1444
1445<a id="1.86.0-Internal-Changes"></a>
1446
1447Internal Changes
1448----------------
1449
1450These changes do not affect any public interfaces of Rust, but they represent
1451significant improvements to the performance or internals of rustc and related
1452tools.
1453
1454- [Build the rustc on AArch64 Linux with ThinLTO + PGO.](https://github.com/rust-lang/rust/pull/133807)
1455 The ARM 64-bit compiler (AArch64) on Linux is now optimized with ThinLTO and PGO, similar to the optimizations we have already performed for the x86-64 compiler on Linux. This should make it up to 30% faster.
1456
1457
1458Version 1.85.1 (2025-03-18)
1459==========================
1460
1461<a id="1.85.1"></a>
1462
1463- [Fix the doctest-merging feature of the 2024 Edition.](https://github.com/rust-lang/rust/pull/137899/)
1464- [Relax some `target_feature` checks when generating docs.](https://github.com/rust-lang/rust/pull/137632/)
1465- [Fix errors in `std::fs::rename` on Windows 10, version 1607.](https://github.com/rust-lang/rust/pull/137528/)
1466- [Downgrade bootstrap `cc` to fix custom targets.](https://github.com/rust-lang/rust/pull/137460/)
1467- [Skip submodule updates when building Rust from a source tarball.](https://github.com/rust-lang/rust/pull/137338/)
1468
1469Version 1.85.0 (2025-02-20)
1470==========================
1471
1472<a id="1.85.0-Language"></a>
1473
1474Language
1475--------
1476- [The 2024 Edition is now stable.](https://github.com/rust-lang/rust/pull/133349)
1477 See [the edition guide](https://doc.rust-lang.org/nightly/edition-guide/rust-2024/index.html) for more details.
1478- [Stabilize async closures](https://github.com/rust-lang/rust/pull/132706)
1479 See [RFC 3668](https://rust-lang.github.io/rfcs/3668-async-closures.html) for more details.
1480- [Stabilize `#[diagnostic::do_not_recommend]`](https://github.com/rust-lang/rust/pull/132056)
1481- [Add `unpredictable_function_pointer_comparisons` lint to warn against function pointer comparisons](https://github.com/rust-lang/rust/pull/118833)
1482- [Lint on combining `#[no_mangle]` and `#[export_name]` attributes.](https://github.com/rust-lang/rust/pull/131558)
1483
1484<a id="1.85.0-Compiler"></a>
1485
1486Compiler
1487--------
1488- [The unstable flag `-Zpolymorphize` has been removed](https://github.com/rust-lang/rust/pull/133883), see https://github.com/rust-lang/compiler-team/issues/810 for some background.
1489
1490<a id="1.85.0-Platform-Support"></a>
1491
1492Platform Support
1493----------------
1494- [Promote `powerpc64le-unknown-linux-musl` to tier 2 with host tools](https://github.com/rust-lang/rust/pull/133801)
1495
1496Refer to Rust's [platform support page][platform-support-doc]
1497for more information on Rust's tiered platform support.
1498
1499<a id="1.85.0-Libraries"></a>
1500
1501Libraries
1502---------
1503- [Panics in the standard library now have a leading `library/` in their path](https://github.com/rust-lang/rust/pull/132390)
1504- [`std::env::home_dir()` on Windows now ignores the non-standard `$HOME` environment variable](https://github.com/rust-lang/rust/pull/132515)
1505
1506 It will be un-deprecated in a subsequent release.
1507- [Add `AsyncFn*` to the prelude in all editions.](https://github.com/rust-lang/rust/pull/132611)
1508
1509<a id="1.85.0-Stabilized-APIs"></a>
1510
1511Stabilized APIs
1512---------------
1513
1514- [`BuildHasherDefault::new`](https://doc.rust-lang.org/stable/std/hash/struct.BuildHasherDefault.html#method.new)
1515- [`ptr::fn_addr_eq`](https://doc.rust-lang.org/std/ptr/fn.fn_addr_eq.html)
1516- [`io::ErrorKind::QuotaExceeded`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.QuotaExceeded)
1517- [`io::ErrorKind::CrossesDevices`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.CrossesDevices)
1518- [`{float}::midpoint`](https://doc.rust-lang.org/core/primitive.f32.html#method.midpoint)
1519- [Unsigned `{integer}::midpoint`](https://doc.rust-lang.org/std/primitive.u64.html#method.midpoint)
1520- [`NonZeroU*::midpoint`](https://doc.rust-lang.org/std/num/type.NonZeroU32.html#method.midpoint)
1521- [impl `std::iter::Extend` for tuples with arity 1 through 12](https://doc.rust-lang.org/stable/std/iter/trait.Extend.html#impl-Extend%3C(A,)%3E-for-(EA,))
1522- [`FromIterator<(A, ...)>` for tuples with arity 1 through 12](https://doc.rust-lang.org/stable/std/iter/trait.FromIterator.html#impl-FromIterator%3C(EA,)%3E-for-(A,))
1523- [`std::task::Waker::noop`](https://doc.rust-lang.org/stable/std/task/struct.Waker.html#method.noop)
1524
1525These APIs are now stable in const contexts:
1526
1527- [`mem::size_of_val`](https://doc.rust-lang.org/stable/std/mem/fn.size_of_val.html)
1528- [`mem::align_of_val`](https://doc.rust-lang.org/stable/std/mem/fn.align_of_val.html)
1529- [`Layout::for_value`](https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.for_value)
1530- [`Layout::align_to`](https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.align_to)
1531- [`Layout::pad_to_align`](https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.pad_to_align)
1532- [`Layout::extend`](https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.extend)
1533- [`Layout::array`](https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.array)
1534- [`std::mem::swap`](https://doc.rust-lang.org/stable/std/mem/fn.swap.html)
1535- [`std::ptr::swap`](https://doc.rust-lang.org/stable/std/ptr/fn.swap.html)
1536- [`NonNull::new`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.new)
1537- [`HashMap::with_hasher`](https://doc.rust-lang.org/stable/std/collections/struct.HashMap.html#method.with_hasher)
1538- [`HashSet::with_hasher`](https://doc.rust-lang.org/stable/std/collections/struct.HashSet.html#method.with_hasher)
1539- [`BuildHasherDefault::new`](https://doc.rust-lang.org/stable/std/hash/struct.BuildHasherDefault.html#method.new)
1540- [`<float>::recip`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.recip)
1541- [`<float>::to_degrees`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.to_degrees)
1542- [`<float>::to_radians`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.to_radians)
1543- [`<float>::max`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.max)
1544- [`<float>::min`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.min)
1545- [`<float>::clamp`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.clamp)
1546- [`<float>::abs`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.abs)
1547- [`<float>::signum`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.signum)
1548- [`<float>::copysign`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.copysign)
1549- [`MaybeUninit::write`](https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#method.write)
1550
1551<a id="1.85.0-Cargo"></a>
1552
1553Cargo
1554-----
1555- [Add future-incompatibility warning against keywords in cfgs and add raw-idents](https://github.com/rust-lang/cargo/pull/14671/)
1556- [Stabilize higher precedence trailing flags](https://github.com/rust-lang/cargo/pull/14900/)
1557- [Pass `CARGO_CFG_FEATURE` to build scripts](https://github.com/rust-lang/cargo/pull/14902/)
1558
1559<a id="1.85.0-Rustdoc"></a>
1560
1561Rustdoc
1562-----
1563- [Doc comment on impl blocks shows the first line, even when the impl block is collapsed](https://github.com/rust-lang/rust/pull/132155)
1564
1565<a id="1.85.0-Compatibility-Notes"></a>
1566
1567Compatibility Notes
1568-------------------
1569- [`rustc` no longer treats the `test` cfg as a well known check-cfg](https://github.com/rust-lang/rust/pull/131729), instead it is up to the build systems and users of `--check-cfg`[^check-cfg] to set it as a well known cfg using `--check-cfg=cfg(test)`.
1570
1571 This is done to enable build systems like Cargo to set it conditionally, as not all source files are suitable for unit tests.
1572 [Cargo (for now) unconditionally sets the `test` cfg as a well known cfg](https://github.com/rust-lang/cargo/pull/14963).
1573 [^check-cfg]: https://doc.rust-lang.org/nightly/rustc/check-cfg.html
1574- [Disable potentially incorrect type inference if there are trivial and non-trivial where-clauses](https://github.com/rust-lang/rust/pull/132325)
1575- `std::env::home_dir()` has been deprecated for years, because it can give surprising results in some Windows configurations if the `HOME` environment variable is set (which is not the normal configuration on Windows). We had previously avoided changing its behavior, out of concern for compatibility with code depending on this non-standard configuration. Given how long this function has been deprecated, we're now fixing its behavior as a bugfix. A subsequent release will remove the deprecation for this function.
1576- [Make `core::ffi::c_char` signedness more closely match that of the platform-default `char`](https://github.com/rust-lang/rust/pull/132975)
1577
1578 This changed `c_char` from an `i8` to `u8` or vice versa on many Tier 2 and 3
1579 targets (mostly Arm and RISC-V embedded targets). The new definition may
1580 result in compilation failures but fixes compatibility issues with C.
1581
1582 The `libc` crate matches this change as of its 0.2.169 release.
1583- [When compiling a nested `macro_rules` macro from an external crate, the content of the inner `macro_rules` is now built with the edition of the external crate, not the local crate.](https://github.com/rust-lang/rust/pull/133274)
1584- [Increase `sparcv9-sun-solaris` and `x86_64-pc-solaris` Solaris baseline to 11.4.](https://github.com/rust-lang/rust/pull/133293)
1585- [Show `abi_unsupported_vector_types` lint in future breakage reports](https://github.com/rust-lang/rust/pull/133374)
1586- [Error if multiple super-trait instantiations of `dyn Trait` need associated types to be specified but only one is provided](https://github.com/rust-lang/rust/pull/133392)
1587- [Change `powerpc64-ibm-aix` default `codemodel` to large](https://github.com/rust-lang/rust/pull/133811)
1588
1589<a id="1.85.0-Internal-Changes"></a>
1590
1591Internal Changes
1592----------------
1593
1594These changes do not affect any public interfaces of Rust, but they represent
1595significant improvements to the performance or internals of rustc and related
1596tools.
1597
1598- [Build `x86_64-unknown-linux-gnu` with LTO for C/C++ code (e.g., `jemalloc`)](https://github.com/rust-lang/rust/pull/134690)
1599
1600Version 1.84.1 (2025-01-30)
1601==========================
1602
1603<a id="1.84.1"></a>
1604
1605- [Fix ICE 132920 in duplicate-crate diagnostics.](https://github.com/rust-lang/rust/pull/133304/)
1606- [Fix errors for overlapping impls in incremental rebuilds.](https://github.com/rust-lang/rust/pull/133828/)
1607- [Fix slow compilation related to the next-generation trait solver.](https://github.com/rust-lang/rust/pull/135618/)
1608- [Fix debuginfo when LLVM's location discriminator value limit is exceeded.](https://github.com/rust-lang/rust/pull/135643/)
1609- Fixes for building Rust from source:
1610 - [Only try to distribute `llvm-objcopy` if llvm tools are enabled.](https://github.com/rust-lang/rust/pull/134240/)
1611 - [Add Profile Override for Non-Git Sources.](https://github.com/rust-lang/rust/pull/135433/)
1612 - [Resolve symlinks of LLVM tool binaries before copying them.](https://github.com/rust-lang/rust/pull/135585/)
1613 - [Make it possible to use ci-rustc on tarball sources.](https://github.com/rust-lang/rust/pull/135722/)
1614
1615Version 1.84.0 (2025-01-09)
1616==========================
1617
1618<a id="1.84.0-Language"></a>
1619
1620Language
1621--------
1622- [Allow `#[deny]` inside `#[forbid]` as a no-op](https://github.com/rust-lang/rust/pull/121560/)
1623- [Show a warning when `-Ctarget-feature` is used to toggle features that can lead to unsoundness due to ABI mismatches](https://github.com/rust-lang/rust/pull/129884)
1624- [Use the next-generation trait solver in coherence](https://github.com/rust-lang/rust/pull/130654)
1625- [Allow coercions to drop the principal of trait objects](https://github.com/rust-lang/rust/pull/131857)
1626- [Support `/` as the path separator for `include!()` in all cases on Windows](https://github.com/rust-lang/rust/pull/125205)
1627- [Taking a raw ref (`raw (const|mut)`) of a deref of a pointer (`*ptr`) is now safe](https://github.com/rust-lang/rust/pull/129248)
1628- [Stabilize s390x inline assembly](https://github.com/rust-lang/rust/pull/131258)
1629- [Stabilize Arm64EC inline assembly](https://github.com/rust-lang/rust/pull/131781)
1630- [Lint against creating pointers to immediately dropped temporaries](https://github.com/rust-lang/rust/pull/128985)
1631- [Execute drop glue when unwinding in an `extern "C"` function](https://github.com/rust-lang/rust/pull/129582)
1632
1633<a id="1.84.0-Compiler"></a>
1634
1635Compiler
1636--------
1637- [Add `--print host-tuple` flag to print the host target tuple and affirm the "target tuple" terminology over "target triple"](https://github.com/rust-lang/rust/pull/125579)
1638- [Declaring functions with a calling convention not supported on the current target now triggers a hard error](https://github.com/rust-lang/rust/pull/129935)
1639- [Set up indirect access to external data for `loongarch64-unknown-linux-{musl,ohos}`](https://github.com/rust-lang/rust/pull/131583)
1640- [Enable XRay instrumentation for LoongArch Linux targets](https://github.com/rust-lang/rust/pull/131818)
1641- [Extend the `unexpected_cfgs` lint to also warn in external macros](https://github.com/rust-lang/rust/pull/132577)
1642- [Stabilize WebAssembly `multivalue`, `reference-types`, and `tail-call` target features](https://github.com/rust-lang/rust/pull/131080)
1643- [Added Tier 2 support for the `wasm32v1-none` target](https://github.com/rust-lang/rust/pull/131487)
1644
1645<a id="1.84.0-Libraries"></a>
1646
1647Libraries
1648---------
1649- [Implement `From<&mut {slice}>` for `Box/Rc/Arc<{slice}>`](https://github.com/rust-lang/rust/pull/129329)
1650- [Move `<float>::copysign`, `<float>::abs`, `<float>::signum` to `core`](https://github.com/rust-lang/rust/pull/131304)
1651- [Add `LowerExp` and `UpperExp` implementations to `NonZero`](https://github.com/rust-lang/rust/pull/131377)
1652- [Implement `FromStr` for `CString` and `TryFrom<CString>` for `String`](https://github.com/rust-lang/rust/pull/130608)
1653- [`std::os::darwin` has been made public](https://github.com/rust-lang/rust/pull/123723)
1654
1655<a id="1.84.0-Stabilized-APIs"></a>
1656
1657Stabilized APIs
1658---------------
1659
1660- [`Ipv6Addr::is_unique_local`](https://doc.rust-lang.org/stable/core/net/struct.Ipv6Addr.html#method.is_unique_local)
1661- [`Ipv6Addr::is_unicast_link_local`](https://doc.rust-lang.org/stable/core/net/struct.Ipv6Addr.html#method.is_unicast_link_local)
1662- [`core::ptr::with_exposed_provenance`](https://doc.rust-lang.org/stable/core/ptr/fn.with_exposed_provenance.html)
1663- [`core::ptr::with_exposed_provenance_mut`](https://doc.rust-lang.org/stable/core/ptr/fn.with_exposed_provenance_mut.html)
1664- [`<ptr>::addr`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.addr)
1665- [`<ptr>::expose_provenance`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.expose_provenance)
1666- [`<ptr>::with_addr`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.with_addr)
1667- [`<ptr>::map_addr`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.map_addr)
1668- [`<int>::isqrt`](https://doc.rust-lang.org/stable/core/primitive.i32.html#method.isqrt)
1669- [`<int>::checked_isqrt`](https://doc.rust-lang.org/stable/core/primitive.i32.html#method.checked_isqrt)
1670- [`<uint>::isqrt`](https://doc.rust-lang.org/stable/core/primitive.u32.html#method.isqrt)
1671- [`NonZero::isqrt`](https://doc.rust-lang.org/stable/core/num/struct.NonZero.html#impl-NonZero%3Cu128%3E/method.isqrt)
1672- [`core::ptr::without_provenance`](https://doc.rust-lang.org/stable/core/ptr/fn.without_provenance.html)
1673- [`core::ptr::without_provenance_mut`](https://doc.rust-lang.org/stable/core/ptr/fn.without_provenance_mut.html)
1674- [`core::ptr::dangling`](https://doc.rust-lang.org/stable/core/ptr/fn.dangling.html)
1675- [`core::ptr::dangling_mut`](https://doc.rust-lang.org/stable/core/ptr/fn.dangling_mut.html)
1676- [`Pin::as_deref_mut`](https://doc.rust-lang.org/stable/core/pin/struct.Pin.html#method.as_deref_mut)
1677
1678These APIs are now stable in const contexts
1679
1680- [`AtomicBool::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicBool.html#method.from_ptr)
1681- [`AtomicPtr::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicPtr.html#method.from_ptr)
1682- [`AtomicU8::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicU8.html#method.from_ptr)
1683- [`AtomicU16::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicU16.html#method.from_ptr)
1684- [`AtomicU32::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicU32.html#method.from_ptr)
1685- [`AtomicU64::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicU64.html#method.from_ptr)
1686- [`AtomicUsize::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicUsize.html#method.from_ptr)
1687- [`AtomicI8::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicI8.html#method.from_ptr)
1688- [`AtomicI16::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicI16.html#method.from_ptr)
1689- [`AtomicI32::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicI32.html#method.from_ptr)
1690- [`AtomicI64::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicI64.html#method.from_ptr)
1691- [`AtomicIsize::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicIsize.html#method.from_ptr)
1692- [`<ptr>::is_null`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.is_null-1)
1693- [`<ptr>::as_ref`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.as_ref-1)
1694- [`<ptr>::as_mut`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.as_mut)
1695- [`Pin::new`](https://doc.rust-lang.org/stable/core/pin/struct.Pin.html#method.new)
1696- [`Pin::new_unchecked`](https://doc.rust-lang.org/stable/core/pin/struct.Pin.html#method.new_unchecked)
1697- [`Pin::get_ref`](https://doc.rust-lang.org/stable/core/pin/struct.Pin.html#method.get_ref)
1698- [`Pin::into_ref`](https://doc.rust-lang.org/stable/core/pin/struct.Pin.html#method.into_ref)
1699- [`Pin::get_mut`](https://doc.rust-lang.org/stable/core/pin/struct.Pin.html#method.get_mut)
1700- [`Pin::get_unchecked_mut`](https://doc.rust-lang.org/stable/core/pin/struct.Pin.html#method.get_unchecked_mut)
1701- [`Pin::static_ref`](https://doc.rust-lang.org/stable/core/pin/struct.Pin.html#method.static_ref)
1702- [`Pin::static_mut`](https://doc.rust-lang.org/stable/core/pin/struct.Pin.html#method.static_mut)
1703
1704<a id="1.84.0-Cargo"></a>
1705
1706Cargo
1707-----
1708- [Stabilize MSRV-aware resolver config](https://github.com/rust-lang/cargo/pull/14639/)
1709- [Stabilize resolver v3](https://github.com/rust-lang/cargo/pull/14754/)
1710
1711<a id="1.84-Rustdoc"></a>
1712
1713Rustdoc
1714-------
1715
1716- [rustdoc-search: improve type-driven search](https://github.com/rust-lang/rust/pull/127589)
1717
1718<a id="1.84.0-Compatibility-Notes"></a>
1719
1720Compatibility Notes
1721-------------------
1722- [Enable by default the `LSX` target feature for LoongArch Linux targets](https://github.com/rust-lang/rust/pull/132140)
1723- [The unstable `-Zprofile` flag (“gcov-style” coverage instrumentation) has been removed.](https://github.com/rust-lang/rust/pull/131829) This does not affect the stable flags for coverage instrumentation (`-Cinstrument-coverage`) and profile-guided optimization (`-Cprofile-generate`, `-Cprofile-use`), which are unrelated and remain available.
1724- Support for the target named `wasm32-wasi` has been removed as the target is now named `wasm32-wasip1`. This completes the [transition](https://github.com/rust-lang/compiler-team/issues/607) [plan](https://github.com/rust-lang/compiler-team/issues/695) for this target following [the introduction of `wasm32-wasip1`](https://github.com/rust-lang/rust/pull/120468) in Rust 1.78. Compiler warnings on [use of `wasm32-wasi`](https://github.com/rust-lang/rust/pull/126662) introduced in Rust 1.81 are now gone as well as the target is removed.
1725- [The syntax `&pin (mut|const) T` is now parsed as a type which in theory could affect macro expansion results in some edge cases](https://github.com/rust-lang/rust/pull/130635#issuecomment-2375462821)
1726- [Legacy syntax for calling `std::arch` functions is no longer permitted to declare items or bodies (such as closures, inline consts, or async blocks).](https://github.com/rust-lang/rust/pull/130443#issuecomment-2445678945)
1727- [Declaring functions with a calling convention not supported on the current target now triggers a hard error](https://github.com/rust-lang/rust/pull/129935)
1728- [The next-generation trait solver is now enabled for coherence, fixing multiple soundness issues](https://github.com/rust-lang/rust/pull/130654)
1729
1730Version 1.83.0 (2024-11-28)
1731==========================
1732
1733<a id="1.83.0-Language"></a>
1734
1735Language
1736--------
1737- [Stabilize `&mut`, `*mut`, `&Cell`, and `*const Cell` in const.](https://github.com/rust-lang/rust/pull/129195)
1738- [Allow creating references to statics in `const` initializers.](https://github.com/rust-lang/rust/pull/129759)
1739- [Implement raw lifetimes and labels (`'r#ident`).](https://github.com/rust-lang/rust/pull/126452)
1740- [Define behavior when atomic and non-atomic reads race.](https://github.com/rust-lang/rust/pull/128778)
1741- [Non-exhaustive structs may now be empty.](https://github.com/rust-lang/rust/pull/128934)
1742- [Disallow implicit coercions from places of type `!`](https://github.com/rust-lang/rust/pull/129392)
1743- [`const extern` functions can now be defined for other calling conventions.](https://github.com/rust-lang/rust/pull/129753)
1744- [Stabilize `expr_2021` macro fragment specifier in all editions.](https://github.com/rust-lang/rust/pull/129972)
1745- [The `non_local_definitions` lint now fires on less code and warns by default.](https://github.com/rust-lang/rust/pull/127117)
1746
1747
1748<a id="1.83.0-Compiler"></a>
1749
1750Compiler
1751--------
1752- [Deprecate unsound `-Csoft-float` flag.](https://github.com/rust-lang/rust/pull/129897)
1753- Add many new tier 3 targets:
1754 - [`aarch64_unknown_nto_qnx700`](https://github.com/rust-lang/rust/pull/127897)
1755 - [`arm64e-apple-tvos`](https://github.com/rust-lang/rust/pull/130614)
1756 - [`armv7-rtems-eabihf`](https://github.com/rust-lang/rust/pull/127021)
1757 - [`loongarch64-unknown-linux-ohos`](https://github.com/rust-lang/rust/pull/130750)
1758 - [`riscv32-wrs-vxworks` and `riscv64-wrs-vxworks`](https://github.com/rust-lang/rust/pull/130549)
1759 - [`riscv32{e|em|emc}-unknown-none-elf`](https://github.com/rust-lang/rust/pull/130555)
1760 - [`x86_64-unknown-hurd-gnu`](https://github.com/rust-lang/rust/pull/128345)
1761 - [`x86_64-unknown-trusty`](https://github.com/rust-lang/rust/pull/130453)
1762
1763Refer to Rust's [platform support page][platform-support-doc]
1764for more information on Rust's tiered platform support.
1765
1766
1767<a id="1.83.0-Libraries"></a>
1768
1769Libraries
1770---------
1771- [Implement `PartialEq` for `ExitCode`.](https://github.com/rust-lang/rust/pull/127633)
1772- [Document that `catch_unwind` can deal with foreign exceptions without UB, although the exact behavior is unspecified.](https://github.com/rust-lang/rust/pull/128321)
1773- [Implement `Default` for `HashMap`/`HashSet` iterators that don't already have it.](https://github.com/rust-lang/rust/pull/128711)
1774- [Bump Unicode to version 16.0.0.](https://github.com/rust-lang/rust/pull/130183)
1775- [Change documentation of `ptr::add`/`sub` to not claim equivalence with `offset`.](https://github.com/rust-lang/rust/pull/130229)
1776
1777
1778<a id="1.83.0-Stabilized-APIs"></a>
1779
1780Stabilized APIs
1781---------------
1782
1783- [`BufRead::skip_until`](https://doc.rust-lang.org/stable/std/io/trait.BufRead.html#method.skip_until)
1784- [`ControlFlow::break_value`](https://doc.rust-lang.org/stable/core/ops/enum.ControlFlow.html#method.break_value)
1785- [`ControlFlow::continue_value`](https://doc.rust-lang.org/stable/core/ops/enum.ControlFlow.html#method.continue_value)
1786- [`ControlFlow::map_break`](https://doc.rust-lang.org/stable/core/ops/enum.ControlFlow.html#method.map_break)
1787- [`ControlFlow::map_continue`](https://doc.rust-lang.org/stable/core/ops/enum.ControlFlow.html#method.map_continue)
1788- [`DebugList::finish_non_exhaustive`](https://doc.rust-lang.org/stable/core/fmt/struct.DebugList.html#method.finish_non_exhaustive)
1789- [`DebugMap::finish_non_exhaustive`](https://doc.rust-lang.org/stable/core/fmt/struct.DebugMap.html#method.finish_non_exhaustive)
1790- [`DebugSet::finish_non_exhaustive`](https://doc.rust-lang.org/stable/core/fmt/struct.DebugSet.html#method.finish_non_exhaustive)
1791- [`DebugTuple::finish_non_exhaustive`](https://doc.rust-lang.org/stable/core/fmt/struct.DebugTuple.html#method.finish_non_exhaustive)
1792- [`ErrorKind::ArgumentListTooLong`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.ArgumentListTooLong)
1793- [`ErrorKind::Deadlock`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.Deadlock)
1794- [`ErrorKind::DirectoryNotEmpty`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.DirectoryNotEmpty)
1795- [`ErrorKind::ExecutableFileBusy`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.ExecutableFileBusy)
1796- [`ErrorKind::FileTooLarge`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.FileTooLarge)
1797- [`ErrorKind::HostUnreachable`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.HostUnreachable)
1798- [`ErrorKind::IsADirectory`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.IsADirectory)
1799- [`ErrorKind::NetworkDown`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.NetworkDown)
1800- [`ErrorKind::NetworkUnreachable`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.NetworkUnreachable)
1801- [`ErrorKind::NotADirectory`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.NotADirectory)
1802- [`ErrorKind::NotSeekable`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.NotSeekable)
1803- [`ErrorKind::ReadOnlyFilesystem`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.ReadOnlyFilesystem)
1804- [`ErrorKind::ResourceBusy`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.ResourceBusy)
1805- [`ErrorKind::StaleNetworkFileHandle`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.StaleNetworkFileHandle)
1806- [`ErrorKind::StorageFull`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.StorageFull)
1807- [`ErrorKind::TooManyLinks`](https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#variant.TooManyLinks)
1808- [`Option::get_or_insert_default`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.get_or_insert_default)
1809- [`Waker::data`](https://doc.rust-lang.org/stable/core/task/struct.Waker.html#method.data)
1810- [`Waker::new`](https://doc.rust-lang.org/stable/core/task/struct.Waker.html#method.new)
1811- [`Waker::vtable`](https://doc.rust-lang.org/stable/core/task/struct.Waker.html#method.vtable)
1812- [`char::MIN`](https://doc.rust-lang.org/stable/core/primitive.char.html#associatedconstant.MIN)
1813- [`hash_map::Entry::insert_entry`](https://doc.rust-lang.org/stable/std/collections/hash_map/enum.Entry.html#method.insert_entry)
1814- [`hash_map::VacantEntry::insert_entry`](https://doc.rust-lang.org/stable/std/collections/hash_map/struct.VacantEntry.html#method.insert_entry)
1815
1816These APIs are now stable in const contexts:
1817
1818- [`Cell::into_inner`](https://doc.rust-lang.org/stable/core/cell/struct.Cell.html#method.into_inner)
1819- [`Duration::as_secs_f32`](https://doc.rust-lang.org/stable/core/time/struct.Duration.html#method.as_secs_f32)
1820- [`Duration::as_secs_f64`](https://doc.rust-lang.org/stable/core/time/struct.Duration.html#method.as_secs_f64)
1821- [`Duration::div_duration_f32`](https://doc.rust-lang.org/stable/core/time/struct.Duration.html#method.div_duration_f32)
1822- [`Duration::div_duration_f64`](https://doc.rust-lang.org/stable/core/time/struct.Duration.html#method.div_duration_f64)
1823- [`MaybeUninit::as_mut_ptr`](https://doc.rust-lang.org/stable/core/mem/union.MaybeUninit.html#method.as_mut_ptr)
1824- [`NonNull::as_mut`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.as_mut)
1825- [`NonNull::copy_from`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.copy_from)
1826- [`NonNull::copy_from_nonoverlapping`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.copy_from_nonoverlapping)
1827- [`NonNull::copy_to`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.copy_to)
1828- [`NonNull::copy_to_nonoverlapping`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.copy_to_nonoverlapping)
1829- [`NonNull::slice_from_raw_parts`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.slice_from_raw_parts)
1830- [`NonNull::write`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.write)
1831- [`NonNull::write_bytes`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.write_bytes)
1832- [`NonNull::write_unaligned`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.write_unaligned)
1833- [`OnceCell::into_inner`](https://doc.rust-lang.org/stable/core/cell/struct.OnceCell.html#method.into_inner)
1834- [`Option::as_mut`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.as_mut)
1835- [`Option::expect`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.expect)
1836- [`Option::replace`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.replace)
1837- [`Option::take`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.take)
1838- [`Option::unwrap`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.unwrap)
1839- [`Option::unwrap_unchecked`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.unwrap_unchecked)
1840- [`Option::<&_>::copied`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.copied)
1841- [`Option::<&mut _>::copied`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.copied-1)
1842- [`Option::<Option<_>>::flatten`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.flatten)
1843- [`Option::<Result<_, _>>::transpose`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.transpose)
1844- [`RefCell::into_inner`](https://doc.rust-lang.org/stable/core/cell/struct.RefCell.html#method.into_inner)
1845- [`Result::as_mut`](https://doc.rust-lang.org/stable/core/result/enum.Result.html#method.as_mut)
1846- [`Result::<&_, _>::copied`](https://doc.rust-lang.org/stable/core/result/enum.Result.html#method.copied)
1847- [`Result::<&mut _, _>::copied`](https://doc.rust-lang.org/stable/core/result/enum.Result.html#method.copied-1)
1848- [`Result::<Option<_>, _>::transpose`](https://doc.rust-lang.org/stable/core/result/enum.Result.html#method.transpose)
1849- [`UnsafeCell::get_mut`](https://doc.rust-lang.org/stable/core/cell/struct.UnsafeCell.html#method.get_mut)
1850- [`UnsafeCell::into_inner`](https://doc.rust-lang.org/stable/core/cell/struct.UnsafeCell.html#method.into_inner)
1851- [`array::from_mut`](https://doc.rust-lang.org/stable/core/array/fn.from_mut.html)
1852- [`char::encode_utf8`](https://doc.rust-lang.org/stable/core/primitive.char.html#method.encode_utf8)
1853- [`{float}::classify`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.classify)
1854- [`{float}::is_finite`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.is_finite)
1855- [`{float}::is_infinite`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.is_infinite)
1856- [`{float}::is_nan`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.is_nan)
1857- [`{float}::is_normal`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.is_normal)
1858- [`{float}::is_sign_negative`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.is_sign_negative)
1859- [`{float}::is_sign_positive`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.is_sign_positive)
1860- [`{float}::is_subnormal`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.is_subnormal)
1861- [`{float}::from_bits`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.from_bits)
1862- [`{float}::from_be_bytes`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.from_be_bytes)
1863- [`{float}::from_le_bytes`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.from_le_bytes)
1864- [`{float}::from_ne_bytes`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.from_ne_bytes)
1865- [`{float}::to_bits`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.to_bits)
1866- [`{float}::to_be_bytes`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.to_be_bytes)
1867- [`{float}::to_le_bytes`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.to_le_bytes)
1868- [`{float}::to_ne_bytes`](https://doc.rust-lang.org/stable/core/primitive.f64.html#method.to_ne_bytes)
1869- [`mem::replace`](https://doc.rust-lang.org/stable/core/mem/fn.replace.html)
1870- [`ptr::replace`](https://doc.rust-lang.org/stable/core/ptr/fn.replace.html)
1871- [`ptr::slice_from_raw_parts_mut`](https://doc.rust-lang.org/stable/core/ptr/fn.slice_from_raw_parts_mut.html)
1872- [`ptr::write`](https://doc.rust-lang.org/stable/core/ptr/fn.write.html)
1873- [`ptr::write_unaligned`](https://doc.rust-lang.org/stable/core/ptr/fn.write_unaligned.html)
1874- [`<*const _>::copy_to`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.copy_to)
1875- [`<*const _>::copy_to_nonoverlapping`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.copy_to_nonoverlapping)
1876- [`<*mut _>::copy_from`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.copy_from)
1877- [`<*mut _>::copy_from_nonoverlapping`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.copy_from_nonoverlapping)
1878- [`<*mut _>::copy_to`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.copy_to-1)
1879- [`<*mut _>::copy_to_nonoverlapping`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.copy_to_nonoverlapping-1)
1880- [`<*mut _>::write`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.write)
1881- [`<*mut _>::write_bytes`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.write_bytes)
1882- [`<*mut _>::write_unaligned`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.write_unaligned)
1883- [`slice::from_mut`](https://doc.rust-lang.org/stable/core/slice/fn.from_mut.html)
1884- [`slice::from_raw_parts_mut`](https://doc.rust-lang.org/stable/core/slice/fn.from_raw_parts_mut.html)
1885- [`<[_]>::first_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.first_mut)
1886- [`<[_]>::last_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.last_mut)
1887- [`<[_]>::first_chunk_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.first_chunk_mut)
1888- [`<[_]>::last_chunk_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.last_chunk_mut)
1889- [`<[_]>::split_at_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.split_at_mut)
1890- [`<[_]>::split_at_mut_checked`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.split_at_mut_checked)
1891- [`<[_]>::split_at_mut_unchecked`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.split_at_mut_unchecked)
1892- [`<[_]>::split_first_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.split_first_mut)
1893- [`<[_]>::split_last_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.split_last_mut)
1894- [`<[_]>::split_first_chunk_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.split_first_chunk_mut)
1895- [`<[_]>::split_last_chunk_mut`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.split_last_chunk_mut)
1896- [`str::as_bytes_mut`](https://doc.rust-lang.org/stable/core/primitive.str.html#method.as_bytes_mut)
1897- [`str::as_mut_ptr`](https://doc.rust-lang.org/stable/core/primitive.str.html#method.as_mut_ptr)
1898- [`str::from_utf8_unchecked_mut`](https://doc.rust-lang.org/stable/core/str/fn.from_utf8_unchecked_mut.html)
1899
1900
1901<a id="1.83.0-Cargo"></a>
1902
1903Cargo
1904-----
1905- [Introduced a new `CARGO_MANIFEST_PATH` environment variable, similar to `CARGO_MANIFEST_DIR` but pointing directly to the manifest file.](https://github.com/rust-lang/cargo/pull/14404/)
1906- [Added `package.autolib` to the manifest, allowing `[lib]` auto-discovery to be disabled.](https://github.com/rust-lang/cargo/pull/14591/)
1907- [Declare support level for each crate in Cargo's Charter / crate docs.](https://github.com/rust-lang/cargo/pull/14600/)
1908- [Declare new Intentional Artifacts as 'small' changes.](https://github.com/rust-lang/cargo/pull/14599/)
1909
1910
1911<a id="1.83-Rustdoc"></a>
1912
1913Rustdoc
1914-------
1915
1916- [The sidebar / hamburger menu table of contents now includes the `# headers` from the main item's doc comment](https://github.com/rust-lang/rust/pull/120736). This is similar to a third-party feature provided by the rustdoc-search-enhancements browser extension.
1917
1918
1919<a id="1.83.0-Compatibility-Notes"></a>
1920
1921Compatibility Notes
1922-------------------
1923- [Warn against function pointers using unsupported ABI strings.](https://github.com/rust-lang/rust/pull/128784)
1924- [Check well-formedness of the source type's signature in fn pointer casts.](https://github.com/rust-lang/rust/pull/129021) This partly closes a soundness hole that comes when casting a function item to function pointer
1925- [Use equality instead of subtyping when resolving type dependent paths.](https://github.com/rust-lang/rust/pull/129073)
1926- Linking on macOS now correctly includes Rust's default deployment target. Due to a linker bug, you might have to pass `MACOSX_DEPLOYMENT_TARGET` or fix your `#[link]` attributes to point to the correct frameworks. See <https://github.com/rust-lang/rust/pull/129369>.
1927- [Rust will now correctly raise an error for `repr(Rust)` written on non-`struct`/`enum`/`union` items, since it previously did not have any effect.](https://github.com/rust-lang/rust/pull/129422)
1928- The future incompatibility lint `deprecated_cfg_attr_crate_type_name` [has been made into a hard error](https://github.com/rust-lang/rust/pull/129670). It was used to deny usage of `#![crate_type]` and `#![crate_name]` attributes in `#![cfg_attr]`, which required a hack in the compiler to be able to change the used crate type and crate name after cfg expansion.
1929 Users can use `--crate-type` instead of `#![cfg_attr(..., crate_type = "...")]` and `--crate-name` instead of `#![cfg_attr(..., crate_name = "...")]` when running `rustc`/`cargo rustc` on the command line.
1930 Use of those two attributes outside of `#![cfg_attr]` continue to be fully supported.
1931- Until now, paths into the sysroot were always prefixed with `/rustc/$hash` in diagnostics, codegen, backtrace, e.g.
1932 ```
1933 thread 'main' panicked at 'hello world', map-panic.rs:2:50
1934 stack backtrace:
1935 0: std::panicking::begin_panic
1936 at /rustc/a55dd71d5fb0ec5a6a3a9e8c27b2127ba491ce52/library/std/src/panicking.rs:616:12
1937 1: map_panic::main::{{closure}}
1938 at ./map-panic.rs:2:50
1939 2: core::option::Option<T>::map
1940 at /rustc/a55dd71d5fb0ec5a6a3a9e8c27b2127ba491ce52/library/core/src/option.rs:929:29
1941 3: map_panic::main
1942 at ./map-panic.rs:2:30
1943 4: core::ops::function::FnOnce::call_once
1944 at /rustc/a55dd71d5fb0ec5a6a3a9e8c27b2127ba491ce52/library/core/src/ops/function.rs:248:5
1945 note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
1946 ```
1947 [RFC 3127 said](https://rust-lang.github.io/rfcs/3127-trim-paths.html#changing-handling-of-sysroot-path-in-rustc)
1948 > We want to change this behaviour such that, when `rust-src` source files can be discovered, the virtual path is discarded and therefore the local path will be embedded, unless there is a `--remap-path-prefix` that causes this local path to be remapped in the usual way.
1949
1950 [#129687](https://github.com/rust-lang/rust/pull/129687) implements this behaviour, when `rust-src` is present at compile time, `rustc` replaces `/rustc/$hash` with a real path into the local `rust-src` component with best effort.
1951 To sanitize this, users must explicitly supply `--remap-path-prefix=<path to rust-src>=foo` or not have the `rust-src` component installed.
1952 - The allow-by-default `missing_docs` lint used to disable itself when invoked through `rustc --test`/`cargo test`, resulting in `#[expect(missing_docs)]` emitting false positives due to the expectation being wrongly unfulfilled. This behavior [has now been removed](https://github.com/rust-lang/rust/pull/130025), which allows `#[expect(missing_docs)]` to be fulfilled in all scenarios, but will also report new `missing_docs` diagnostics for publicly reachable `#[cfg(test)]` items, [integration test](https://doc.rust-lang.org/cargo/reference/cargo-targets.html#integration-tests) crate-level documentation, and publicly reachable items in integration tests.
1953- [The `armv8r-none-eabihf` target now uses the Armv8-R required set of floating-point features.](https://github.com/rust-lang/rust/pull/130295)
1954- [Fix a soundness bug where rustc wouldn't detect unconstrained higher-ranked lifetimes in a `dyn Trait`'s associated types that occur due to supertraits.](https://github.com/rust-lang/rust/pull/130367)
1955- [Update the minimum external LLVM version to 18.](https://github.com/rust-lang/rust/pull/130487)
1956- [Remove `aarch64-fuchsia` and `x86_64-fuchsia` target aliases in favor of `aarch64-unknown-fuchsia` and `x86_64-unknown-fuchsia` respectively.](https://github.com/rust-lang/rust/pull/130657)
1957- [The ABI-level exception class of a Rust panic is now encoded with native-endian bytes, so it is legible in hex dumps.](https://github.com/rust-lang/rust/pull/130897)
1958- [Visual Studio 2013 is no longer supported for MSVC targets.](https://github.com/rust-lang/rust/pull/131070)
1959- [The sysroot no longer contains the `std` dynamic library in its top-level `lib/` dir.](https://github.com/rust-lang/rust/pull/131188)
1960
1961
1962Version 1.82.0 (2024-10-17)
1963==========================
1964
1965<a id="1.82.0-Language"></a>
1966
1967Language
1968--------
1969- [Don't make statement nonterminals match pattern nonterminals](https://github.com/rust-lang/rust/pull/120221/)
1970- [Patterns matching empty types can now be omitted in common cases](https://github.com/rust-lang/rust/pull/122792)
1971- [Enforce supertrait outlives obligations when using trait impls](https://github.com/rust-lang/rust/pull/124336)
1972- [`addr_of(_mut)!` macros and the newly stabilized `&raw (const|mut)` are now safe to use with all static items](https://github.com/rust-lang/rust/pull/125834)
1973- [size_of_val_raw: for length 0 this is safe to call](https://github.com/rust-lang/rust/pull/126152/)
1974- [Reorder trait bound modifiers *after* `for<...>` binder in trait bounds](https://github.com/rust-lang/rust/pull/127054/)
1975- [Stabilize `+ use<'lt>` opaque type precise capturing (RFC 3617)](https://github.com/rust-lang/rust/pull/127672)
1976- [Stabilize `&raw const` and `&raw mut` operators (RFC 2582)](https://github.com/rust-lang/rust/pull/127679)
1977- [Stabilize unsafe extern blocks (RFC 3484)](https://github.com/rust-lang/rust/pull/127921)
1978- [Stabilize nested field access in `offset_of!`](https://github.com/rust-lang/rust/pull/128284)
1979- [Do not require `T` to be live when dropping `[T; 0]`](https://github.com/rust-lang/rust/pull/128438)
1980- [Stabilize `const` operands in inline assembly](https://github.com/rust-lang/rust/pull/128570)
1981- [Stabilize floating-point arithmetic in `const fn`](https://github.com/rust-lang/rust/pull/128596)
1982- [Stabilize explicit opt-in to unsafe attributes](https://github.com/rust-lang/rust/pull/128771)
1983- [Document NaN bit patterns guarantees](https://github.com/rust-lang/rust/pull/129559)
1984
1985
1986<a id="1.82.0-Compiler"></a>
1987
1988Compiler
1989--------
1990- [Promote riscv64gc-unknown-linux-musl to tier 2](https://github.com/rust-lang/rust/pull/122049)
1991- [Promote Mac Catalyst targets `aarch64-apple-ios-macabi` and `x86_64-apple-ios-macabi` to Tier 2, and ship them with rustup](https://github.com/rust-lang/rust/pull/126450)
1992- [Add tier 3 NuttX based targets for RISC-V and ARM](https://github.com/rust-lang/rust/pull/127755)
1993- [Add tier 3 powerpc-unknown-linux-muslspe target](https://github.com/rust-lang/rust/pull/127905)
1994- [Improved diagnostics to explain why a pattern is unreachable](https://github.com/rust-lang/rust/pull/128034)
1995- [The compiler now triggers the unreachable code warning properly for async functions that don't return/are `-> !`](https://github.com/rust-lang/rust/pull/128443)
1996- [Promote `aarch64-apple-darwin` to Tier 1](https://github.com/rust-lang/rust/pull/128592)
1997- [Add Trusty OS target `aarch64-unknown-trusty` and `armv7-unknown-trusty` as tier 3 targets](https://github.com/rust-lang/rust/pull/129490)
1998- [Promote `wasm32-wasip2` to Tier 2.](https://github.com/rust-lang/rust/pull/126967/)
1999
2000
2001<a id="1.82.0-Libraries"></a>
2002
2003Libraries
2004---------
2005- [Generalize `{Rc,Arc}::make_mut()` to `Path`, `OsStr`, and `CStr`.](https://github.com/rust-lang/rust/pull/126877)
2006
2007<a id="1.82.0-Stabilized-APIs"></a>
2008
2009Stabilized APIs
2010---------------
2011
2012- [`std::thread::Builder::spawn_unchecked`](https://doc.rust-lang.org/stable/std/thread/struct.Builder.html#method.spawn_unchecked)
2013- [`std::str::CharIndices::offset`](https://doc.rust-lang.org/nightly/std/str/struct.CharIndices.html#method.offset)
2014- [`std::option::Option::is_none_or`](https://doc.rust-lang.org/nightly/std/option/enum.Option.html#method.is_none_or)
2015- [`[T]::is_sorted`](https://doc.rust-lang.org/nightly/std/primitive.slice.html#method.is_sorted)
2016- [`[T]::is_sorted_by`](https://doc.rust-lang.org/nightly/std/primitive.slice.html#method.is_sorted_by)
2017- [`[T]::is_sorted_by_key`](https://doc.rust-lang.org/nightly/std/primitive.slice.html#method.is_sorted_by_key)
2018- [`Iterator::is_sorted`](https://doc.rust-lang.org/nightly/std/iter/trait.Iterator.html#method.is_sorted)
2019- [`Iterator::is_sorted_by`](https://doc.rust-lang.org/nightly/std/iter/trait.Iterator.html#method.is_sorted_by)
2020- [`Iterator::is_sorted_by_key`](https://doc.rust-lang.org/nightly/std/iter/trait.Iterator.html#method.is_sorted_by_key)
2021- [`std::future::Ready::into_inner`](https://doc.rust-lang.org/nightly/std/future/struct.Ready.html#method.into_inner)
2022- [`std::iter::repeat_n`](https://doc.rust-lang.org/nightly/std/iter/fn.repeat_n.html)
2023- [`impl<T: Clone> DoubleEndedIterator for Take<Repeat<T>>`](https://doc.rust-lang.org/nightly/std/iter/struct.Take.html#impl-DoubleEndedIterator-for-Take%3CRepeat%3CT%3E%3E)
2024- [`impl<T: Clone> ExactSizeIterator for Take<Repeat<T>>`](https://doc.rust-lang.org/nightly/std/iter/struct.Take.html#impl-ExactSizeIterator-for-Take%3CRepeat%3CT%3E%3E)
2025- [`impl<T: Clone> ExactSizeIterator for Take<RepeatWith<T>>`](https://doc.rust-lang.org/nightly/std/iter/struct.Take.html#impl-ExactSizeIterator-for-Take%3CRepeatWith%3CF%3E%3E)
2026- [`impl Default for std::collections::binary_heap::Iter`](https://doc.rust-lang.org/nightly/std/collections/binary_heap/struct.Iter.html#impl-Default-for-Iter%3C'_,+T%3E)
2027- [`impl Default for std::collections::btree_map::RangeMut`](https://doc.rust-lang.org/nightly/std/collections/btree_map/struct.RangeMut.html#impl-Default-for-RangeMut%3C'_,+K,+V%3E)
2028- [`impl Default for std::collections::btree_map::ValuesMut`](https://doc.rust-lang.org/nightly/std/collections/btree_map/struct.ValuesMut.html#impl-Default-for-ValuesMut%3C'_,+K,+V%3E)
2029- [`impl Default for std::collections::vec_deque::Iter`](https://doc.rust-lang.org/nightly/std/collections/vec_deque/struct.Iter.html#impl-Default-for-Iter%3C'_,+T%3E)
2030- [`impl Default for std::collections::vec_deque::IterMut`](https://doc.rust-lang.org/nightly/std/collections/vec_deque/struct.IterMut.html#impl-Default-for-IterMut%3C'_,+T%3E)
2031- [`Rc<T>::new_uninit`](https://doc.rust-lang.org/nightly/std/rc/struct.Rc.html#method.new_uninit)
2032- [`Rc<MaybeUninit<T>>::assume_init`](https://doc.rust-lang.org/nightly/std/rc/struct.Rc.html#method.assume_init)
2033- [`Rc<[T]>::new_uninit_slice`](https://doc.rust-lang.org/nightly/std/rc/struct.Rc.html#method.new_uninit_slice)
2034- [`Rc<[MaybeUninit<T>]>::assume_init`](https://doc.rust-lang.org/nightly/std/rc/struct.Rc.html#method.assume_init-1)
2035- [`Arc<T>::new_uninit`](https://doc.rust-lang.org/nightly/std/sync/struct.Arc.html#method.new_uninit)
2036- [`Arc<MaybeUninit<T>>::assume_init`](https://doc.rust-lang.org/nightly/std/sync/struct.Arc.html#method.assume_init)
2037- [`Arc<[T]>::new_uninit_slice`](https://doc.rust-lang.org/nightly/std/sync/struct.Arc.html#method.new_uninit_slice)
2038- [`Arc<[MaybeUninit<T>]>::assume_init`](https://doc.rust-lang.org/nightly/std/sync/struct.Arc.html#method.assume_init-1)
2039- [`Box<T>::new_uninit`](https://doc.rust-lang.org/nightly/std/boxed/struct.Box.html#method.new_uninit)
2040- [`Box<MaybeUninit<T>>::assume_init`](https://doc.rust-lang.org/nightly/std/boxed/struct.Box.html#method.assume_init)
2041- [`Box<[T]>::new_uninit_slice`](https://doc.rust-lang.org/nightly/std/boxed/struct.Box.html#method.new_uninit_slice)
2042- [`Box<[MaybeUninit<T>]>::assume_init`](https://doc.rust-lang.org/nightly/std/boxed/struct.Box.html#method.assume_init-1)
2043- [`core::arch::x86_64::_bextri_u64`](https://doc.rust-lang.org/stable/core/arch/x86_64/fn._bextri_u64.html)
2044- [`core::arch::x86_64::_bextri_u32`](https://doc.rust-lang.org/stable/core/arch/x86_64/fn._bextri_u32.html)
2045- [`core::arch::x86::_mm_broadcastsi128_si256`](https://doc.rust-lang.org/stable/core/arch/x86/fn._mm_broadcastsi128_si256.html)
2046- [`core::arch::x86::_mm256_stream_load_si256`](https://doc.rust-lang.org/stable/core/arch/x86/fn._mm256_stream_load_si256.html)
2047- [`core::arch::x86::_tzcnt_u16`](https://doc.rust-lang.org/stable/core/arch/x86/fn._tzcnt_u16.html)
2048- [`core::arch::x86::_mm_extracti_si64`](https://doc.rust-lang.org/stable/core/arch/x86/fn._mm_extracti_si64.html)
2049- [`core::arch::x86::_mm_inserti_si64`](https://doc.rust-lang.org/stable/core/arch/x86/fn._mm_inserti_si64.html)
2050- [`core::arch::x86::_mm_storeu_si16`](https://doc.rust-lang.org/stable/core/arch/x86/fn._mm_storeu_si16.html)
2051- [`core::arch::x86::_mm_storeu_si32`](https://doc.rust-lang.org/stable/core/arch/x86/fn._mm_storeu_si32.html)
2052- [`core::arch::x86::_mm_storeu_si64`](https://doc.rust-lang.org/stable/core/arch/x86/fn._mm_storeu_si64.html)
2053- [`core::arch::x86::_mm_loadu_si16`](https://doc.rust-lang.org/stable/core/arch/x86/fn._mm_loadu_si16.html)
2054- [`core::arch::x86::_mm_loadu_si32`](https://doc.rust-lang.org/stable/core/arch/x86/fn._mm_loadu_si32.html)
2055- [`core::arch::wasm32::u8x16_relaxed_swizzle`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u8x16_relaxed_swizzle.html)
2056- [`core::arch::wasm32::i8x16_relaxed_swizzle`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i8x16_relaxed_swizzle.html)
2057- [`core::arch::wasm32::i32x4_relaxed_trunc_f32x4`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i32x4_relaxed_trunc_f32x4.html)
2058- [`core::arch::wasm32::u32x4_relaxed_trunc_f32x4`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u32x4_relaxed_trunc_f32x4.html)
2059- [`core::arch::wasm32::i32x4_relaxed_trunc_f64x2_zero`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i32x4_relaxed_trunc_f64x2_zero.html)
2060- [`core::arch::wasm32::u32x4_relaxed_trunc_f64x2_zero`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u32x4_relaxed_trunc_f64x2_zero.html)
2061- [`core::arch::wasm32::f32x4_relaxed_madd`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.f32x4_relaxed_madd.html)
2062- [`core::arch::wasm32::f32x4_relaxed_nmadd`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.f32x4_relaxed_nmadd.html)
2063- [`core::arch::wasm32::f64x2_relaxed_madd`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.f64x2_relaxed_madd.html)
2064- [`core::arch::wasm32::f64x2_relaxed_nmadd`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.f64x2_relaxed_nmadd.html)
2065- [`core::arch::wasm32::i8x16_relaxed_laneselect`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i8x16_relaxed_laneselect.html)
2066- [`core::arch::wasm32::u8x16_relaxed_laneselect`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u8x16_relaxed_laneselect.html)
2067- [`core::arch::wasm32::i16x8_relaxed_laneselect`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i16x8_relaxed_laneselect.html)
2068- [`core::arch::wasm32::u16x8_relaxed_laneselect`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u16x8_relaxed_laneselect.html)
2069- [`core::arch::wasm32::i32x4_relaxed_laneselect`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i32x4_relaxed_laneselect.html)
2070- [`core::arch::wasm32::u32x4_relaxed_laneselect`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u32x4_relaxed_laneselect.html)
2071- [`core::arch::wasm32::i64x2_relaxed_laneselect`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i64x2_relaxed_laneselect.html)
2072- [`core::arch::wasm32::u64x2_relaxed_laneselect`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u64x2_relaxed_laneselect.html)
2073- [`core::arch::wasm32::f32x4_relaxed_min`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.f32x4_relaxed_min.html)
2074- [`core::arch::wasm32::f32x4_relaxed_max`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.f32x4_relaxed_max.html)
2075- [`core::arch::wasm32::f64x2_relaxed_min`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.f64x2_relaxed_min.html)
2076- [`core::arch::wasm32::f64x2_relaxed_max`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.f64x2_relaxed_max.html)
2077- [`core::arch::wasm32::i16x8_relaxed_q15mulr`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i16x8_relaxed_q15mulr.html)
2078- [`core::arch::wasm32::u16x8_relaxed_q15mulr`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u16x8_relaxed_q15mulr.html)
2079- [`core::arch::wasm32::i16x8_relaxed_dot_i8x16_i7x16`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i16x8_relaxed_dot_i8x16_i7x16.html)
2080- [`core::arch::wasm32::u16x8_relaxed_dot_i8x16_i7x16`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u16x8_relaxed_dot_i8x16_i7x16.html)
2081- [`core::arch::wasm32::i32x4_relaxed_dot_i8x16_i7x16_add`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.i32x4_relaxed_dot_i8x16_i7x16_add.html)
2082- [`core::arch::wasm32::u32x4_relaxed_dot_i8x16_i7x16_add`](https://doc.rust-lang.org/nightly/core/arch/wasm32/fn.u32x4_relaxed_dot_i8x16_i7x16_add.html)
2083
2084These APIs are now stable in const contexts:
2085
2086- [`std::task::Waker::from_raw`](https://doc.rust-lang.org/nightly/std/task/struct.Waker.html#method.from_raw)
2087- [`std::task::Context::from_waker`](https://doc.rust-lang.org/nightly/std/task/struct.Context.html#method.from_waker)
2088- [`std::task::Context::waker`](https://doc.rust-lang.org/nightly/std/task/struct.Context.html#method.waker)
2089- [`{integer}::from_str_radix`](https://doc.rust-lang.org/nightly/std/primitive.u32.html#method.from_str_radix)
2090- [`std::num::ParseIntError::kind`](https://doc.rust-lang.org/nightly/std/num/struct.ParseIntError.html#method.kind)
2091
2092<a id="1.82.0-Cargo"></a>
2093
2094Cargo
2095-----
2096- [feat: Add `info` cargo subcommand](https://github.com/rust-lang/cargo/pull/14141/)
2097
2098<a id="1.82.0-Compatibility-Notes"></a>
2099
2100Compatibility Notes
2101-------------------
2102 - We now [disallow setting some built-in cfgs via the command-line](https://github.com/rust-lang/rust/pull/126158) with the newly added [`explicit_builtin_cfgs_in_flags`](https://doc.rust-lang.org/rustc/lints/listing/deny-by-default.html#explicit-builtin-cfgs-in-flags) lint in order to prevent incoherent state, eg. `windows` cfg active but target is Linux based. The appropriate [`rustc` flag](https://doc.rust-lang.org/rustc/command-line-arguments.html) should be used instead.
2103- The standard library has a new implementation of `binary_search` which significantly improves performance ([#128254](https://github.com/rust-lang/rust/pull/128254)). However when a sorted slice has multiple values which compare equal, the new implementation may select a different value among the equal ones than the old implementation.
2104- [illumos/Solaris now sets `MSG_NOSIGNAL` when writing to sockets](https://github.com/rust-lang/rust/pull/128259). This avoids killing the process with SIGPIPE when writing to a closed socket, which matches the existing behavior on other UNIX targets.
2105- [Removes a problematic hack that always passed the --whole-archive linker flag for tests, which may cause linker errors for code accidentally relying on it.](https://github.com/rust-lang/rust/pull/128400)
2106- The WebAssembly target features `multivalue` and `reference-types` are now
2107 both enabled by default. These two features both have subtle changes implied
2108 for generated WebAssembly binaries. For the `multivalue` feature, WebAssembly
2109 target support has changed when upgrading to LLVM 19. Support for generating
2110 functions with multiple returns no longer works and
2111 `-Ctarget-feature=+multivalue` has a different meaning than it did in LLVM 18
2112 and prior. There is no longer any supported means to generate a module that has
2113 a function with multiple returns in WebAssembly from Rust source code. For the
2114 `reference-types` feature the encoding of immediates in the `call_indirect`, a
2115 commonly used instruction by the WebAssembly backend, has changed. Validators
2116 and parsers which don't understand the `reference-types` proposal will no
2117 longer accept modules produced by LLVM due to this change in encoding of
2118 immediates. Additionally these features being enabled are encoded in the
2119 `target_features` custom section and may affect downstream tooling such as
2120 `wasm-opt` consuming the module. Generating a WebAssembly module that disables
2121 default features requires `-Zbuild-std` support from Cargo and more information
2122 can be found at
2123 [rust-lang/rust#128511](https://github.com/rust-lang/rust/pull/128511).
2124- [Rust now raises unsafety errors for union patterns in parameter-position](https://github.com/rust-lang/rust/pull/130531)
2125
2126
2127<a id="1.82.0-Internal-Changes"></a>
2128
2129Internal Changes
2130----------------
2131
2132These changes do not affect any public interfaces of Rust, but they represent
2133significant improvements to the performance or internals of rustc and related
2134tools.
2135
2136- [Update to LLVM 19](https://github.com/rust-lang/rust/pull/127513)
2137
2138Version 1.81.0 (2024-09-05)
2139==========================
2140
2141<a id="1.81.0-Language"></a>
2142
2143Language
2144--------
2145
2146- [Abort on uncaught panics in `extern "C"` functions.](https://github.com/rust-lang/rust/pull/116088/)
2147- [Fix ambiguous cases of multiple `&` in elided self lifetimes.](https://github.com/rust-lang/rust/pull/117967/)
2148- [Stabilize `#[expect]` for lints (RFC 2383),](https://github.com/rust-lang/rust/pull/120924/) like `#[allow]` with a warning if the lint is _not_ fulfilled.
2149- [Change method resolution to constrain hidden types instead of rejecting method candidates.](https://github.com/rust-lang/rust/pull/123962/)
2150- [Bump `elided_lifetimes_in_associated_constant` to deny.](https://github.com/rust-lang/rust/pull/124211/)
2151- [`offset_from`: always allow pointers to point to the same address.](https://github.com/rust-lang/rust/pull/124921/)
2152- [Allow constraining opaque types during subtyping in the trait system.](https://github.com/rust-lang/rust/pull/125447/)
2153- [Allow constraining opaque types during various unsizing casts.](https://github.com/rust-lang/rust/pull/125610/)
2154- [Deny keyword lifetimes pre-expansion.](https://github.com/rust-lang/rust/pull/126762/)
2155
2156<a id="1.81.0-Compiler"></a>
2157
2158Compiler
2159--------
2160
2161- [Make casts of pointers to trait objects stricter.](https://github.com/rust-lang/rust/pull/120248/)
2162- [Check alias args for well-formedness even if they have escaping bound vars.](https://github.com/rust-lang/rust/pull/123737/)
2163- [Deprecate no-op codegen option `-Cinline-threshold=...`.](https://github.com/rust-lang/rust/pull/124712/)
2164- [Re-implement a type-size based limit.](https://github.com/rust-lang/rust/pull/125507/)
2165- [Properly account for alignment in `transmute` size checks.](https://github.com/rust-lang/rust/pull/125740/)
2166- [Remove the `box_pointers` lint.](https://github.com/rust-lang/rust/pull/126018/)
2167- [Ensure the interpreter checks bool/char for validity when they are used in a cast.](https://github.com/rust-lang/rust/pull/126265/)
2168- [Improve coverage instrumentation for functions containing nested items.](https://github.com/rust-lang/rust/pull/127199/)
2169- Target changes:
2170 - [Add Tier 3 `no_std` Xtensa targets:](https://github.com/rust-lang/rust/pull/125141/) `xtensa-esp32-none-elf`, `xtensa-esp32s2-none-elf`, `xtensa-esp32s3-none-elf`
2171 - [Add Tier 3 `std` Xtensa targets:](https://github.com/rust-lang/rust/pull/126380/) `xtensa-esp32-espidf`, `xtensa-esp32s2-espidf`, `xtensa-esp32s3-espidf`
2172 - [Add Tier 3 i686 Redox OS target:](https://github.com/rust-lang/rust/pull/126192/) `i686-unknown-redox`
2173 - [Promote `arm64ec-pc-windows-msvc` to Tier 2.](https://github.com/rust-lang/rust/pull/126039/)
2174 - [Promote `loongarch64-unknown-linux-musl` to Tier 2 with host tools.](https://github.com/rust-lang/rust/pull/126298/)
2175 - [Enable full tools and profiler for LoongArch Linux targets.](https://github.com/rust-lang/rust/pull/127078/)
2176 - [Unconditionally warn on usage of `wasm32-wasi`.](https://github.com/rust-lang/rust/pull/126662/) (see compatibility note below)
2177 - Refer to Rust's [platform support page][platform-support-doc] for more information on Rust's tiered platform support.
2178
2179<a id="1.81.0-Libraries"></a>
2180
2181Libraries
2182---------
2183
2184- [Split core's `PanicInfo` and std's `PanicInfo`.](https://github.com/rust-lang/rust/pull/115974/) (see compatibility note below)
2185- [Generalize `{Rc,Arc}::make_mut()` to unsized types.](https://github.com/rust-lang/rust/pull/116113/)
2186- [Replace sort implementations with stable `driftsort` and unstable `ipnsort`.](https://github.com/rust-lang/rust/pull/124032/) All `slice::sort*` and `slice::select_nth*` methods are expected to see significant performance improvements. See the [research project](https://github.com/Voultapher/sort-research-rs) for more details.
2187- [Document behavior of `create_dir_all` with respect to empty paths.](https://github.com/rust-lang/rust/pull/125112/)
2188- [Fix interleaved output in the default panic hook when multiple threads panic simultaneously.](https://github.com/rust-lang/rust/pull/127397/)
2189- Fix `Command`'s batch files argument escaping not working when file name has trailing whitespace or periods (CVE-2024-43402).
2190
2191<a id="1.81.0-Stabilized-APIs"></a>
2192
2193Stabilized APIs
2194---------------
2195
2196- [`core::error`](https://doc.rust-lang.org/stable/core/error/index.html)
2197- [`hint::assert_unchecked`](https://doc.rust-lang.org/stable/core/hint/fn.assert_unchecked.html)
2198- [`fs::exists`](https://doc.rust-lang.org/stable/std/fs/fn.exists.html)
2199- [`AtomicBool::fetch_not`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicBool.html#method.fetch_not)
2200- [`Duration::abs_diff`](https://doc.rust-lang.org/stable/core/time/struct.Duration.html#method.abs_diff)
2201- [`IoSlice::advance`](https://doc.rust-lang.org/stable/std/io/struct.IoSlice.html#method.advance)
2202- [`IoSlice::advance_slices`](https://doc.rust-lang.org/stable/std/io/struct.IoSlice.html#method.advance_slices)
2203- [`IoSliceMut::advance`](https://doc.rust-lang.org/stable/std/io/struct.IoSliceMut.html#method.advance)
2204- [`IoSliceMut::advance_slices`](https://doc.rust-lang.org/stable/std/io/struct.IoSliceMut.html#method.advance_slices)
2205- [`PanicHookInfo`](https://doc.rust-lang.org/stable/std/panic/struct.PanicHookInfo.html)
2206- [`PanicInfo::message`](https://doc.rust-lang.org/stable/core/panic/struct.PanicInfo.html#method.message)
2207- [`PanicMessage`](https://doc.rust-lang.org/stable/core/panic/struct.PanicMessage.html)
2208
2209These APIs are now stable in const contexts:
2210
2211- [`char::from_u32_unchecked`](https://doc.rust-lang.org/stable/core/char/fn.from_u32_unchecked.html) (function)
2212- [`char::from_u32_unchecked`](https://doc.rust-lang.org/stable/core/primitive.char.html#method.from_u32_unchecked) (method)
2213- [`CStr::count_bytes`](https://doc.rust-lang.org/stable/core/ffi/c_str/struct.CStr.html#method.count_bytes)
2214- [`CStr::from_ptr`](https://doc.rust-lang.org/stable/core/ffi/c_str/struct.CStr.html#method.from_ptr)
2215
2216<a id="1.81.0-Cargo"></a>
2217
2218Cargo
2219-----
2220
2221- [Generated `.cargo_vcs_info.json` is always included, even when `--allow-dirty` is passed.](https://github.com/rust-lang/cargo/pull/13960/)
2222- [Disallow `package.license-file` and `package.readme` pointing to non-existent files during packaging.](https://github.com/rust-lang/cargo/pull/13921/)
2223- [Disallow passing `--release`/`--debug` flag along with the `--profile` flag.](https://github.com/rust-lang/cargo/pull/13971/)
2224- [Remove `lib.plugin` key support in `Cargo.toml`. Rust plugin support has been deprecated for four years and was removed in 1.75.0.](https://github.com/rust-lang/cargo/pull/13902/)
2225
2226<a id="1.81.0-Compatibility-Notes"></a>
2227
2228Compatibility Notes
2229-------------------
2230
2231* Usage of the `wasm32-wasi` target will now issue a compiler warning and request users switch to the `wasm32-wasip1` target instead. Both targets are the same, `wasm32-wasi` is only being renamed, and this [change to the WASI target](https://blog.rust-lang.org/2024/04/09/updates-to-rusts-wasi-targets.html) is being done to enable removing `wasm32-wasi` in January 2025.
2232
2233* We have renamed `std::panic::PanicInfo` to `std::panic::PanicHookInfo`. The old name will continue to work as an alias, but will result in a deprecation warning starting in Rust 1.82.0.
2234
2235 `core::panic::PanicInfo` will remain unchanged, however, as this is now a *different type*.
2236
2237 The reason is that these types have different roles: `std::panic::PanicHookInfo` is the argument to the [panic hook](https://doc.rust-lang.org/stable/std/panic/fn.set_hook.html) in std context (where panics can have an arbitrary payload), while `core::panic::PanicInfo` is the argument to the [`#[panic_handler]`](https://doc.rust-lang.org/nomicon/panic-handler.html) in no_std context (where panics always carry a formatted *message*). Separating these types allows us to add more useful methods to these types, such as `std::panic::PanicHookInfo::payload_as_str()` and `core::panic::PanicInfo::message()`.
2238
2239* The new sort implementations may panic if a type's implementation of [`Ord`](https://doc.rust-lang.org/std/cmp/trait.Ord.html) (or the given comparison function) does not implement a [total order](https://en.wikipedia.org/wiki/Total_order) as the trait requires. `Ord`'s supertraits (`PartialOrd`, `Eq`, and `PartialEq`) must also be consistent. The previous implementations would not "notice" any problem, but the new implementations have a good chance of detecting inconsistencies, throwing a panic rather than returning knowingly unsorted data.
2240* [In very rare cases, a change in the internal evaluation order of the trait
2241 solver may result in new fatal overflow errors.](https://github.com/rust-lang/rust/pull/126128)
2242
2243
2244<a id="1.81.0-Internal-Changes"></a>
2245
2246Internal Changes
2247----------------
2248
2249These changes do not affect any public interfaces of Rust, but they represent
2250significant improvements to the performance or internals of rustc and related
2251tools.
2252
2253- [Add a Rust-for-Linux `auto` CI job to check kernel builds.](https://github.com/rust-lang/rust/pull/125209/)
2254
2255Version 1.80.1 (2024-08-08)
2256===========================
2257
2258<a id="1.80.1"></a>
2259
2260- [Fix miscompilation in the jump threading MIR optimization when comparing floats](https://github.com/rust-lang/rust/pull/128271)
2261- [Revert changes to the `dead_code` lint from 1.80.0](https://github.com/rust-lang/rust/pull/128618)
2262
2263Version 1.80.0 (2024-07-25)
2264==========================
2265
2266<a id="1.80-Language"></a>
2267
2268Language
2269--------
2270- [Document maximum allocation size](https://github.com/rust-lang/rust/pull/116675/)
2271- [Allow zero-byte offsets and ZST read/writes on arbitrary pointers](https://github.com/rust-lang/rust/pull/117329/)
2272- [Support C23's variadics without a named parameter](https://github.com/rust-lang/rust/pull/124048/)
2273- [Stabilize `exclusive_range_pattern` feature](https://github.com/rust-lang/rust/pull/124459/)
2274- [Guarantee layout and ABI of `Result` in some scenarios](https://github.com/rust-lang/rust/pull/124870)
2275
2276<a id="1.80-Compiler"></a>
2277
2278Compiler
2279--------
2280- [Update cc crate to v1.0.97 allowing additional spectre mitigations on MSVC targets](https://github.com/rust-lang/rust/pull/124892/)
2281- [Allow field reordering on types marked `repr(packed(1))`](https://github.com/rust-lang/rust/pull/125360/)
2282- [Add a lint against never type fallback affecting unsafe code](https://github.com/rust-lang/rust/pull/123939/)
2283- [Disallow cast with trailing braced macro in let-else](https://github.com/rust-lang/rust/pull/125049/)
2284- [Expand `for_loops_over_fallibles` lint to lint on fallibles behind references.](https://github.com/rust-lang/rust/pull/125156/)
2285- [self-contained linker: retry linking without `-fuse-ld=lld` on CCs that don't support it](https://github.com/rust-lang/rust/pull/125417/)
2286- [Do not parse CVarArgs (`...`) as a type in trait bounds](https://github.com/rust-lang/rust/pull/125863/)
2287- Improvements to LLDB formatting [#124458](https://github.com/rust-lang/rust/pull/124458) [#124500](https://github.com/rust-lang/rust/pull/124500)
2288- [For the wasm32-wasip2 target default to PIC and do not use `-fuse-ld=lld`](https://github.com/rust-lang/rust/pull/124858/)
2289- [Add x86_64-unknown-linux-none as a tier 3 target](https://github.com/rust-lang/rust/pull/125023/)
2290- [Lint on `foo.into_iter()` resolving to `&Box<[T]>: IntoIterator`](https://github.com/rust-lang/rust/pull/124097/)
2291
2292<a id="1.80-Libraries"></a>
2293
2294Libraries
2295---------
2296- [Add `size_of` and `size_of_val` and `align_of` and `align_of_val` to the prelude](https://github.com/rust-lang/rust/pull/123168/)
2297- [Abort a process when FD ownership is violated](https://github.com/rust-lang/rust/pull/124210/)
2298- [io::Write::write_fmt: panic if the formatter fails when the stream does not fail](https://github.com/rust-lang/rust/pull/125012/)
2299- [Panic if `PathBuf::set_extension` would add a path separator](https://github.com/rust-lang/rust/pull/125070/)
2300- [Add assert_unsafe_precondition to unchecked_{add,sub,neg,mul,shl,shr} methods](https://github.com/rust-lang/rust/pull/121571/)
2301- [Update `c_char` on AIX to use the correct type](https://github.com/rust-lang/rust/pull/122986/)
2302- [`offset_of!` no longer returns a temporary](https://github.com/rust-lang/rust/pull/124484/)
2303- [Handle sigma in `str.to_lowercase` correctly](https://github.com/rust-lang/rust/pull/124773/)
2304- [Raise `DEFAULT_MIN_STACK_SIZE` to at least 64KiB](https://github.com/rust-lang/rust/pull/126059/)
2305
2306<a id="1.80-Stabilized-APIs"></a>
2307
2308Stabilized APIs
2309---------------
2310- [`impl Default for Rc<CStr>`](https://doc.rust-lang.org/beta/alloc/rc/struct.Rc.html#impl-Default-for-Rc%3CCStr%3E)
2311- [`impl Default for Rc<str>`](https://doc.rust-lang.org/beta/alloc/rc/struct.Rc.html#impl-Default-for-Rc%3Cstr%3E)
2312- [`impl Default for Rc<[T]>`](https://doc.rust-lang.org/beta/alloc/rc/struct.Rc.html#impl-Default-for-Rc%3C%5BT%5D%3E)
2313- [`impl Default for Arc<str>`](https://doc.rust-lang.org/beta/alloc/sync/struct.Arc.html#impl-Default-for-Arc%3Cstr%3E)
2314- [`impl Default for Arc<CStr>`](https://doc.rust-lang.org/beta/alloc/sync/struct.Arc.html#impl-Default-for-Arc%3CCStr%3E)
2315- [`impl Default for Arc<[T]>`](https://doc.rust-lang.org/beta/alloc/sync/struct.Arc.html#impl-Default-for-Arc%3C%5BT%5D%3E)
2316- [`impl IntoIterator for Box<[T]>`](https://doc.rust-lang.org/beta/alloc/boxed/struct.Box.html#impl-IntoIterator-for-Box%3C%5BI%5D,+A%3E)
2317- [`impl FromIterator<String> for Box<str>`](https://doc.rust-lang.org/beta/alloc/boxed/struct.Box.html#impl-FromIterator%3CString%3E-for-Box%3Cstr%3E)
2318- [`impl FromIterator<char> for Box<str>`](https://doc.rust-lang.org/beta/alloc/boxed/struct.Box.html#impl-FromIterator%3Cchar%3E-for-Box%3Cstr%3E)
2319- [`LazyCell`](https://doc.rust-lang.org/beta/core/cell/struct.LazyCell.html)
2320- [`LazyLock`](https://doc.rust-lang.org/beta/std/sync/struct.LazyLock.html)
2321- [`Duration::div_duration_f32`](https://doc.rust-lang.org/beta/std/time/struct.Duration.html#method.div_duration_f32)
2322- [`Duration::div_duration_f64`](https://doc.rust-lang.org/beta/std/time/struct.Duration.html#method.div_duration_f64)
2323- [`Option::take_if`](https://doc.rust-lang.org/beta/std/option/enum.Option.html#method.take_if)
2324- [`Seek::seek_relative`](https://doc.rust-lang.org/beta/std/io/trait.Seek.html#method.seek_relative)
2325- [`BinaryHeap::as_slice`](https://doc.rust-lang.org/beta/std/collections/struct.BinaryHeap.html#method.as_slice)
2326- [`NonNull::offset`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.offset)
2327- [`NonNull::byte_offset`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.byte_offset)
2328- [`NonNull::add`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.add)
2329- [`NonNull::byte_add`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.byte_add)
2330- [`NonNull::sub`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.sub)
2331- [`NonNull::byte_sub`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.byte_sub)
2332- [`NonNull::offset_from`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.offset_from)
2333- [`NonNull::byte_offset_from`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.byte_offset_from)
2334- [`NonNull::read`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.read)
2335- [`NonNull::read_volatile`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.read_volatile)
2336- [`NonNull::read_unaligned`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.read_unaligned)
2337- [`NonNull::write`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.write)
2338- [`NonNull::write_volatile`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.write_volatile)
2339- [`NonNull::write_unaligned`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.write_unaligned)
2340- [`NonNull::write_bytes`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.write_bytes)
2341- [`NonNull::copy_to`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.copy_to)
2342- [`NonNull::copy_to_nonoverlapping`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.copy_to_nonoverlapping)
2343- [`NonNull::copy_from`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.copy_from)
2344- [`NonNull::copy_from_nonoverlapping`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.copy_from_nonoverlapping)
2345- [`NonNull::replace`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.replace)
2346- [`NonNull::swap`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.swap)
2347- [`NonNull::drop_in_place`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.drop_in_place)
2348- [`NonNull::align_offset`](https://doc.rust-lang.org/beta/std/ptr/struct.NonNull.html#method.align_offset)
2349- [`<[T]>::split_at_checked`](https://doc.rust-lang.org/beta/std/primitive.slice.html#method.split_at_checked)
2350- [`<[T]>::split_at_mut_checked`](https://doc.rust-lang.org/beta/std/primitive.slice.html#method.split_at_mut_checked)
2351- [`str::split_at_checked`](https://doc.rust-lang.org/beta/std/primitive.str.html#method.split_at_checked)
2352- [`str::split_at_mut_checked`](https://doc.rust-lang.org/beta/std/primitive.str.html#method.split_at_mut_checked)
2353- [`str::trim_ascii`](https://doc.rust-lang.org/beta/std/primitive.str.html#method.trim_ascii)
2354- [`str::trim_ascii_start`](https://doc.rust-lang.org/beta/std/primitive.str.html#method.trim_ascii_start)
2355- [`str::trim_ascii_end`](https://doc.rust-lang.org/beta/std/primitive.str.html#method.trim_ascii_end)
2356- [`<[u8]>::trim_ascii`](https://doc.rust-lang.org/beta/core/primitive.slice.html#method.trim_ascii)
2357- [`<[u8]>::trim_ascii_start`](https://doc.rust-lang.org/beta/core/primitive.slice.html#method.trim_ascii_start)
2358- [`<[u8]>::trim_ascii_end`](https://doc.rust-lang.org/beta/core/primitive.slice.html#method.trim_ascii_end)
2359- [`Ipv4Addr::BITS`](https://doc.rust-lang.org/beta/core/net/struct.Ipv4Addr.html#associatedconstant.BITS)
2360- [`Ipv4Addr::to_bits`](https://doc.rust-lang.org/beta/core/net/struct.Ipv4Addr.html#method.to_bits)
2361- [`Ipv4Addr::from_bits`](https://doc.rust-lang.org/beta/core/net/struct.Ipv4Addr.html#method.from_bits)
2362- [`Ipv6Addr::BITS`](https://doc.rust-lang.org/beta/core/net/struct.Ipv6Addr.html#associatedconstant.BITS)
2363- [`Ipv6Addr::to_bits`](https://doc.rust-lang.org/beta/core/net/struct.Ipv6Addr.html#method.to_bits)
2364- [`Ipv6Addr::from_bits`](https://doc.rust-lang.org/beta/core/net/struct.Ipv6Addr.html#method.from_bits)
2365- [`Vec::<[T; N]>::into_flattened`](https://doc.rust-lang.org/beta/alloc/vec/struct.Vec.html#method.into_flattened)
2366- [`<[[T; N]]>::as_flattened`](https://doc.rust-lang.org/beta/core/primitive.slice.html#method.as_flattened)
2367- [`<[[T; N]]>::as_flattened_mut`](https://doc.rust-lang.org/beta/core/primitive.slice.html#method.as_flattened_mut)
2368
2369These APIs are now stable in const contexts:
2370
2371- [`<[T]>::last_chunk`](https://doc.rust-lang.org/beta/core/primitive.slice.html#method.last_chunk)
2372- [`BinaryHeap::new`](https://doc.rust-lang.org/beta/std/collections/struct.BinaryHeap.html#method.new)
2373
2374<a id="1.80-Cargo"></a>
2375
2376Cargo
2377-----
2378- [Stabilize `-Zcheck-cfg` as always enabled](https://github.com/rust-lang/cargo/pull/13571/)
2379- [Warn, rather than fail publish, if a target is excluded](https://github.com/rust-lang/cargo/pull/13713/)
2380- [Add special `check-cfg` lint config for the `unexpected_cfgs` lint](https://github.com/rust-lang/cargo/pull/13913/)
2381- [Stabilize `cargo update --precise <yanked>`](https://github.com/rust-lang/cargo/pull/13974/)
2382- [Don't change file permissions on `Cargo.toml` when using `cargo add`](https://github.com/rust-lang/cargo/pull/13898/)
2383- [Support using `cargo fix` on IPv6-only networks](https://github.com/rust-lang/cargo/pull/13907/)
2384
2385<a id="1.80-Rustdoc"></a>
2386
2387Rustdoc
2388-----
2389
2390- [Allow searching for references](https://github.com/rust-lang/rust/pull/124148/)
2391- [Stabilize `custom_code_classes_in_docs` feature](https://github.com/rust-lang/rust/pull/124577/)
2392- [fix: In cross-crate scenarios show enum variants on type aliases of enums](https://github.com/rust-lang/rust/pull/125300/)
2393
2394<a id="1.80-Compatibility-Notes"></a>
2395
2396Compatibility Notes
2397-------------------
2398- [rustfmt estimates line lengths differently when using non-ascii characters](https://github.com/rust-lang/rustfmt/issues/6203)
2399- [Type aliases are now handled correctly in orphan check](https://github.com/rust-lang/rust/pull/117164/)
2400- [Allow instructing rustdoc to read from stdin via `-`](https://github.com/rust-lang/rust/pull/124611/)
2401- [`std::env::{set_var, remove_var}` can no longer be converted to safe function pointers and no longer implement the `Fn` family of traits](https://github.com/rust-lang/rust/pull/124636)
2402- [Warn (or error) when `Self` constructor from outer item is referenced in inner nested item](https://github.com/rust-lang/rust/pull/124187/)
2403- [Turn `indirect_structural_match` and `pointer_structural_match` lints into hard errors](https://github.com/rust-lang/rust/pull/124661/)
2404- [Make `where_clause_object_safety` lint a regular object safety violation](https://github.com/rust-lang/rust/pull/125380/)
2405- [Turn `proc_macro_back_compat` lint into a hard error.](https://github.com/rust-lang/rust/pull/125596/)
2406- [Detect unused structs even when implementing private traits](https://github.com/rust-lang/rust/pull/122382/)
2407- [`std::sync::ReentrantLockGuard<T>` is no longer `Sync` if `T: !Sync`](https://github.com/rust-lang/rust/pull/125527) which means [`std::io::StdoutLock` and `std::io::StderrLock` are no longer Sync](https://github.com/rust-lang/rust/issues/127340)
2408- [Type inference will fail in some cases due to new implementations of `FromIterator for Box<str>`.](https://github.com/rust-lang/rust/pull/99969/)
2409 Notably, this breaks versions of the `time` crate before 0.3.35, due to no longer inferring the implementation for `Box<[_]>`.
2410
2411<a id="1.80-Internal-Changes"></a>
2412
2413Internal Changes
2414----------------
2415
2416These changes do not affect any public interfaces of Rust, but they represent
2417significant improvements to the performance or internals of rustc and related
2418tools.
2419
2420- Misc improvements to size of generated html by rustdoc e.g. [#124738](https://github.com/rust-lang/rust/pull/124738/) and [#123734](https://github.com/rust-lang/rust/pull/123734/)
2421- [MSVC targets no longer depend on libc](https://github.com/rust-lang/rust/pull/124050/)
2422
2423Version 1.79.0 (2024-06-13)
2424==========================
2425
2426<a id="1.79.0-Language"></a>
2427
2428Language
2429--------
2430- [Stabilize inline `const {}` expressions.](https://github.com/rust-lang/rust/pull/104087/)
2431- [Prevent opaque types being instantiated twice with different regions within the same function.](https://github.com/rust-lang/rust/pull/116935/)
2432- [Stabilize WebAssembly target features that are in phase 4 and 5.](https://github.com/rust-lang/rust/pull/117457/)
2433- [Add the `redundant_lifetimes` lint to detect lifetimes which are semantically redundant.](https://github.com/rust-lang/rust/pull/118391/)
2434- [Stabilize the `unnameable_types` lint for public types that can't be named.](https://github.com/rust-lang/rust/pull/120144/)
2435- [Enable debuginfo in macros, and stabilize `-C collapse-macro-debuginfo` and `#[collapse_debuginfo]`.](https://github.com/rust-lang/rust/pull/120845/)
2436- [Propagate temporary lifetime extension into `if` and `match` expressions.](https://github.com/rust-lang/rust/pull/121346/)
2437- [Restrict promotion of `const fn` calls.](https://github.com/rust-lang/rust/pull/121557/)
2438- [Warn against refining impls of crate-private traits with `refining_impl_trait` lint.](https://github.com/rust-lang/rust/pull/121720/)
2439- [Stabilize associated type bounds (RFC 2289).](https://github.com/rust-lang/rust/pull/122055/)
2440- [Stabilize importing `main` from other modules or crates.](https://github.com/rust-lang/rust/pull/122060/)
2441- [Check return types of function types for well-formedness](https://github.com/rust-lang/rust/pull/115538)
2442- [Rework `impl Trait` lifetime inference](https://github.com/rust-lang/rust/pull/116891/)
2443- [Change inductive trait solver cycles to be ambiguous](https://github.com/rust-lang/rust/pull/122791)
2444
2445<a id="1.79.0-Compiler"></a>
2446
2447Compiler
2448--------
2449- [Define `-C strip` to only affect binaries, not artifacts like `.pdb`.](https://github.com/rust-lang/rust/pull/115120/)
2450- [Stabilize `-Crelro-level` for controlling runtime link hardening.](https://github.com/rust-lang/rust/pull/121694/)
2451- [Stabilize checking of `cfg` names and values at compile-time with `--check-cfg`.](https://github.com/rust-lang/rust/pull/123501/)
2452 *Note that this only stabilizes the compiler part, the Cargo part is still unstable in this release.*
2453- [Add `aarch64-apple-visionos` and `aarch64-apple-visionos-sim` tier 3 targets.](https://github.com/rust-lang/rust/pull/121419/)
2454- [Add `riscv32ima-unknown-none-elf` tier 3 target.](https://github.com/rust-lang/rust/pull/122696/)
2455- [Promote several Windows targets to tier 2](https://github.com/rust-lang/rust/pull/121712): `aarch64-pc-windows-gnullvm`, `i686-pc-windows-gnullvm`, and `x86_64-pc-windows-gnullvm`.
2456
2457Refer to Rust's [platform support page][platform-support-doc]
2458for more information on Rust's tiered platform support.
2459
2460<a id="1.79.0-Libraries"></a>
2461
2462Libraries
2463---------
2464
2465- [Implement `FromIterator` for `(impl Default + Extend, impl Default + Extend)`.](https://github.com/rust-lang/rust/pull/107462/)
2466- [Implement `{Div,Rem}Assign<NonZero<X>>` on `X`.](https://github.com/rust-lang/rust/pull/121952/)
2467- [Document overrides of `clone_from()` in core/std.](https://github.com/rust-lang/rust/pull/122201/)
2468- [Link MSVC default lib in core.](https://github.com/rust-lang/rust/pull/122268/)
2469- [Caution against using `transmute` between pointers and integers.](https://github.com/rust-lang/rust/pull/122379/)
2470- [Enable frame pointers for the standard library.](https://github.com/rust-lang/rust/pull/122646/)
2471
2472<a id="1.79.0-Stabilized-APIs"></a>
2473
2474Stabilized APIs
2475---------------
2476
2477- [`{integer}::unchecked_add`](https://doc.rust-lang.org/stable/core/primitive.i32.html#method.unchecked_add)
2478- [`{integer}::unchecked_mul`](https://doc.rust-lang.org/stable/core/primitive.i32.html#method.unchecked_mul)
2479- [`{integer}::unchecked_sub`](https://doc.rust-lang.org/stable/core/primitive.i32.html#method.unchecked_sub)
2480- [`<[T]>::split_at_unchecked`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.split_at_unchecked)
2481- [`<[T]>::split_at_mut_unchecked`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.split_at_mut_unchecked)
2482- [`<[u8]>::utf8_chunks`](https://doc.rust-lang.org/stable/core/primitive.slice.html#method.utf8_chunks)
2483- [`str::Utf8Chunks`](https://doc.rust-lang.org/stable/core/str/struct.Utf8Chunks.html)
2484- [`str::Utf8Chunk`](https://doc.rust-lang.org/stable/core/str/struct.Utf8Chunk.html)
2485- [`<*const T>::is_aligned`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.is_aligned)
2486- [`<*mut T>::is_aligned`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.is_aligned-1)
2487- [`NonNull::is_aligned`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.is_aligned)
2488- [`<*const [T]>::len`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.len)
2489- [`<*mut [T]>::len`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.len-1)
2490- [`<*const [T]>::is_empty`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.is_empty)
2491- [`<*mut [T]>::is_empty`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.is_empty-1)
2492- [`NonNull::<[T]>::is_empty`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.is_empty)
2493- [`CStr::count_bytes`](https://doc.rust-lang.org/stable/core/ffi/c_str/struct.CStr.html#method.count_bytes)
2494- [`io::Error::downcast`](https://doc.rust-lang.org/stable/std/io/struct.Error.html#method.downcast)
2495- [`num::NonZero<T>`](https://doc.rust-lang.org/stable/core/num/struct.NonZero.html)
2496- [`path::absolute`](https://doc.rust-lang.org/stable/std/path/fn.absolute.html)
2497- [`proc_macro::Literal::byte_character`](https://doc.rust-lang.org/stable/proc_macro/struct.Literal.html#method.byte_character)
2498- [`proc_macro::Literal::c_string`](https://doc.rust-lang.org/stable/proc_macro/struct.Literal.html#method.c_string)
2499
2500These APIs are now stable in const contexts:
2501
2502- [`Atomic*::into_inner`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicUsize.html#method.into_inner)
2503- [`io::Cursor::new`](https://doc.rust-lang.org/stable/std/io/struct.Cursor.html#method.new)
2504- [`io::Cursor::get_ref`](https://doc.rust-lang.org/stable/std/io/struct.Cursor.html#method.get_ref)
2505- [`io::Cursor::position`](https://doc.rust-lang.org/stable/std/io/struct.Cursor.html#method.position)
2506- [`io::empty`](https://doc.rust-lang.org/stable/std/io/fn.empty.html)
2507- [`io::repeat`](https://doc.rust-lang.org/stable/std/io/fn.repeat.html)
2508- [`io::sink`](https://doc.rust-lang.org/stable/std/io/fn.sink.html)
2509- [`panic::Location::caller`](https://doc.rust-lang.org/stable/std/panic/struct.Location.html#method.caller)
2510- [`panic::Location::file`](https://doc.rust-lang.org/stable/std/panic/struct.Location.html#method.file)
2511- [`panic::Location::line`](https://doc.rust-lang.org/stable/std/panic/struct.Location.html#method.line)
2512- [`panic::Location::column`](https://doc.rust-lang.org/stable/std/panic/struct.Location.html#method.column)
2513
2514<a id="1.79.0-Cargo"></a>
2515
2516Cargo
2517-----
2518
2519- [Prevent dashes in `lib.name`, always normalizing to `_`.](https://github.com/rust-lang/cargo/pull/12783/)
2520- [Stabilize MSRV-aware version requirement selection in `cargo add`.](https://github.com/rust-lang/cargo/pull/13608/)
2521- [Switch to using `gitoxide` by default for listing files.](https://github.com/rust-lang/cargo/pull/13696/)
2522
2523<a id="1.79.0-Rustdoc"></a>
2524
2525Rustdoc
2526-----
2527
2528- [Always display stability version even if it's the same as the containing item.](https://github.com/rust-lang/rust/pull/118441/)
2529- [Show a single search result for items with multiple paths.](https://github.com/rust-lang/rust/pull/119912/)
2530- [Support typing `/` in docs to begin a search.](https://github.com/rust-lang/rust/pull/123355/)
2531
2532<a id="1.79.0-Misc"></a>
2533
2534Misc
2535----
2536
2537<a id="1.79.0-Compatibility-Notes"></a>
2538
2539Compatibility Notes
2540-------------------
2541
2542- [Update the minimum external LLVM to 17.](https://github.com/rust-lang/rust/pull/122649/)
2543- [`RustcEncodable` and `RustcDecodable` are soft-destabilized, to be removed
2544 from the prelude in next edition.](https://github.com/rust-lang/rust/pull/116016/)
2545- [The `wasm_c_abi` future-incompatibility lint will warn about use of the
2546 non-spec-compliant C ABI.](https://github.com/rust-lang/rust/pull/117918/)
2547 Use `wasm-bindgen v0.2.88` to generate forward-compatible bindings.
2548- [Check return types of function types for well-formedness](https://github.com/rust-lang/rust/pull/115538)
2549
2550Version 1.78.0 (2024-05-02)
2551==========================
2552
2553<a id="1.78.0-Language"></a>
2554
2555Language
2556--------
2557- [Stabilize `#[cfg(target_abi = ...)]`](https://github.com/rust-lang/rust/pull/119590/)
2558- [Stabilize the `#[diagnostic]` namespace and `#[diagnostic::on_unimplemented]` attribute](https://github.com/rust-lang/rust/pull/119888/)
2559- [Make async-fn-in-trait implementable with concrete signatures](https://github.com/rust-lang/rust/pull/120103/)
2560- [Make matching on NaN a hard error, and remove the rest of `illegal_floating_point_literal_pattern`](https://github.com/rust-lang/rust/pull/116284/)
2561- [static mut: allow mutable reference to arbitrary types, not just slices and arrays](https://github.com/rust-lang/rust/pull/117614/)
2562- [Extend `invalid_reference_casting` to include references casting to bigger memory layout](https://github.com/rust-lang/rust/pull/118983/)
2563- [Add `non_contiguous_range_endpoints` lint for singleton gaps after exclusive ranges](https://github.com/rust-lang/rust/pull/118879/)
2564- [Add `wasm_c_abi` lint for use of older wasm-bindgen versions](https://github.com/rust-lang/rust/pull/117918/)
2565 This lint currently only works when using Cargo.
2566- [Update `indirect_structural_match` and `pointer_structural_match` lints to match RFC](https://github.com/rust-lang/rust/pull/120423/)
2567- [Make non-`PartialEq`-typed consts as patterns a hard error](https://github.com/rust-lang/rust/pull/120805/)
2568- [Split `refining_impl_trait` lint into `_reachable`, `_internal` variants](https://github.com/rust-lang/rust/pull/121720/)
2569- [Remove unnecessary type inference when using associated types inside of higher ranked `where`-bounds](https://github.com/rust-lang/rust/pull/119849)
2570- [Weaken eager detection of cyclic types during type inference](https://github.com/rust-lang/rust/pull/119989)
2571- [`trait Trait: Auto {}`: allow upcasting from `dyn Trait` to `dyn Trait + Auto`](https://github.com/rust-lang/rust/pull/119338)
2572
2573<a id="1.78.0-Compiler"></a>
2574
2575Compiler
2576--------
2577
2578- [Made `INVALID_DOC_ATTRIBUTES` lint deny by default](https://github.com/rust-lang/rust/pull/111505/)
2579- [Increase accuracy of redundant `use` checking](https://github.com/rust-lang/rust/pull/117772/)
2580- [Suggest moving definition if non-found macro_rules! is defined later](https://github.com/rust-lang/rust/pull/121130/)
2581- [Lower transmutes from int to pointer type as gep on null](https://github.com/rust-lang/rust/pull/121282/)
2582
2583Target changes:
2584
2585- [Windows tier 1 targets now require at least Windows 10](https://github.com/rust-lang/rust/pull/115141/)
2586 - [Enable CMPXCHG16B, SSE3, SAHF/LAHF and 128-bit Atomics in tier 1 Windows](https://github.com/rust-lang/rust/pull/120820/)
2587- [Add `wasm32-wasip1` tier 2 (without host tools) target](https://github.com/rust-lang/rust/pull/120468/)
2588- [Add `wasm32-wasip2` tier 3 target](https://github.com/rust-lang/rust/pull/119616/)
2589- [Rename `wasm32-wasi-preview1-threads` to `wasm32-wasip1-threads`](https://github.com/rust-lang/rust/pull/122170/)
2590- [Add `arm64ec-pc-windows-msvc` tier 3 target](https://github.com/rust-lang/rust/pull/119199/)
2591- [Add `armv8r-none-eabihf` tier 3 target for the Cortex-R52](https://github.com/rust-lang/rust/pull/110482/)
2592- [Add `loongarch64-unknown-linux-musl` tier 3 target](https://github.com/rust-lang/rust/pull/121832/)
2593
2594Refer to Rust's [platform support page][platform-support-doc]
2595for more information on Rust's tiered platform support.
2596
2597<a id="1.78.0-Libraries"></a>
2598
2599Libraries
2600---------
2601
2602- [Bump Unicode to version 15.1.0, regenerate tables](https://github.com/rust-lang/rust/pull/120777/)
2603- [Make align_offset, align_to well-behaved in all cases](https://github.com/rust-lang/rust/pull/121201/)
2604- [PartialEq, PartialOrd: document expectations for transitive chains](https://github.com/rust-lang/rust/pull/115386/)
2605- [Optimize away poison guards when std is built with panic=abort](https://github.com/rust-lang/rust/pull/100603/)
2606- [Replace pthread `RwLock` with custom implementation](https://github.com/rust-lang/rust/pull/110211/)
2607- [Implement unwind safety for Condvar on all platforms](https://github.com/rust-lang/rust/pull/121768/)
2608- [Add ASCII fast-path for `char::is_grapheme_extended`](https://github.com/rust-lang/rust/pull/121138/)
2609
2610<a id="1.78.0-Stabilized-APIs"></a>
2611
2612Stabilized APIs
2613---------------
2614
2615- [`impl Read for &Stdin`](https://doc.rust-lang.org/stable/std/io/struct.Stdin.html#impl-Read-for-%26Stdin)
2616- [Accept non `'static` lifetimes for several `std::error::Error` related implementations](https://github.com/rust-lang/rust/pull/113833/)
2617- [Make `impl<Fd: AsFd>` impl take `?Sized`](https://github.com/rust-lang/rust/pull/114655/)
2618- [`impl From<TryReserveError> for io::Error`](https://doc.rust-lang.org/stable/std/io/struct.Error.html#impl-From%3CTryReserveError%3E-for-Error)
2619
2620These APIs are now stable in const contexts:
2621
2622- [`Barrier::new()`](https://doc.rust-lang.org/stable/std/sync/struct.Barrier.html#method.new)
2623
2624<a id="1.78.0-Cargo"></a>
2625
2626Cargo
2627-----
2628
2629- [Stabilize lockfile v4](https://github.com/rust-lang/cargo/pull/12852/)
2630- [Respect `rust-version` when generating lockfile](https://github.com/rust-lang/cargo/pull/12861/)
2631- [Control `--charset` via auto-detecting config value](https://github.com/rust-lang/cargo/pull/13337/)
2632- [Support `target.<triple>.rustdocflags` officially](https://github.com/rust-lang/cargo/pull/13197/)
2633- [Stabilize global cache data tracking](https://github.com/rust-lang/cargo/pull/13492/)
2634
2635<a id="1.78.0-Compatibility-Notes"></a>
2636
2637Compatibility Notes
2638-------------------
2639
2640- [Many unsafe precondition checks now run for user code with debug assertions enabled](https://github.com/rust-lang/rust/pull/120594/)
2641 This change helps users catch undefined behavior in their code, though the details of how much is checked are generally not stable.
2642- [riscv only supports split_debuginfo=off for now](https://github.com/rust-lang/rust/pull/120518/)
2643- [Consistently check bounds on hidden types of `impl Trait`](https://github.com/rust-lang/rust/pull/121679)
2644- [Change equality of higher ranked types to not rely on subtyping](https://github.com/rust-lang/rust/pull/118247)
2645- [When called, additionally check bounds on normalized function return type](https://github.com/rust-lang/rust/pull/118882)
2646- [Expand coverage for `arithmetic_overflow` lint](https://github.com/rust-lang/rust/pull/119432/)
2647- [Fix detection of potential interior mutability in `const` initializers](https://github.com/rust-lang/rust/issues/121250)
2648 This code was accidentally accepted. The fix can break generic code that borrows a value of unknown type,
2649 as there is currently no way to declare "this type has no interior mutability". In the future, stabilizing
2650 the [`Freeze` trait](https://github.com/rust-lang/rust/issues/121675) will allow proper support for such code.
2651
2652<a id="1.78.0-Internal-Changes"></a>
2653
2654Internal Changes
2655----------------
2656
2657These changes do not affect any public interfaces of Rust, but they represent
2658significant improvements to the performance or internals of rustc and related
2659tools.
2660
2661- [Update to LLVM 18](https://github.com/rust-lang/rust/pull/120055/)
2662- [Build `rustc` with 1CGU on `x86_64-pc-windows-msvc`](https://github.com/rust-lang/rust/pull/112267/)
2663- [Build `rustc` with 1CGU on `x86_64-apple-darwin`](https://github.com/rust-lang/rust/pull/112268/)
2664- [Introduce `run-make` V2 infrastructure, a `run_make_support` library and port over 2 tests as example](https://github.com/rust-lang/rust/pull/113026/)
2665- [Windows: Implement condvar, mutex and rwlock using futex](https://github.com/rust-lang/rust/pull/121956/)
2666
2667Version 1.77.2 (2024-04-09)
2668===========================
2669
2670<a id="1.77.2"></a>
2671
2672- [CVE-2024-24576: fix escaping of Windows batch file arguments in `std::process::Command`](https://blog.rust-lang.org/2024/04/09/cve-2024-24576.html)
2673
2674Version 1.77.1 (2024-03-28)
2675===========================
2676
2677<a id="1.77.1"></a>
2678
2679- [Revert stripping debuginfo by default for Windows](https://github.com/rust-lang/cargo/pull/13654)
2680 This fixes a regression in 1.77 by reverting to the previous default.
2681 Platforms other than Windows are not affected.
2682- Internal: [Fix heading anchor rendering in doc pages](https://github.com/rust-lang/rust/pull/122693)
2683
2684Version 1.77.0 (2024-03-21)
2685==========================
2686
2687<a id="1.77.0-Language"></a>
2688
2689Language
2690--------
2691
2692- [Reveal opaque types within the defining body for exhaustiveness checking.](https://github.com/rust-lang/rust/pull/116821/)
2693- [Stabilize C-string literals.](https://github.com/rust-lang/rust/pull/117472/)
2694- [Stabilize THIR unsafeck.](https://github.com/rust-lang/rust/pull/117673/)
2695- [Add lint `static_mut_refs` to warn on references to mutable statics.](https://github.com/rust-lang/rust/pull/117556/)
2696- [Support async recursive calls (as long as they have indirection).](https://github.com/rust-lang/rust/pull/117703/)
2697- [Undeprecate lint `unstable_features` and make use of it in the compiler.](https://github.com/rust-lang/rust/pull/118639/)
2698- [Make inductive cycles in coherence ambiguous always.](https://github.com/rust-lang/rust/pull/118649/)
2699- [Get rid of type-driven traversal in const-eval interning](https://github.com/rust-lang/rust/pull/119044/),
2700 only as a [future compatibility lint](https://github.com/rust-lang/rust/pull/122204) for now.
2701- [Deny braced macro invocations in let-else.](https://github.com/rust-lang/rust/pull/119062/)
2702
2703<a id="1.77.0-Compiler"></a>
2704
2705Compiler
2706--------
2707
2708- [Include lint `soft_unstable` in future breakage reports.](https://github.com/rust-lang/rust/pull/116274/)
2709- [Make `i128` and `u128` 16-byte aligned on x86-based targets.](https://github.com/rust-lang/rust/pull/116672/)
2710- [Use `--verbose` in diagnostic output.](https://github.com/rust-lang/rust/pull/119129/)
2711- [Improve spacing between printed tokens.](https://github.com/rust-lang/rust/pull/120227/)
2712- [Merge the `unused_tuple_struct_fields` lint into `dead_code`.](https://github.com/rust-lang/rust/pull/118297/)
2713- [Error on incorrect implied bounds in well-formedness check](https://github.com/rust-lang/rust/pull/118553/),
2714 with a temporary exception for Bevy.
2715- [Fix coverage instrumentation/reports for non-ASCII source code.](https://github.com/rust-lang/rust/pull/119033/)
2716- [Fix `fn`/`const` items implied bounds and well-formedness check.](https://github.com/rust-lang/rust/pull/120019/)
2717- [Promote `riscv32{im|imafc}-unknown-none-elf` targets to tier 2.](https://github.com/rust-lang/rust/pull/118704/)
2718- Add several new tier 3 targets:
2719 - [`aarch64-unknown-illumos`](https://github.com/rust-lang/rust/pull/112936/)
2720 - [`hexagon-unknown-none-elf`](https://github.com/rust-lang/rust/pull/117601/)
2721 - [`riscv32imafc-esp-espidf`](https://github.com/rust-lang/rust/pull/119738/)
2722 - [`riscv32im-risc0-zkvm-elf`](https://github.com/rust-lang/rust/pull/117958/)
2723
2724Refer to Rust's [platform support page][platform-support-doc]
2725for more information on Rust's tiered platform support.
2726
2727<a id="1.77.0-Libraries"></a>
2728
2729Libraries
2730---------
2731
2732- [Implement `From<&[T; N]>` for `Cow<[T]>`.](https://github.com/rust-lang/rust/pull/113489/)
2733- [Remove special-case handling of `vec.split_off(0)`.](https://github.com/rust-lang/rust/pull/119917/)
2734
2735<a id="1.77.0-Stabilized-APIs"></a>
2736
2737Stabilized APIs
2738---------------
2739
2740- [`array::each_ref`](https://doc.rust-lang.org/stable/std/primitive.array.html#method.each_ref)
2741- [`array::each_mut`](https://doc.rust-lang.org/stable/std/primitive.array.html#method.each_mut)
2742- [`core::net`](https://doc.rust-lang.org/stable/core/net/index.html)
2743- [`f32::round_ties_even`](https://doc.rust-lang.org/stable/std/primitive.f32.html#method.round_ties_even)
2744- [`f64::round_ties_even`](https://doc.rust-lang.org/stable/std/primitive.f64.html#method.round_ties_even)
2745- [`mem::offset_of!`](https://doc.rust-lang.org/stable/std/mem/macro.offset_of.html)
2746- [`slice::first_chunk`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.first_chunk)
2747- [`slice::first_chunk_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.first_chunk_mut)
2748- [`slice::split_first_chunk`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_first_chunk)
2749- [`slice::split_first_chunk_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_first_chunk_mut)
2750- [`slice::last_chunk`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.last_chunk)
2751- [`slice::last_chunk_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.last_chunk_mut)
2752- [`slice::split_last_chunk`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_last_chunk)
2753- [`slice::split_last_chunk_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_last_chunk_mut)
2754- [`slice::chunk_by`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.chunk_by)
2755- [`slice::chunk_by_mut`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.chunk_by_mut)
2756- [`Bound::map`](https://doc.rust-lang.org/stable/std/ops/enum.Bound.html#method.map)
2757- [`File::create_new`](https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.create_new)
2758- [`Mutex::clear_poison`](https://doc.rust-lang.org/stable/std/sync/struct.Mutex.html#method.clear_poison)
2759- [`RwLock::clear_poison`](https://doc.rust-lang.org/stable/std/sync/struct.RwLock.html#method.clear_poison)
2760
2761<a id="1.77.0-Cargo"></a>
2762
2763Cargo
2764-----
2765
2766- [Extend the build directive syntax with `cargo::`.](https://github.com/rust-lang/cargo/pull/12201/)
2767- [Stabilize metadata `id` format as `PackageIDSpec`.](https://github.com/rust-lang/cargo/pull/12914/)
2768- [Pull out `cargo-util-schemas` as a crate.](https://github.com/rust-lang/cargo/pull/13178/)
2769- [Strip all debuginfo when debuginfo is not requested.](https://github.com/rust-lang/cargo/pull/13257/)
2770- [Inherit jobserver from env for all kinds of runners.](https://github.com/rust-lang/cargo/pull/12776/)
2771- [Deprecate rustc plugin support in cargo.](https://github.com/rust-lang/cargo/pull/13248/)
2772
2773<a id="1.77.0-Rustdoc"></a>
2774
2775Rustdoc
2776-----
2777
2778- [Allows links in markdown headings.](https://github.com/rust-lang/rust/pull/117662/)
2779- [Search for tuples and unit by type with `()`.](https://github.com/rust-lang/rust/pull/118194/)
2780- [Clean up the source sidebar's hide button.](https://github.com/rust-lang/rust/pull/119066/)
2781- [Prevent JS injection from `localStorage`.](https://github.com/rust-lang/rust/pull/120250/)
2782
2783<a id="1.77.0-Misc"></a>
2784
2785Misc
2786----
2787
2788- [Recommend version-sorting for all sorting in style guide.](https://github.com/rust-lang/rust/pull/115046/)
2789
2790<a id="1.77.0-Internal-Changes"></a>
2791
2792Internal Changes
2793----------------
2794
2795These changes do not affect any public interfaces of Rust, but they represent
2796significant improvements to the performance or internals of rustc and related
2797tools.
2798
2799- [Add more weirdness to `weird-exprs.rs`.](https://github.com/rust-lang/rust/pull/119028/)
2800
2801Version 1.76.0 (2024-02-08)
2802==========================
2803
2804<a id="1.76.0-Language"></a>
2805
2806Language
2807--------
2808- [Document Rust ABI compatibility between various types](https://github.com/rust-lang/rust/pull/115476/)
2809- [Also: guarantee that char and u32 are ABI-compatible](https://github.com/rust-lang/rust/pull/118032/)
2810- [Add lint `ambiguous_wide_pointer_comparisons` that supersedes `clippy::vtable_address_comparisons`](https://github.com/rust-lang/rust/pull/117758)
2811
2812<a id="1.76.0-Compiler"></a>
2813
2814Compiler
2815--------
2816- [Lint pinned `#[must_use]` pointers (in particular, `Box<T>` where `T` is `#[must_use]`) in `unused_must_use`.](https://github.com/rust-lang/rust/pull/118054/)
2817- [Soundness fix: fix computing the offset of an unsized field in a packed struct](https://github.com/rust-lang/rust/pull/118540/)
2818- [Soundness fix: fix dynamic size/align computation logic for packed types with dyn Trait tail](https://github.com/rust-lang/rust/pull/118538/)
2819- [Add `$message_type` field to distinguish json diagnostic outputs](https://github.com/rust-lang/rust/pull/115691/)
2820- [Enable Rust to use the EHCont security feature of Windows](https://github.com/rust-lang/rust/pull/118013/)
2821- [Add tier 3 {x86_64,i686}-win7-windows-msvc targets](https://github.com/rust-lang/rust/pull/118150/)
2822- [Add tier 3 aarch64-apple-watchos target](https://github.com/rust-lang/rust/pull/119074/)
2823- [Add tier 3 arm64e-apple-ios & arm64e-apple-darwin targets](https://github.com/rust-lang/rust/pull/115526/)
2824
2825Refer to Rust's [platform support page][platform-support-doc]
2826for more information on Rust's tiered platform support.
2827
2828<a id="1.76.0-Libraries"></a>
2829
2830Libraries
2831---------
2832- [Add a column number to `dbg!()`](https://github.com/rust-lang/rust/pull/114962/)
2833- [Add `std::hash::{DefaultHasher, RandomState}` exports](https://github.com/rust-lang/rust/pull/115694/)
2834- [Fix rounding issue with exponents in fmt](https://github.com/rust-lang/rust/pull/116301/)
2835- [Add T: ?Sized to `RwLockReadGuard` and `RwLockWriteGuard`'s Debug impls.](https://github.com/rust-lang/rust/pull/117138/)
2836- [Windows: Allow `File::create` to work on hidden files](https://github.com/rust-lang/rust/pull/116438/)
2837
2838<a id="1.76.0-Stabilized-APIs"></a>
2839
2840Stabilized APIs
2841---------------
2842
2843- [`Arc::unwrap_or_clone`](https://doc.rust-lang.org/stable/std/sync/struct.Arc.html#method.unwrap_or_clone)
2844- [`Rc::unwrap_or_clone`](https://doc.rust-lang.org/stable/std/rc/struct.Rc.html#method.unwrap_or_clone)
2845- [`Result::inspect`](https://doc.rust-lang.org/stable/std/result/enum.Result.html#method.inspect)
2846- [`Result::inspect_err`](https://doc.rust-lang.org/stable/std/result/enum.Result.html#method.inspect_err)
2847- [`Option::inspect`](https://doc.rust-lang.org/stable/std/option/enum.Option.html#method.inspect)
2848- [`type_name_of_val`](https://doc.rust-lang.org/stable/std/any/fn.type_name_of_val.html)
2849- [`std::hash::{DefaultHasher, RandomState}`](https://doc.rust-lang.org/stable/std/hash/index.html#structs)
2850 These were previously available only through `std::collections::hash_map`.
2851- [`ptr::{from_ref, from_mut}`](https://doc.rust-lang.org/stable/std/ptr/fn.from_ref.html)
2852- [`ptr::addr_eq`](https://doc.rust-lang.org/stable/std/ptr/fn.addr_eq.html)
2853
2854<a id="1.76.0-Cargo"></a>
2855
2856Cargo
2857-----
2858
2859See [Cargo release notes](https://github.com/rust-lang/cargo/blob/master/CHANGELOG.md#cargo-176-2024-02-08).
2860
2861<a id="1.76.0-Rustdoc"></a>
2862
2863Rustdoc
2864-------
2865
2866- [Don't merge cfg and doc(cfg) attributes for re-exports](https://github.com/rust-lang/rust/pull/113091/)
2867- [rustdoc: allow resizing the sidebar / hiding the top bar](https://github.com/rust-lang/rust/pull/115660/)
2868- [rustdoc-search: add support for traits and associated types](https://github.com/rust-lang/rust/pull/116085/)
2869- [rustdoc: Add highlighting for comments in items declaration](https://github.com/rust-lang/rust/pull/117869/)
2870
2871<a id="1.76.0-Compatibility-Notes"></a>
2872
2873Compatibility Notes
2874-------------------
2875- [Add allow-by-default lint for unit bindings](https://github.com/rust-lang/rust/pull/112380/)
2876 This is expected to be upgraded to a warning by default in a future Rust
2877 release. Some macros emit bindings with type `()` with user-provided spans,
2878 which means that this lint will warn for user code.
2879- [Remove x86_64-sun-solaris target.](https://github.com/rust-lang/rust/pull/118091/)
2880- [Remove asmjs-unknown-emscripten target](https://github.com/rust-lang/rust/pull/117338/)
2881- [Report errors in jobserver inherited through environment variables](https://github.com/rust-lang/rust/pull/113730/)
2882 This [may warn](https://github.com/rust-lang/rust/issues/120515) on benign problems too.
2883- [Update the minimum external LLVM to 16.](https://github.com/rust-lang/rust/pull/117947/)
2884- [Improve `print_tts`](https://github.com/rust-lang/rust/pull/114571/)
2885 This change can break some naive manual parsing of token trees in proc macro
2886 code which expect a particular structure after `.to_string()`, rather than just arbitrary Rust code.
2887- [Make `IMPLIED_BOUNDS_ENTAILMENT` into a hard error from a lint](https://github.com/rust-lang/rust/pull/117984/)
2888- [Vec's allocation behavior was changed when collecting some iterators](https://github.com/rust-lang/rust/pull/110353)
2889 Allocation behavior is currently not specified, nevertheless changes can be surprising.
2890 See [`impl FromIterator for Vec`](https://doc.rust-lang.org/nightly/std/vec/struct.Vec.html#impl-FromIterator%3CT%3E-for-Vec%3CT%3E)
2891 for more details.
2892- [Properly reject `default` on free const items](https://github.com/rust-lang/rust/pull/117818/)
2893
2894Version 1.75.0 (2023-12-28)
2895==========================
2896
2897<a id="1.75.0-Language"></a>
2898
2899Language
2900--------
2901
2902- [Stabilize `async fn` and return-position `impl Trait` in traits.](https://github.com/rust-lang/rust/pull/115822/)
2903- [Allow function pointer signatures containing `&mut T` in `const` contexts.](https://github.com/rust-lang/rust/pull/116015/)
2904- [Match `usize`/`isize` exhaustively with half-open ranges.](https://github.com/rust-lang/rust/pull/116692/)
2905- [Guarantee that `char` has the same size and alignment as `u32`.](https://github.com/rust-lang/rust/pull/116894/)
2906- [Document that the null pointer has the 0 address.](https://github.com/rust-lang/rust/pull/116988/)
2907- [Allow partially moved values in `match`.](https://github.com/rust-lang/rust/pull/103208/)
2908- [Add notes about non-compliant FP behavior on 32bit x86 targets.](https://github.com/rust-lang/rust/pull/113053/)
2909- [Stabilize ratified RISC-V target features.](https://github.com/rust-lang/rust/pull/116485/)
2910
2911<a id="1.75.0-Compiler"></a>
2912
2913Compiler
2914--------
2915
2916- [Rework negative coherence to properly consider impls that only partly overlap.](https://github.com/rust-lang/rust/pull/112875/)
2917- [Bump `COINDUCTIVE_OVERLAP_IN_COHERENCE` to deny, and warn in dependencies.](https://github.com/rust-lang/rust/pull/116493/)
2918- [Consider alias bounds when computing liveness in NLL.](https://github.com/rust-lang/rust/pull/116733/)
2919- [Add the V (vector) extension to the `riscv64-linux-android` target spec.](https://github.com/rust-lang/rust/pull/116618/)
2920- [Automatically enable cross-crate inlining for small functions](https://github.com/rust-lang/rust/pull/116505)
2921- Add several new tier 3 targets:
2922 - [`csky-unknown-linux-gnuabiv2hf`](https://github.com/rust-lang/rust/pull/117049/)
2923 - [`i586-unknown-netbsd`](https://github.com/rust-lang/rust/pull/117170/)
2924 - [`mipsel-unknown-netbsd`](https://github.com/rust-lang/rust/pull/117356/)
2925
2926Refer to Rust's [platform support page][platform-support-doc]
2927for more information on Rust's tiered platform support.
2928
2929<a id="1.75.0-Libraries"></a>
2930
2931Libraries
2932---------
2933
2934- [Override `Waker::clone_from` to avoid cloning `Waker`s unnecessarily.](https://github.com/rust-lang/rust/pull/96979/)
2935- [Implement `BufRead` for `VecDeque<u8>`.](https://github.com/rust-lang/rust/pull/110604/)
2936- [Implement `FusedIterator` for `DecodeUtf16` when the inner iterator does.](https://github.com/rust-lang/rust/pull/110729/)
2937- [Implement `Not, Bit{And,Or}{,Assign}` for IP addresses.](https://github.com/rust-lang/rust/pull/113747/)
2938- [Implement `Default` for `ExitCode`.](https://github.com/rust-lang/rust/pull/114589/)
2939- [Guarantee representation of None in NPO](https://github.com/rust-lang/rust/pull/115333/)
2940- [Document when atomic loads are guaranteed read-only.](https://github.com/rust-lang/rust/pull/115577/)
2941- [Broaden the consequences of recursive TLS initialization.](https://github.com/rust-lang/rust/pull/116172/)
2942- [Windows: Support sub-millisecond sleep.](https://github.com/rust-lang/rust/pull/116461/)
2943- [Fix generic bound of `str::SplitInclusive`'s `DoubleEndedIterator` impl](https://github.com/rust-lang/rust/pull/100806/)
2944- [Fix exit status / wait status on non-Unix `cfg(unix)` platforms.](https://github.com/rust-lang/rust/pull/115108/)
2945
2946<a id="1.75.0-Stabilized-APIs"></a>
2947
2948Stabilized APIs
2949---------------
2950
2951- [`Atomic*::from_ptr`](https://doc.rust-lang.org/stable/core/sync/atomic/struct.AtomicUsize.html#method.from_ptr)
2952- [`FileTimes`](https://doc.rust-lang.org/stable/std/fs/struct.FileTimes.html)
2953- [`FileTimesExt`](https://doc.rust-lang.org/stable/std/os/windows/fs/trait.FileTimesExt.html)
2954- [`File::set_modified`](https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.set_modified)
2955- [`File::set_times`](https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.set_times)
2956- [`IpAddr::to_canonical`](https://doc.rust-lang.org/stable/core/net/enum.IpAddr.html#method.to_canonical)
2957- [`Ipv6Addr::to_canonical`](https://doc.rust-lang.org/stable/core/net/struct.Ipv6Addr.html#method.to_canonical)
2958- [`Option::as_slice`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.as_slice)
2959- [`Option::as_mut_slice`](https://doc.rust-lang.org/stable/core/option/enum.Option.html#method.as_mut_slice)
2960- [`pointer::byte_add`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.byte_add)
2961- [`pointer::byte_offset`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.byte_offset)
2962- [`pointer::byte_offset_from`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.byte_offset_from)
2963- [`pointer::byte_sub`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.byte_sub)
2964- [`pointer::wrapping_byte_add`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.wrapping_byte_add)
2965- [`pointer::wrapping_byte_offset`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.wrapping_byte_offset)
2966- [`pointer::wrapping_byte_sub`](https://doc.rust-lang.org/stable/core/primitive.pointer.html#method.wrapping_byte_sub)
2967
2968These APIs are now stable in const contexts:
2969
2970- [`Ipv6Addr::to_ipv4_mapped`](https://doc.rust-lang.org/stable/core/net/struct.Ipv6Addr.html#method.to_ipv4_mapped)
2971- [`MaybeUninit::assume_init_read`](https://doc.rust-lang.org/stable/core/mem/union.MaybeUninit.html#method.assume_init_read)
2972- [`MaybeUninit::zeroed`](https://doc.rust-lang.org/stable/core/mem/union.MaybeUninit.html#method.zeroed)
2973- [`mem::discriminant`](https://doc.rust-lang.org/stable/core/mem/fn.discriminant.html)
2974- [`mem::zeroed`](https://doc.rust-lang.org/stable/core/mem/fn.zeroed.html)
2975
2976<a id="1.75.0-Cargo"></a>
2977
2978Cargo
2979-----
2980
2981- [Add new packages to `[workspace.members]` automatically.](https://github.com/rust-lang/cargo/pull/12779/)
2982- [Allow version-less `Cargo.toml` manifests.](https://github.com/rust-lang/cargo/pull/12786/)
2983- [Make browser links out of HTML file paths.](https://github.com/rust-lang/cargo/pull/12889)
2984
2985<a id="1.75.0-Rustdoc"></a>
2986
2987Rustdoc
2988-------
2989
2990- [Accept less invalid Rust in rustdoc.](https://github.com/rust-lang/rust/pull/117450/)
2991- [Document lack of object safety on affected traits.](https://github.com/rust-lang/rust/pull/113241/)
2992- [Hide `#[repr(transparent)]` if it isn't part of the public ABI.](https://github.com/rust-lang/rust/pull/115439/)
2993- [Show enum discriminant if it is a C-like variant.](https://github.com/rust-lang/rust/pull/116142/)
2994
2995<a id="1.75.0-Compatibility-Notes"></a>
2996
2997Compatibility Notes
2998-------------------
2999
3000- [FreeBSD targets now require at least version 12.](https://github.com/rust-lang/rust/pull/114521/)
3001- [Formally demote tier 2 MIPS targets to tier 3.](https://github.com/rust-lang/rust/pull/115238/)
3002- [Make misalignment a hard error in `const` contexts.](https://github.com/rust-lang/rust/pull/115524/)
3003- [Fix detecting references to packed unsized fields.](https://github.com/rust-lang/rust/pull/115583/)
3004- [Remove support for compiler plugins.](https://github.com/rust-lang/rust/pull/116412/)
3005
3006<a id="1.75.0-Internal-Changes"></a>
3007
3008Internal Changes
3009----------------
3010
3011These changes do not affect any public interfaces of Rust, but they represent
3012significant improvements to the performance or internals of rustc and related
3013tools.
3014
3015- [Optimize `librustc_driver.so` with BOLT.](https://github.com/rust-lang/rust/pull/116352/)
3016- [Enable parallel rustc front end in dev and nightly builds.](https://github.com/rust-lang/rust/pull/117435/)
3017- [Distribute `rustc-codegen-cranelift` as rustup component on the nightly channel.](https://github.com/rust-lang/rust/pull/81746/)
3018
3019Version 1.74.1 (2023-12-07)
3020===========================
3021
3022- [Resolved spurious STATUS_ACCESS_VIOLATIONs in LLVM](https://github.com/rust-lang/rust/pull/118464)
3023- [Clarify guarantees for std::mem::discriminant](https://github.com/rust-lang/rust/pull/118006)
3024- [Fix some subtyping-related regressions](https://github.com/rust-lang/rust/pull/116415)
3025
3026Version 1.74.0 (2023-11-16)
3027==========================
3028
3029<a id="1.74.0-Language"></a>
3030
3031Language
3032--------
3033
3034- [Codify that `std::mem::Discriminant<T>` does not depend on any lifetimes in T](https://github.com/rust-lang/rust/pull/104299/)
3035- [Replace `private_in_public` lint with `private_interfaces` and `private_bounds` per RFC 2145.](https://github.com/rust-lang/rust/pull/113126/)
3036 Read more in [RFC 2145](https://rust-lang.github.io/rfcs/2145-type-privacy.html).
3037- [Allow explicit `#[repr(Rust)]`](https://github.com/rust-lang/rust/pull/114201/)
3038- [closure field capturing: don't depend on alignment of packed fields](https://github.com/rust-lang/rust/pull/115315/)
3039- [Enable MIR-based drop-tracking for `async` blocks](https://github.com/rust-lang/rust/pull/107421/)
3040- [Stabilize `impl_trait_projections`](https://github.com/rust-lang/rust/pull/115659)
3041
3042<a id="1.74.0-Compiler"></a>
3043
3044Compiler
3045--------
3046
3047- [stabilize combining +bundle and +whole-archive link modifiers](https://github.com/rust-lang/rust/pull/113301/)
3048- [Stabilize `PATH` option for `--print KIND=PATH`](https://github.com/rust-lang/rust/pull/114183/)
3049- [Enable ASAN/LSAN/TSAN for `*-apple-ios-macabi`](https://github.com/rust-lang/rust/pull/115644/)
3050- [Promote loongarch64-unknown-none* to Tier 2](https://github.com/rust-lang/rust/pull/115368/)
3051- [Add `i686-pc-windows-gnullvm` as a tier 3 target](https://github.com/rust-lang/rust/pull/115687/)
3052
3053<a id="1.74.0-Libraries"></a>
3054
3055Libraries
3056---------
3057
3058- [Implement `From<OwnedFd/Handle>` for ChildStdin/out/err](https://github.com/rust-lang/rust/pull/98704/)
3059- [Implement `From<{&,&mut} [T; N]>` for `Vec<T>` where `T: Clone`](https://github.com/rust-lang/rust/pull/111278/)
3060- [impl Step for IP addresses](https://github.com/rust-lang/rust/pull/113748/)
3061- [Implement `From<[T; N]>` for `Rc<[T]>` and `Arc<[T]>`](https://github.com/rust-lang/rust/pull/114041/)
3062- [`impl TryFrom<char> for u16`](https://github.com/rust-lang/rust/pull/114065/)
3063- [Stabilize `io_error_other` feature](https://github.com/rust-lang/rust/pull/115453/)
3064- [Stabilize the `Saturating` type](https://github.com/rust-lang/rust/pull/115477/)
3065- [Stabilize const_transmute_copy](https://github.com/rust-lang/rust/pull/115520/)
3066
3067<a id="1.74.0-Stabilized-APIs"></a>
3068
3069Stabilized APIs
3070---------------
3071
3072- [`core::num::Saturating`](https://doc.rust-lang.org/stable/std/num/struct.Saturating.html)
3073- [`impl From<io::Stdout> for std::process::Stdio`](https://doc.rust-lang.org/stable/std/process/struct.Stdio.html#impl-From%3CStdout%3E-for-Stdio)
3074- [`impl From<io::Stderr> for std::process::Stdio`](https://doc.rust-lang.org/stable/std/process/struct.Stdio.html#impl-From%3CStderr%3E-for-Stdio)
3075- [`impl From<OwnedHandle> for std::process::Child{Stdin, Stdout, Stderr}`](https://doc.rust-lang.org/stable/std/process/struct.ChildStderr.html#impl-From%3COwnedHandle%3E-for-ChildStderr)
3076- [`impl From<OwnedFd> for std::process::Child{Stdin, Stdout, Stderr}`](https://doc.rust-lang.org/stable/std/process/struct.ChildStderr.html#impl-From%3COwnedFd%3E-for-ChildStderr)
3077- [`std::ffi::OsString::from_encoded_bytes_unchecked`](https://doc.rust-lang.org/stable/std/ffi/struct.OsString.html#method.from_encoded_bytes_unchecked)
3078- [`std::ffi::OsString::into_encoded_bytes`](https://doc.rust-lang.org/stable/std/ffi/struct.OsString.html#method.into_encoded_bytes)
3079- [`std::ffi::OsStr::from_encoded_bytes_unchecked`](https://doc.rust-lang.org/stable/std/ffi/struct.OsStr.html#method.from_encoded_bytes_unchecked)
3080- [`std::ffi::OsStr::as_encoded_bytes`](https://doc.rust-lang.org/stable/std/ffi/struct.OsStr.html#method.as_encoded_bytes)
3081- [`std::io::Error::other`](https://doc.rust-lang.org/stable/std/io/struct.Error.html#method.other)
3082- [`impl TryFrom<char> for u16`](https://doc.rust-lang.org/stable/std/primitive.u16.html#impl-TryFrom%3Cchar%3E-for-u16)
3083- [`impl<T: Clone, const N: usize> From<&[T; N]> for Vec<T>`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#impl-From%3C%26%5BT;+N%5D%3E-for-Vec%3CT,+Global%3E)
3084- [`impl<T: Clone, const N: usize> From<&mut [T; N]> for Vec<T>`](https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#impl-From%3C%26mut+%5BT;+N%5D%3E-for-Vec%3CT,+Global%3E)
3085- [`impl<T, const N: usize> From<[T; N]> for Arc<[T]>`](https://doc.rust-lang.org/stable/std/sync/struct.Arc.html#impl-From%3C%5BT;+N%5D%3E-for-Arc%3C%5BT%5D,+Global%3E)
3086- [`impl<T, const N: usize> From<[T; N]> for Rc<[T]>`](https://doc.rust-lang.org/stable/std/rc/struct.Rc.html#impl-From%3C%5BT;+N%5D%3E-for-Rc%3C%5BT%5D,+Global%3E)
3087
3088These APIs are now stable in const contexts:
3089
3090- [`core::mem::transmute_copy`](https://doc.rust-lang.org/beta/std/mem/fn.transmute_copy.html)
3091- [`str::is_ascii`](https://doc.rust-lang.org/beta/std/primitive.str.html#method.is_ascii)
3092- [`[u8]::is_ascii`](https://doc.rust-lang.org/beta/std/primitive.slice.html#method.is_ascii)
3093
3094<a id="1.74.0-Cargo"></a>
3095
3096Cargo
3097-----
3098
3099- [In `Cargo.toml`, stabilize `[lints]`](https://github.com/rust-lang/cargo/pull/12648/)
3100- [Stabilize credential-process and registry-auth](https://github.com/rust-lang/cargo/pull/12649/)
3101- [Stabilize `--keep-going` build flag](https://github.com/rust-lang/cargo/pull/12568/)
3102- [Add styling to `--help` output](https://github.com/rust-lang/cargo/pull/12578/)
3103- [For `cargo clean`, add `--dry-run` flag and summary line at the end](https://github.com/rust-lang/cargo/pull/12638)
3104- [For `cargo update`, make `--package` more convenient by being positional](https://github.com/rust-lang/cargo/pull/12545/)
3105- [For `cargo update`, clarify meaning of --aggressive as --recursive](https://github.com/rust-lang/cargo/pull/12544/)
3106- [Add '-n' as an alias for `--dry-run`](https://github.com/rust-lang/cargo/pull/12660/)
3107- [Allow version-prefixes in pkgid's (e.g. `--package` flags) to resolve ambiguities](https://github.com/rust-lang/cargo/pull/12614/)
3108- [In `.cargo/config.toml`, merge lists in precedence order](https://github.com/rust-lang/cargo/pull/12515/)
3109- [Add support for `target.'cfg(..)'.linker`](https://github.com/rust-lang/cargo/pull/12535/)
3110
3111<a id="1.74.0-Rustdoc"></a>
3112
3113Rustdoc
3114-------
3115
3116- [Add warning block support in rustdoc](https://github.com/rust-lang/rust/pull/106561/)
3117- [rustdoc-search: add support for type parameters](https://github.com/rust-lang/rust/pull/112725/)
3118- [rustdoc: show inner enum and struct in type definition for concrete type](https://github.com/rust-lang/rust/pull/114855/)
3119
3120<a id="1.74.0-Compatibility-Notes"></a>
3121
3122Compatibility Notes
3123-------------------
3124
3125- [Raise minimum supported Apple OS versions](https://github.com/rust-lang/rust/pull/104385/)
3126- [make Cell::swap panic if the Cells partially overlap](https://github.com/rust-lang/rust/pull/114795/)
3127- [Reject invalid crate names in `--extern`](https://github.com/rust-lang/rust/pull/116001/)
3128- [Don't resolve generic impls that may be shadowed by dyn built-in impls](https://github.com/rust-lang/rust/pull/114941/)
3129- [The new `impl From<{&,&mut} [T; N]> for Vec<T>` is known to cause some inference failures with overly-generic code.](https://github.com/rust-lang/rust/issues/117054) In those examples using the `tui` crate, the combination of `AsRef<_>` and `Into<Vec>` leaves the middle type ambiguous, and the new `impl` adds another possibility, so it now requires an explicit type annotation.
3130
3131<a id="1.74.0-Internal-Changes"></a>
3132
3133Internal Changes
3134----------------
3135
3136These changes do not affect any public interfaces of Rust, but they represent
3137significant improvements to the performance or internals of rustc and related
3138tools.
3139
3140None this cycle.
3141
3142Version 1.73.0 (2023-10-05)
3143==========================
3144
3145<a id="1.73.0-Language"></a>
3146
3147Language
3148--------
3149
3150- [Uplift `clippy::fn_null_check` lint as `useless_ptr_null_checks`.](https://github.com/rust-lang/rust/pull/111717/)
3151- [Make `noop_method_call` warn by default.](https://github.com/rust-lang/rust/pull/111916/)
3152- [Support interpolated block for `try` and `async` in macros.](https://github.com/rust-lang/rust/pull/112953/)
3153- [Make `unconditional_recursion` lint detect recursive drops.](https://github.com/rust-lang/rust/pull/113902/)
3154- [Future compatibility warning for some impls being incorrectly considered not overlapping.](https://github.com/rust-lang/rust/pull/114023/)
3155- [The `invalid_reference_casting` lint is now **deny-by-default** (instead of allow-by-default)](https://github.com/rust-lang/rust/pull/112431)
3156
3157<a id="1.73.0-Compiler"></a>
3158
3159Compiler
3160--------
3161
3162- [Write version information in a `.comment` section like GCC/Clang.](https://github.com/rust-lang/rust/pull/97550/)
3163- [Add documentation on v0 symbol mangling.](https://github.com/rust-lang/rust/pull/97571/)
3164- [Stabilize `extern "thiscall"` and `"thiscall-unwind"` ABIs.](https://github.com/rust-lang/rust/pull/114562/)
3165- [Only check outlives goals on impl compared to trait.](https://github.com/rust-lang/rust/pull/109356/)
3166- [Infer type in irrefutable slice patterns with fixed length as array.](https://github.com/rust-lang/rust/pull/113199/)
3167- [Discard default auto trait impls if explicit ones exist.](https://github.com/rust-lang/rust/pull/113312/)
3168- Add several new tier 3 targets:
3169 - [`aarch64-unknown-teeos`](https://github.com/rust-lang/rust/pull/113480/)
3170 - [`csky-unknown-linux-gnuabiv2`](https://github.com/rust-lang/rust/pull/113658/)
3171 - [`riscv64-linux-android`](https://github.com/rust-lang/rust/pull/112858/)
3172 - [`riscv64gc-unknown-hermit`](https://github.com/rust-lang/rust/pull/114004/)
3173 - [`x86_64-unikraft-linux-musl`](https://github.com/rust-lang/rust/pull/113411/)
3174 - [`x86_64-unknown-linux-ohos`](https://github.com/rust-lang/rust/pull/113061/)
3175- [Add `wasm32-wasi-preview1-threads` as a tier 2 target.](https://github.com/rust-lang/rust/pull/112922/)
3176
3177Refer to Rust's [platform support page][platform-support-doc]
3178for more information on Rust's tiered platform support.
3179
3180<a id="1.73.0-Libraries"></a>
3181
3182Libraries
3183---------
3184
3185- [Add `Read`, `Write` and `Seek` impls for `Arc<File>`.](https://github.com/rust-lang/rust/pull/94748/)
3186- [Merge functionality of `io::Sink` into `io::Empty`.](https://github.com/rust-lang/rust/pull/98154/)
3187- [Implement `RefUnwindSafe` for `Backtrace`](https://github.com/rust-lang/rust/pull/100455/)
3188- [Make `ExitStatus` implement `Default`](https://github.com/rust-lang/rust/pull/106425/)
3189- [`impl SliceIndex<str> for (Bound<usize>, Bound<usize>)`](https://github.com/rust-lang/rust/pull/111081/)
3190- [Change default panic handler message format.](https://github.com/rust-lang/rust/pull/112849/)
3191- [Cleaner `assert_eq!` & `assert_ne!` panic messages.](https://github.com/rust-lang/rust/pull/111071/)
3192- [Correct the (deprecated) Android `stat` struct definitions.](https://github.com/rust-lang/rust/pull/113130/)
3193
3194<a id="1.73.0-Stabilized-APIs"></a>
3195
3196Stabilized APIs
3197---------------
3198
3199- [Unsigned `{integer}::div_ceil`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.div_ceil)
3200- [Unsigned `{integer}::next_multiple_of`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.next_multiple_of)
3201- [Unsigned `{integer}::checked_next_multiple_of`](https://doc.rust-lang.org/stable/std/primitive.u32.html#method.checked_next_multiple_of)
3202- [`std::ffi::FromBytesUntilNulError`](https://doc.rust-lang.org/stable/std/ffi/struct.FromBytesUntilNulError.html)
3203- [`std::os::unix::fs::chown`](https://doc.rust-lang.org/stable/std/os/unix/fs/fn.chown.html)
3204- [`std::os::unix::fs::fchown`](https://doc.rust-lang.org/stable/std/os/unix/fs/fn.fchown.html)
3205- [`std::os::unix::fs::lchown`](https://doc.rust-lang.org/stable/std/os/unix/fs/fn.lchown.html)
3206- [`LocalKey::<Cell<T>>::get`](https://doc.rust-lang.org/stable/std/thread/struct.LocalKey.html#method.get)
3207- [`LocalKey::<Cell<T>>::set`](https://doc.rust-lang.org/stable/std/thread/struct.LocalKey.html#method.set)
3208- [`LocalKey::<Cell<T>>::take`](https://doc.rust-lang.org/stable/std/thread/struct.LocalKey.html#method.take)
3209- [`LocalKey::<Cell<T>>::replace`](https://doc.rust-lang.org/stable/std/thread/struct.LocalKey.html#method.replace)
3210- [`LocalKey::<RefCell<T>>::with_borrow`](https://doc.rust-lang.org/stable/std/thread/struct.LocalKey.html#method.with_borrow)
3211- [`LocalKey::<RefCell<T>>::with_borrow_mut`](https://doc.rust-lang.org/stable/std/thread/struct.LocalKey.html#method.with_borrow_mut)
3212- [`LocalKey::<RefCell<T>>::set`](https://doc.rust-lang.org/stable/std/thread/struct.LocalKey.html#method.set-1)
3213- [`LocalKey::<RefCell<T>>::take`](https://doc.rust-lang.org/stable/std/thread/struct.LocalKey.html#method.take-1)
3214- [`LocalKey::<RefCell<T>>::replace`](https://doc.rust-lang.org/stable/std/thread/struct.LocalKey.html#method.replace-1)
3215
3216These APIs are now stable in const contexts:
3217
3218- [`rc::Weak::new`](https://doc.rust-lang.org/stable/alloc/rc/struct.Weak.html#method.new)
3219- [`sync::Weak::new`](https://doc.rust-lang.org/stable/alloc/sync/struct.Weak.html#method.new)
3220- [`NonNull::as_ref`](https://doc.rust-lang.org/stable/core/ptr/struct.NonNull.html#method.as_ref)
3221
3222<a id="1.73.0-Cargo"></a>
3223
3224Cargo
3225-----
3226
3227- [Bail out an error when using `cargo::` in custom build script.](https://github.com/rust-lang/cargo/pull/12332/)
3228
3229<a id="1.73.0-Misc"></a>
3230
3231Misc
3232----
3233
3234<a id="1.73.0-Compatibility-Notes"></a>
3235
3236Compatibility Notes
3237-------------------
3238
3239- [Update the minimum external LLVM to 15.](https://github.com/rust-lang/rust/pull/114148/)
3240- [Check for non-defining uses of return position `impl Trait`.](https://github.com/rust-lang/rust/pull/112842/)
3241
3242<a id="1.73.0-Internal-Changes"></a>
3243
3244Internal Changes
3245----------------
3246
3247These changes do not affect any public interfaces of Rust, but they represent
3248significant improvements to the performance or internals of rustc and related
3249tools.
3250
3251- [Remove LLVM pointee types, supporting only opaque pointers.](https://github.com/rust-lang/rust/pull/105545/)
3252- [Port PGO/LTO/BOLT optimized build pipeline to Rust.](https://github.com/rust-lang/rust/pull/112235/)
3253- [Replace in-tree `rustc_apfloat` with the new version of the crate.](https://github.com/rust-lang/rust/pull/113843/)
3254- [Update to LLVM 17.](https://github.com/rust-lang/rust/pull/114048/)
3255- [Add `internal_features` lint for internal unstable features.](https://github.com/rust-lang/rust/pull/108955/)
3256- [Mention style for new syntax in tracking issue template.](https://github.com/rust-lang/rust/pull/113586/)
3257
3258Version 1.72.1 (2023-09-19)
3259===========================
3260
3261- [Adjust codegen change to improve LLVM codegen](https://github.com/rust-lang/rust/pull/115236)
3262- [rustdoc: Fix self ty params in objects with lifetimes](https://github.com/rust-lang/rust/pull/115276)
3263- [Fix regression in compile times](https://github.com/rust-lang/rust/pull/114948)
3264- Resolve some ICE regressions in the compiler:
3265 - [#115215](https://github.com/rust-lang/rust/pull/115215)
3266 - [#115559](https://github.com/rust-lang/rust/pull/115559)
3267
3268Version 1.72.0 (2023-08-24)
3269==========================
3270
3271<a id="1.72.0-Language"></a>
3272
3273Language
3274--------
3275
3276- [Replace const eval limit by a lint and add an exponential backoff warning](https://github.com/rust-lang/rust/pull/103877/)
3277- [expand: Change how `#![cfg(FALSE)]` behaves on crate root](https://github.com/rust-lang/rust/pull/110141/)
3278- [Stabilize inline asm for LoongArch64](https://github.com/rust-lang/rust/pull/111235/)
3279- [Uplift `clippy::undropped_manually_drops` lint](https://github.com/rust-lang/rust/pull/111530/)
3280- [Uplift `clippy::invalid_utf8_in_unchecked` lint](https://github.com/rust-lang/rust/pull/111543/) as `invalid_from_utf8_unchecked` and `invalid_from_utf8`
3281- [Uplift `clippy::cast_ref_to_mut` lint](https://github.com/rust-lang/rust/pull/111567/) as `invalid_reference_casting`
3282- [Uplift `clippy::cmp_nan` lint](https://github.com/rust-lang/rust/pull/111818/) as `invalid_nan_comparisons`
3283- [resolve: Remove artificial import ambiguity errors](https://github.com/rust-lang/rust/pull/112086/)
3284- [Don't require associated types with Self: Sized bounds in `dyn Trait` objects](https://github.com/rust-lang/rust/pull/112319/)
3285
3286<a id="1.72.0-Compiler"></a>
3287
3288Compiler
3289--------
3290
3291- [Remember names of `cfg`-ed out items to mention them in diagnostics](https://github.com/rust-lang/rust/pull/109005/)
3292- [Support for native WASM exceptions](https://github.com/rust-lang/rust/pull/111322/)
3293- [Add support for NetBSD/aarch64-be (big-endian arm64).](https://github.com/rust-lang/rust/pull/111326/)
3294- [Write to stdout if `-` is given as output file](https://github.com/rust-lang/rust/pull/111626/)
3295- [Force all native libraries to be statically linked when linking a static binary](https://github.com/rust-lang/rust/pull/111698/)
3296- [Add Tier 3 support for `loongarch64-unknown-none*`](https://github.com/rust-lang/rust/pull/112310/)
3297- [Prevent `.eh_frame` from being emitted for `-C panic=abort`](https://github.com/rust-lang/rust/pull/112403/)
3298- [Support 128-bit enum variant in debuginfo codegen](https://github.com/rust-lang/rust/pull/112474/)
3299- [compiler: update solaris/illumos to enable tsan support.](https://github.com/rust-lang/rust/pull/112039/)
3300
3301Refer to Rust's [platform support page][platform-support-doc]
3302for more information on Rust's tiered platform support.
3303
3304<a id="1.72.0-Libraries"></a>
3305
3306Libraries
3307---------
3308
3309- [Document memory orderings of `thread::{park, unpark}`](https://github.com/rust-lang/rust/pull/99587/)
3310- [io: soften ‘at most one write attempt’ requirement in io::Write::write](https://github.com/rust-lang/rust/pull/107200/)
3311- [Specify behavior of HashSet::insert](https://github.com/rust-lang/rust/pull/107619/)
3312- [Relax implicit `T: Sized` bounds on `BufReader<T>`, `BufWriter<T>` and `LineWriter<T>`](https://github.com/rust-lang/rust/pull/111074/)
3313- [Update runtime guarantee for `select_nth_unstable`](https://github.com/rust-lang/rust/pull/111974/)
3314- [Return `Ok` on kill if process has already exited](https://github.com/rust-lang/rust/pull/112594/)
3315- [Implement PartialOrd for `Vec`s over different allocators](https://github.com/rust-lang/rust/pull/112632/)
3316- [Use 128 bits for TypeId hash](https://github.com/rust-lang/rust/pull/109953/)
3317- [Don't drain-on-drop in DrainFilter impls of various collections.](https://github.com/rust-lang/rust/pull/104455/)
3318- [Make `{Arc,Rc,Weak}::ptr_eq` ignore pointer metadata](https://github.com/rust-lang/rust/pull/106450/)
3319
3320<a id="1.72.0-Rustdoc"></a>
3321
3322Rustdoc
3323-------
3324
3325- [Allow whitespace as path separator like double colon](https://github.com/rust-lang/rust/pull/108537/)
3326- [Add search result item types after their name](https://github.com/rust-lang/rust/pull/110688/)
3327- [Search for slices and arrays by type with `[]`](https://github.com/rust-lang/rust/pull/111958/)
3328- [Clean up type unification and "unboxing"](https://github.com/rust-lang/rust/pull/112233/)
3329
3330<a id="1.72.0-Stabilized-APIs"></a>
3331
3332Stabilized APIs
3333---------------
3334
3335- [`impl<T: Send> Sync for mpsc::Sender<T>`](https://doc.rust-lang.org/stable/std/sync/mpsc/struct.Sender.html#impl-Sync-for-Sender%3CT%3E)
3336- [`impl TryFrom<&OsStr> for &str`](https://doc.rust-lang.org/stable/std/primitive.str.html#impl-TryFrom%3C%26'a+OsStr%3E-for-%26'a+str)
3337- [`String::leak`](https://doc.rust-lang.org/stable/alloc/string/struct.String.html#method.leak)
3338
3339These APIs are now stable in const contexts:
3340
3341- [`CStr::from_bytes_with_nul`](https://doc.rust-lang.org/stable/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
3342- [`CStr::to_bytes`](https://doc.rust-lang.org/stable/std/ffi/struct.CStr.html#method.to_bytes)
3343- [`CStr::to_bytes_with_nul`](https://doc.rust-lang.org/stable/std/ffi/struct.CStr.html#method.to_bytes_with_nul)
3344- [`CStr::to_str`](https://doc.rust-lang.org/stable/std/ffi/struct.CStr.html#method.to_str)
3345
3346<a id="1.72.0-Cargo"></a>
3347
3348Cargo
3349-----
3350
3351- Enable `-Zdoctest-in-workspace` by default. When running each documentation
3352 test, the working directory is set to the root directory of the package the
3353 test belongs to.
3354 [docs](https://doc.rust-lang.org/nightly/cargo/commands/cargo-test.html#working-directory-of-tests)
3355 [#12221](https://github.com/rust-lang/cargo/pull/12221)
3356 [#12288](https://github.com/rust-lang/cargo/pull/12288)
3357- Add support of the "default" keyword to reset previously set `build.jobs`
3358 parallelism back to the default.
3359 [#12222](https://github.com/rust-lang/cargo/pull/12222)
3360
3361<a id="1.72.0-Compatibility-Notes"></a>
3362
3363Compatibility Notes
3364-------------------
3365
3366- [Alter `Display` for `Ipv6Addr` for IPv4-compatible addresses](https://github.com/rust-lang/rust/pull/112606/)
3367- Cargo changed feature name validation check to a hard error. The warning was
3368 added in Rust 1.49. These extended characters aren't allowed on crates.io, so
3369 this should only impact users of other registries, or people who don't publish
3370 to a registry.
3371 [#12291](https://github.com/rust-lang/cargo/pull/12291)
3372- [Demoted `mips*-unknown-linux-gnu*` targets from host tier 2 to target tier 3 support.](https://github.com/rust-lang/rust/pull/113274)
3373
3374Version 1.71.1 (2023-08-03)
3375===========================
3376
3377- [Fix CVE-2023-38497: Cargo did not respect the umask when extracting dependencies](https://github.com/rust-lang/cargo/security/advisories/GHSA-j3xp-wfr4-hx87)
3378- [Fix bash completion for users of Rustup](https://github.com/rust-lang/rust/pull/113579)
3379- [Do not show `suspicious_double_ref_op` lint when calling `borrow()`](https://github.com/rust-lang/rust/pull/112517)
3380- [Fix ICE: substitute types before checking inlining compatibility](https://github.com/rust-lang/rust/pull/113802)
3381- [Fix ICE: don't use `can_eq` in `derive(..)` suggestion for missing method](https://github.com/rust-lang/rust/pull/111516)
3382- [Fix building Rust 1.71.0 from the source tarball](https://github.com/rust-lang/rust/issues/113678)
3383
3384Version 1.71.0 (2023-07-13)
3385==========================
3386
3387<a id="1.71.0-Language"></a>
3388
3389Language
3390--------
3391
3392- [Stabilize `raw-dylib`, `link_ordinal`, `import_name_type` and `-Cdlltool`.](https://github.com/rust-lang/rust/pull/109677/)
3393- [Uplift `clippy::{drop,forget}_{ref,copy}` lints.](https://github.com/rust-lang/rust/pull/109732/)
3394- [Type inference is more conservative around constrained vars.](https://github.com/rust-lang/rust/pull/110100/)
3395- [Use fulfillment to check `Drop` impl compatibility](https://github.com/rust-lang/rust/pull/110577/)
3396
3397<a id="1.71.0-Compiler"></a>
3398
3399Compiler
3400--------
3401
3402- [Evaluate place expression in `PlaceMention`](https://github.com/rust-lang/rust/pull/104844/),
3403 making `let _ =` patterns more consistent with respect to the borrow checker.
3404- [Add `--print deployment-target` flag for Apple targets.](https://github.com/rust-lang/rust/pull/105354/)
3405- [Stabilize `extern "C-unwind"` and friends.](https://github.com/rust-lang/rust/pull/106075/)
3406 The existing `extern "C"` etc. may change behavior for cross-language unwinding in a future release.
3407- [Update the version of musl used on `*-linux-musl` targets to 1.2.3](https://github.com/rust-lang/rust/pull/107129/),
3408 enabling [time64](https://musl.libc.org/time64.html) on 32-bit systems.
3409- [Stabilize `debugger_visualizer`](https://github.com/rust-lang/rust/pull/108668/)
3410 for embedding metadata like Microsoft's Natvis.
3411- [Enable flatten-format-args by default.](https://github.com/rust-lang/rust/pull/109999/)
3412- [Make `Self` respect tuple constructor privacy.](https://github.com/rust-lang/rust/pull/111245/)
3413- [Improve niche placement by trying two strategies and picking the better result.](https://github.com/rust-lang/rust/pull/108106/)
3414- [Use `apple-m1` as the target CPU for `aarch64-apple-darwin`.](https://github.com/rust-lang/rust/pull/109899/)
3415- [Add Tier 3 support for the `x86_64h-apple-darwin` target.](https://github.com/rust-lang/rust/pull/108795/)
3416- [Promote `loongarch64-unknown-linux-gnu` to Tier 2 with host tools.](https://github.com/rust-lang/rust/pull/110936/)
3417
3418Refer to Rust's [platform support page][platform-support-doc]
3419for more information on Rust's tiered platform support.
3420
3421<a id="1.71.0-Libraries"></a>
3422
3423Libraries
3424---------
3425- [Rework handling of recursive panics.](https://github.com/rust-lang/rust/pull/110975/)
3426 Additional panics are allowed while unwinding, as long as they are caught before escaping
3427 a `Drop` implementation, but panicking within a panic hook is now an immediate abort.
3428- [Loosen `From<&[T]> for Box<[T]>` bound to `T: Clone`.](https://github.com/rust-lang/rust/pull/103406/)
3429- [Remove unnecessary `T: Send` bound](https://github.com/rust-lang/rust/pull/111134/)
3430 in `Error for mpsc::SendError<T>` and `TrySendError<T>`.
3431- [Fix docs for `alloc::realloc`](https://github.com/rust-lang/rust/pull/108630/)
3432 to match `Layout` requirements that the size must not exceed `isize::MAX`.
3433- [Document `const {}` syntax for `std::thread_local`.](https://github.com/rust-lang/rust/pull/110620/)
3434 This syntax was stabilized in Rust 1.59, but not previously mentioned in release notes.
3435
3436<a id="1.71.0-Stabilized-APIs"></a>
3437
3438Stabilized APIs
3439---------------
3440
3441- [`CStr::is_empty`](https://doc.rust-lang.org/stable/std/ffi/struct.CStr.html#method.is_empty)
3442- [`BuildHasher::hash_one`](https://doc.rust-lang.org/stable/std/hash/trait.BuildHasher.html#method.hash_one)
3443- [`NonZeroI*::is_positive`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroI32.html#method.is_positive)
3444- [`NonZeroI*::is_negative`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroI32.html#method.is_negative)
3445- [`NonZeroI*::checked_neg`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroI32.html#method.checked_neg)
3446- [`NonZeroI*::overflowing_neg`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroI32.html#method.overflowing_neg)
3447- [`NonZeroI*::saturating_neg`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroI32.html#method.saturating_neg)
3448- [`NonZeroI*::wrapping_neg`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroI32.html#method.wrapping_neg)
3449- [`Neg for NonZeroI*`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroI32.html#impl-Neg-for-NonZeroI32)
3450- [`Neg for &NonZeroI*`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroI32.html#impl-Neg-for-%26NonZeroI32)
3451- [`From<[T; N]> for (T...)`](https://doc.rust-lang.org/stable/std/primitive.array.html#impl-From%3C%5BT;+1%5D%3E-for-(T,))
3452 (array to N-tuple for N in 1..=12)
3453- [`From<(T...)> for [T; N]`](https://doc.rust-lang.org/stable/std/primitive.array.html#impl-From%3C(T,)%3E-for-%5BT;+1%5D)
3454 (N-tuple to array for N in 1..=12)
3455- [`windows::io::AsHandle for Box<T>`](https://doc.rust-lang.org/stable/std/os/windows/io/trait.AsHandle.html#impl-AsHandle-for-Box%3CT%3E)
3456- [`windows::io::AsHandle for Rc<T>`](https://doc.rust-lang.org/stable/std/os/windows/io/trait.AsHandle.html#impl-AsHandle-for-Rc%3CT%3E)
3457- [`windows::io::AsHandle for Arc<T>`](https://doc.rust-lang.org/stable/std/os/windows/io/trait.AsHandle.html#impl-AsHandle-for-Arc%3CT%3E)
3458- [`windows::io::AsSocket for Box<T>`](https://doc.rust-lang.org/stable/std/os/windows/io/trait.AsSocket.html#impl-AsSocket-for-Box%3CT%3E)
3459- [`windows::io::AsSocket for Rc<T>`](https://doc.rust-lang.org/stable/std/os/windows/io/trait.AsSocket.html#impl-AsSocket-for-Rc%3CT%3E)
3460- [`windows::io::AsSocket for Arc<T>`](https://doc.rust-lang.org/stable/std/os/windows/io/trait.AsSocket.html#impl-AsSocket-for-Arc%3CT%3E)
3461
3462These APIs are now stable in const contexts:
3463
3464- [`<*const T>::read`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.read)
3465- [`<*const T>::read_unaligned`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.read_unaligned)
3466- [`<*mut T>::read`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.read-1)
3467- [`<*mut T>::read_unaligned`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.read_unaligned-1)
3468- [`ptr::read`](https://doc.rust-lang.org/stable/std/ptr/fn.read.html)
3469- [`ptr::read_unaligned`](https://doc.rust-lang.org/stable/std/ptr/fn.read_unaligned.html)
3470- [`<[T]>::split_at`](https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_at)
3471
3472<a id="1.71.0-Cargo"></a>
3473
3474Cargo
3475-----
3476- [Allow named debuginfo options in `Cargo.toml`.](https://github.com/rust-lang/cargo/pull/11958/)
3477- [Add `workspace_default_members` to the output of `cargo metadata`.](https://github.com/rust-lang/cargo/pull/11978/)
3478- [Automatically inherit workspace fields when running `cargo new`/`cargo init`.](https://github.com/rust-lang/cargo/pull/12069/)
3479
3480<a id="1.71.0-Rustdoc"></a>
3481
3482Rustdoc
3483-------
3484
3485- [Add a new `rustdoc::unescaped_backticks` lint for broken inline code.](https://github.com/rust-lang/rust/pull/105848/)
3486- [Support strikethrough with single tildes.](https://github.com/rust-lang/rust/pull/111152/) (`~~old~~` vs. `~new~`)
3487
3488<a id="1.71.0-Misc"></a>
3489
3490Misc
3491----
3492
3493<a id="1.71.0-Compatibility-Notes"></a>
3494
3495Compatibility Notes
3496-------------------
3497
3498- [Remove structural match from `TypeId`.](https://github.com/rust-lang/rust/pull/103291/)
3499 Code that uses a constant `TypeId` in a pattern will potentially be broken.
3500 Known cases have already been fixed -- in particular, users of the `log`
3501 crate's `kv_unstable` feature should update to `log v0.4.18` or later.
3502- [Add a `sysroot` crate to represent the standard library crates.](https://github.com/rust-lang/rust/pull/108865/)
3503 This does not affect stable users, but may require adjustment in tools that build their own standard library.
3504- [Cargo optimizes its usage under `rustup`.](https://github.com/rust-lang/cargo/pull/11917/) When
3505 Cargo detects it will run `rustc` pointing to a rustup proxy, it'll try bypassing the proxy and
3506 use the underlying binary directly. There are assumptions around the interaction with rustup and
3507 `RUSTUP_TOOLCHAIN`. However, it's not expected to affect normal users.
3508- [When querying a package, Cargo tries only the original name, all hyphens, and all underscores to
3509 handle misspellings.](https://github.com/rust-lang/cargo/pull/12083/) Previously, Cargo tried each
3510 combination of hyphens and underscores, causing excessive requests to crates.io.
3511- Cargo now [disallows `RUSTUP_HOME`](https://github.com/rust-lang/cargo/pull/12101/) and
3512 [`RUSTUP_TOOLCHAIN`](https://github.com/rust-lang/cargo/pull/12107/) in the `[env]` configuration
3513 table. This is considered to be not a use case Cargo would like to support, since it will likely
3514 cause problems or lead to confusion.
3515
3516<a id="1.71.0-Internal-Changes"></a>
3517
3518Internal Changes
3519----------------
3520
3521These changes do not affect any public interfaces of Rust, but they represent
3522significant improvements to the performance or internals of rustc and related
3523tools.
3524
3525
3526Version 1.70.0 (2023-06-01)
3527==========================
3528
3529<a id="1.70.0-Language"></a>
3530
3531Language
3532--------
3533- [Relax ordering rules for `asm!` operands](https://github.com/rust-lang/rust/pull/105798/)
3534- [Properly allow macro expanded `format_args` invocations to uses captures](https://github.com/rust-lang/rust/pull/106505/)
3535- [Lint ambiguous glob re-exports](https://github.com/rust-lang/rust/pull/107880/)
3536- [Perform const and unsafe checking for expressions in `let _ = expr` position.](https://github.com/rust-lang/rust/pull/102256/)
3537
3538<a id="1.70.0-Compiler"></a>
3539
3540Compiler
3541--------
3542- [Extend -Cdebuginfo with new options and named aliases](https://github.com/rust-lang/rust/pull/109808/)
3543 This provides a smaller version of debuginfo for cases that only need line number information
3544 (`-Cdebuginfo=line-tables-only`), which may eventually become the default for `-Cdebuginfo=1`.
3545- [Make `unused_allocation` lint against `Box::new` too](https://github.com/rust-lang/rust/pull/104363/)
3546- [Detect uninhabited types early in const eval](https://github.com/rust-lang/rust/pull/109435/)
3547- [Switch to LLD as default linker for {arm,thumb}v4t-none-eabi](https://github.com/rust-lang/rust/pull/109721/)
3548- [Add tier 3 target `loongarch64-unknown-linux-gnu`](https://github.com/rust-lang/rust/pull/96971)
3549- [Add tier 3 target for `i586-pc-nto-qnx700` (QNX Neutrino RTOS, version 7.0)](https://github.com/rust-lang/rust/pull/109173/),
3550- [Insert alignment checks for pointer dereferences as debug assertions](https://github.com/rust-lang/rust/pull/98112)
3551 This catches undefined behavior at runtime, and may cause existing code to fail.
3552
3553Refer to Rust's [platform support page][platform-support-doc]
3554for more information on Rust's tiered platform support.
3555
3556<a id="1.70.0-Libraries"></a>
3557
3558Libraries
3559---------
3560- [Document NonZeroXxx layout guarantees](https://github.com/rust-lang/rust/pull/94786/)
3561- [Windows: make `Command` prefer non-verbatim paths](https://github.com/rust-lang/rust/pull/96391/)
3562- [Implement Default for some alloc/core iterators](https://github.com/rust-lang/rust/pull/99929/)
3563- [Fix handling of trailing bare CR in str::lines](https://github.com/rust-lang/rust/pull/100311/)
3564- [allow negative numeric literals in `concat!`](https://github.com/rust-lang/rust/pull/106844/)
3565- [Add documentation about the memory layout of `Cell`](https://github.com/rust-lang/rust/pull/106921/)
3566- [Use `partial_cmp` to implement tuple `lt`/`le`/`ge`/`gt`](https://github.com/rust-lang/rust/pull/108157/)
3567- [Stabilize `atomic_as_ptr`](https://github.com/rust-lang/rust/pull/108419/)
3568- [Stabilize `nonnull_slice_from_raw_parts`](https://github.com/rust-lang/rust/pull/97506/)
3569- [Partial stabilization of `once_cell`](https://github.com/rust-lang/rust/pull/105587/)
3570- [Stabilize `nonzero_min_max`](https://github.com/rust-lang/rust/pull/106633/)
3571- [Flatten/inline format_args!() and (string and int) literal arguments into format_args!()](https://github.com/rust-lang/rust/pull/106824/)
3572- [Stabilize movbe target feature](https://github.com/rust-lang/rust/pull/107711/)
3573- [don't splice from files into pipes in io::copy](https://github.com/rust-lang/rust/pull/108283/)
3574- [Add a builtin unstable `FnPtr` trait that is implemented for all function pointers](https://github.com/rust-lang/rust/pull/108080/)
3575 This extends `Debug`, `Pointer`, `Hash`, `PartialEq`, `Eq`, `PartialOrd`, and `Ord`
3576 implementations for function pointers with all ABIs.
3577
3578<a id="1.70.0-Stabilized-APIs"></a>
3579
3580Stabilized APIs
3581---------------
3582
3583- [`NonZero*::MIN/MAX`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroI8.html#associatedconstant.MIN)
3584- [`BinaryHeap::retain`](https://doc.rust-lang.org/stable/std/collections/struct.BinaryHeap.html#method.retain)
3585- [`Default for std::collections::binary_heap::IntoIter`](https://doc.rust-lang.org/stable/std/collections/binary_heap/struct.IntoIter.html)
3586- [`Default for std::collections::btree_map::{IntoIter, Iter, IterMut}`](https://doc.rust-lang.org/stable/std/collections/btree_map/struct.IntoIter.html)
3587- [`Default for std::collections::btree_map::{IntoKeys, Keys}`](https://doc.rust-lang.org/stable/std/collections/btree_map/struct.IntoKeys.html)
3588- [`Default for std::collections::btree_map::{IntoValues, Values}`](https://doc.rust-lang.org/stable/std/collections/btree_map/struct.IntoValues.html)
3589- [`Default for std::collections::btree_map::Range`](https://doc.rust-lang.org/stable/std/collections/btree_map/struct.Range.html)
3590- [`Default for std::collections::btree_set::{IntoIter, Iter}`](https://doc.rust-lang.org/stable/std/collections/btree_set/struct.IntoIter.html)
3591- [`Default for std::collections::btree_set::Range`](https://doc.rust-lang.org/stable/std/collections/btree_set/struct.Range.html)
3592- [`Default for std::collections::linked_list::{IntoIter, Iter, IterMut}`](https://doc.rust-lang.org/stable/alloc/collections/linked_list/struct.IntoIter.html)
3593- [`Default for std::vec::IntoIter`](https://doc.rust-lang.org/stable/alloc/vec/struct.IntoIter.html#impl-Default-for-IntoIter%3CT,+A%3E)
3594- [`Default for std::iter::Chain`](https://doc.rust-lang.org/stable/std/iter/struct.Chain.html)
3595- [`Default for std::iter::Cloned`](https://doc.rust-lang.org/stable/std/iter/struct.Cloned.html)
3596- [`Default for std::iter::Copied`](https://doc.rust-lang.org/stable/std/iter/struct.Copied.html)
3597- [`Default for std::iter::Enumerate`](https://doc.rust-lang.org/stable/std/iter/struct.Enumerate.html)
3598- [`Default for std::iter::Flatten`](https://doc.rust-lang.org/stable/std/iter/struct.Flatten.html)
3599- [`Default for std::iter::Fuse`](https://doc.rust-lang.org/stable/std/iter/struct.Fuse.html)
3600- [`Default for std::iter::Rev`](https://doc.rust-lang.org/stable/std/iter/struct.Rev.html)
3601- [`Default for std::slice::Iter`](https://doc.rust-lang.org/stable/std/slice/struct.Iter.html)
3602- [`Default for std::slice::IterMut`](https://doc.rust-lang.org/stable/std/slice/struct.IterMut.html)
3603- [`Rc::into_inner`](https://doc.rust-lang.org/stable/alloc/rc/struct.Rc.html#method.into_inner)
3604- [`Arc::into_inner`](https://doc.rust-lang.org/stable/alloc/sync/struct.Arc.html#method.into_inner)
3605- [`std::cell::OnceCell`](https://doc.rust-lang.org/stable/std/cell/struct.OnceCell.html)
3606- [`Option::is_some_and`](https://doc.rust-lang.org/stable/std/option/enum.Option.html#method.is_some_and)
3607- [`NonNull::slice_from_raw_parts`](https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.slice_from_raw_parts)
3608- [`Result::is_ok_and`](https://doc.rust-lang.org/stable/std/result/enum.Result.html#method.is_ok_and)
3609- [`Result::is_err_and`](https://doc.rust-lang.org/stable/std/result/enum.Result.html#method.is_err_and)
3610- [`std::sync::atomic::Atomic*::as_ptr`](https://doc.rust-lang.org/stable/std/sync/atomic/struct.AtomicU8.html#method.as_ptr)
3611- [`std::io::IsTerminal`](https://doc.rust-lang.org/stable/std/io/trait.IsTerminal.html)
3612- [`std::os::linux::net::SocketAddrExt`](https://doc.rust-lang.org/stable/std/os/linux/net/trait.SocketAddrExt.html)
3613- [`std::os::unix::net::UnixDatagram::bind_addr`](https://doc.rust-lang.org/stable/std/os/unix/net/struct.UnixDatagram.html#method.bind_addr)
3614- [`std::os::unix::net::UnixDatagram::connect_addr`](https://doc.rust-lang.org/stable/std/os/unix/net/struct.UnixDatagram.html#method.connect_addr)
3615- [`std::os::unix::net::UnixDatagram::send_to_addr`](https://doc.rust-lang.org/stable/std/os/unix/net/struct.UnixDatagram.html#method.send_to_addr)
3616- [`std::os::unix::net::UnixListener::bind_addr`](https://doc.rust-lang.org/stable/std/os/unix/net/struct.UnixListener.html#method.bind_addr)
3617- [`std::path::Path::as_mut_os_str`](https://doc.rust-lang.org/stable/std/path/struct.Path.html#method.as_mut_os_str)
3618- [`std::sync::OnceLock`](https://doc.rust-lang.org/stable/std/sync/struct.OnceLock.html)
3619
3620<a id="1.70.0-Cargo"></a>
3621
3622Cargo
3623-----
3624
3625- [Add `CARGO_PKG_README`](https://github.com/rust-lang/cargo/pull/11645/)
3626- [Make `sparse` the default protocol for crates.io](https://github.com/rust-lang/cargo/pull/11791/)
3627- [Accurately show status when downgrading dependencies](https://github.com/rust-lang/cargo/pull/11839/)
3628- [Use registry.default for login/logout](https://github.com/rust-lang/cargo/pull/11949/)
3629- [Stabilize `cargo logout`](https://github.com/rust-lang/cargo/pull/11950/)
3630
3631<a id="1.70.0-Misc"></a>
3632
3633Misc
3634----
3635
3636- [Stabilize rustdoc `--test-run-directory`](https://github.com/rust-lang/rust/pull/103682/)
3637
3638<a id="1.70.0-Compatibility-Notes"></a>
3639
3640Compatibility Notes
3641-------------------
3642
3643- [Prevent stable `libtest` from supporting `-Zunstable-options`](https://github.com/rust-lang/rust/pull/109044/)
3644- [Perform const and unsafe checking for expressions in `let _ = expr` position.](https://github.com/rust-lang/rust/pull/102256/)
3645- [WebAssembly targets enable `sign-ext` and `mutable-globals` features in codegen](https://github.com/rust-lang/rust/issues/109807)
3646 This may cause incompatibility with older execution environments.
3647- [Insert alignment checks for pointer dereferences as debug assertions](https://github.com/rust-lang/rust/pull/98112)
3648 This catches undefined behavior at runtime, and may cause existing code to fail.
3649
3650<a id="1.70.0-Internal-Changes"></a>
3651
3652Internal Changes
3653----------------
3654
3655These changes do not affect any public interfaces of Rust, but they represent
3656significant improvements to the performance or internals of rustc and related
3657tools.
3658
3659- [Upgrade to LLVM 16](https://github.com/rust-lang/rust/pull/109474/)
3660- [Use SipHash-1-3 instead of SipHash-2-4 for StableHasher](https://github.com/rust-lang/rust/pull/107925/)
3661
3662Version 1.69.0 (2023-04-20)
3663==========================
3664
3665<a id="1.69.0-Language"></a>
3666
3667Language
3668--------
3669
3670- [Deriving built-in traits on packed structs works with `Copy` fields.](https://github.com/rust-lang/rust/pull/104429/)
3671- [Stabilize the `cmpxchg16b` target feature on x86 and x86_64.](https://github.com/rust-lang/rust/pull/106774/)
3672- [Improve analysis of trait bounds for associated types.](https://github.com/rust-lang/rust/pull/103695/)
3673- [Allow associated types to be used as union fields.](https://github.com/rust-lang/rust/pull/106938/)
3674- [Allow `Self: Autotrait` bounds on dyn-safe trait methods.](https://github.com/rust-lang/rust/pull/107082/)
3675- [Treat `str` as containing `[u8]` for auto trait purposes.](https://github.com/rust-lang/rust/pull/107941/)
3676
3677<a id="1.69.0-Compiler"></a>
3678
3679Compiler
3680--------
3681
3682- [Upgrade `*-pc-windows-gnu` on CI to mingw-w64 v10 and GCC 12.2.](https://github.com/rust-lang/rust/pull/100178/)
3683- [Rework min_choice algorithm of member constraints.](https://github.com/rust-lang/rust/pull/105300/)
3684- [Support `true` and `false` as boolean flags in compiler arguments.](https://github.com/rust-lang/rust/pull/107043/)
3685- [Default `repr(C)` enums to `c_int` size.](https://github.com/rust-lang/rust/pull/107592/)
3686
3687<a id="1.69.0-Libraries"></a>
3688
3689Libraries
3690---------
3691
3692- [Implement the unstable `DispatchFromDyn` for cell types, allowing downstream experimentation with custom method receivers.](https://github.com/rust-lang/rust/pull/97373/)
3693- [Document that `fmt::Arguments::as_str()` may return `Some(_)` in more cases after optimization, subject to change.](https://github.com/rust-lang/rust/pull/106823/)
3694- [Implement `AsFd` and `AsRawFd` for `Rc`.](https://github.com/rust-lang/rust/pull/107317/)
3695
3696<a id="1.69.0-Stabilized-APIs"></a>
3697
3698Stabilized APIs
3699---------------
3700
3701- [`CStr::from_bytes_until_nul`](https://doc.rust-lang.org/stable/core/ffi/struct.CStr.html#method.from_bytes_until_nul)
3702- [`core::ffi::FromBytesUntilNulError`](https://doc.rust-lang.org/stable/core/ffi/struct.FromBytesUntilNulError.html)
3703
3704These APIs are now stable in const contexts:
3705
3706- [`SocketAddr::new`](https://doc.rust-lang.org/stable/std/net/enum.SocketAddr.html#method.new)
3707- [`SocketAddr::ip`](https://doc.rust-lang.org/stable/std/net/enum.SocketAddr.html#method.ip)
3708- [`SocketAddr::port`](https://doc.rust-lang.org/stable/std/net/enum.SocketAddr.html#method.port)
3709- [`SocketAddr::is_ipv4`](https://doc.rust-lang.org/stable/std/net/enum.SocketAddr.html#method.is_ipv4)
3710- [`SocketAddr::is_ipv6`](https://doc.rust-lang.org/stable/std/net/enum.SocketAddr.html#method.is_ipv6)
3711- [`SocketAddrV4::new`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV4.html#method.new)
3712- [`SocketAddrV4::ip`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV4.html#method.ip)
3713- [`SocketAddrV4::port`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV4.html#method.port)
3714- [`SocketAddrV6::new`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV6.html#method.new)
3715- [`SocketAddrV6::ip`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV6.html#method.ip)
3716- [`SocketAddrV6::port`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV6.html#method.port)
3717- [`SocketAddrV6::flowinfo`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV6.html#method.flowinfo)
3718- [`SocketAddrV6::scope_id`](https://doc.rust-lang.org/stable/std/net/struct.SocketAddrV6.html#method.scope_id)
3719
3720<a id="1.69.0-Cargo"></a>
3721
3722Cargo
3723-----
3724
3725- [Cargo now suggests `cargo fix` or `cargo clippy --fix` when compilation warnings are auto-fixable.](https://github.com/rust-lang/cargo/pull/11558/)
3726- [Cargo now suggests `cargo add` if you try to install a library crate.](https://github.com/rust-lang/cargo/pull/11410/)
3727- [Cargo now sets the `CARGO_BIN_NAME` environment variable also for binary examples.](https://github.com/rust-lang/cargo/pull/11705/)
3728
3729<a id="1.69.0-Rustdoc"></a>
3730
3731Rustdoc
3732-----
3733
3734- [Vertically compact trait bound formatting.](https://github.com/rust-lang/rust/pull/102842/)
3735- [Only include stable lints in `rustdoc::all` group.](https://github.com/rust-lang/rust/pull/106316/)
3736- [Compute maximum Levenshtein distance based on the query.](https://github.com/rust-lang/rust/pull/107141/)
3737- [Remove inconsistently-present sidebar tooltips.](https://github.com/rust-lang/rust/pull/107490/)
3738- [Search by macro when query ends with `!`.](https://github.com/rust-lang/rust/pull/108143/)
3739
3740<a id="1.69.0-Compatibility-Notes"></a>
3741
3742Compatibility Notes
3743-------------------
3744
3745- [The `rust-analysis` component from `rustup` now only contains a warning placeholder.](https://github.com/rust-lang/rust/pull/101841/) This was primarily intended for RLS, and the corresponding `-Zsave-analysis` flag has been removed from the compiler as well.
3746- [Unaligned references to packed fields are now a hard error.](https://github.com/rust-lang/rust/pull/102513/) This has been a warning since 1.53, and denied by default with a future-compatibility warning since 1.62.
3747- [Update the minimum external LLVM to 14.](https://github.com/rust-lang/rust/pull/107573/)
3748- [Cargo now emits errors on invalid characters in a registry token.](https://github.com/rust-lang/cargo/pull/11600/)
3749- [When `default-features` is set to false of a workspace dependency, and an inherited dependency of a member has `default-features = true`, Cargo will enable default features of that dependency.](https://github.com/rust-lang/cargo/pull/11409/)
3750- [Cargo denies `CARGO_HOME` in the `[env]` configuration table. Cargo itself doesn't pick up this value, but recursive calls to cargo would, which was not intended.](https://github.com/rust-lang/cargo/pull/11644/)
3751- [Debuginfo for build dependencies is now off if not explicitly set. This is expected to improve the overall build time.](https://github.com/rust-lang/cargo/pull/11252/)
3752- [The Rust distribution no longer always includes rustdoc](https://github.com/rust-lang/rust/pull/106886)
3753 If `tools = [...]` is set in bootstrap.toml, we will respect a missing rustdoc in that list. By
3754 default rustdoc remains included. To retain the prior behavior explicitly add `"rustdoc"` to the
3755 list.
3756
3757<a id="1.69.0-Internal-Changes"></a>
3758
3759Internal Changes
3760----------------
3761
3762These changes do not affect any public interfaces of Rust, but they represent
3763significant improvements to the performance or internals of rustc and related
3764tools.
3765
3766- [Move `format_args!()` into AST (and expand it during AST lowering)](https://github.com/rust-lang/rust/pull/106745/)
3767
3768Version 1.68.2 (2023-03-28)
3769===========================
3770
3771- [Update the GitHub RSA host key bundled within Cargo](https://github.com/rust-lang/cargo/pull/11883).
3772 The key was [rotated by GitHub](https://github.blog/2023-03-23-we-updated-our-rsa-ssh-host-key/)
3773 on 2023-03-24 after the old one leaked.
3774- [Mark the old GitHub RSA host key as revoked](https://github.com/rust-lang/cargo/pull/11889).
3775 This will prevent Cargo from accepting the leaked key even when trusted by
3776 the system.
3777- [Add support for `@revoked` and a better error message for `@cert-authority` in Cargo's SSH host key verification](https://github.com/rust-lang/cargo/pull/11635)
3778
3779Version 1.68.1 (2023-03-23)
3780===========================
3781
3782- [Fix miscompilation in produced Windows MSVC artifacts](https://github.com/rust-lang/rust/pull/109094)
3783 This was introduced by enabling ThinLTO for the distributed rustc which led
3784 to miscompilations in the resulting binary. Currently this is believed to be
3785 limited to the -Zdylib-lto flag used for rustc compilation, rather than a
3786 general bug in ThinLTO, so only rustc artifacts should be affected.
3787- [Fix --enable-local-rust builds](https://github.com/rust-lang/rust/pull/109111/)
3788- [Treat `$prefix-clang` as `clang` in linker detection code](https://github.com/rust-lang/rust/pull/109156)
3789- [Fix panic in compiler code](https://github.com/rust-lang/rust/pull/108162)
3790
3791Version 1.68.0 (2023-03-09)
3792==========================
3793
3794<a id="1.68.0-Language"></a>
3795
3796Language
3797--------
3798
3799- [Stabilize default_alloc_error_handler](https://github.com/rust-lang/rust/pull/102318/)
3800 This allows usage of `alloc` on stable without requiring the
3801 definition of a handler for allocation failure. Defining custom handlers is still unstable.
3802- [Stabilize `efiapi` calling convention.](https://github.com/rust-lang/rust/pull/105795/)
3803- [Remove implicit promotion for types with drop glue](https://github.com/rust-lang/rust/pull/105085/)
3804
3805<a id="1.68.0-Compiler"></a>
3806
3807Compiler
3808--------
3809
3810- [Change `bindings_with_variant_name` to deny-by-default](https://github.com/rust-lang/rust/pull/104154/)
3811- [Allow .. to be parsed as let initializer](https://github.com/rust-lang/rust/pull/105701/)
3812- [Add `armv7-sony-vita-newlibeabihf` as a tier 3 target](https://github.com/rust-lang/rust/pull/105712/)
3813- [Always check alignment during compile-time const evaluation](https://github.com/rust-lang/rust/pull/104616/)
3814- [Disable "split dwarf inlining" by default.](https://github.com/rust-lang/rust/pull/106709/)
3815- [Add vendor to Fuchsia's target triple](https://github.com/rust-lang/rust/pull/106429/)
3816- [Enable sanitizers for s390x-linux](https://github.com/rust-lang/rust/pull/107127/)
3817
3818<a id="1.68.0-Libraries"></a>
3819
3820Libraries
3821---------
3822
3823- [Loosen the bound on the Debug implementation of Weak.](https://github.com/rust-lang/rust/pull/90291/)
3824- [Make `std::task::Context` !Send and !Sync](https://github.com/rust-lang/rust/pull/95985/)
3825- [PhantomData layout guarantees](https://github.com/rust-lang/rust/pull/104081/)
3826- [Don't derive Debug for `OnceWith` & `RepeatWith`](https://github.com/rust-lang/rust/pull/104163/)
3827- [Implement DerefMut for PathBuf](https://github.com/rust-lang/rust/pull/105018/)
3828- [Add O(1) `Vec -> VecDeque` conversion guarantee](https://github.com/rust-lang/rust/pull/105128/)
3829- [Leak amplification for peek_mut() to ensure BinaryHeap's invariant is always met](https://github.com/rust-lang/rust/pull/105851/)
3830
3831<a id="1.68.0-Stabilized-APIs"></a>
3832
3833Stabilized APIs
3834---------------
3835
3836- [`{core,std}::pin::pin!`](https://doc.rust-lang.org/stable/std/pin/macro.pin.html)
3837- [`impl From<bool> for {f32,f64}`](https://doc.rust-lang.org/stable/std/primitive.f32.html#impl-From%3Cbool%3E-for-f32)
3838- [`std::path::MAIN_SEPARATOR_STR`](https://doc.rust-lang.org/stable/std/path/constant.MAIN_SEPARATOR_STR.html)
3839- [`impl DerefMut for PathBuf`](https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#impl-DerefMut-for-PathBuf)
3840
3841These APIs are now stable in const contexts:
3842
3843- [`VecDeque::new`](https://doc.rust-lang.org/stable/std/collections/struct.VecDeque.html#method.new)
3844
3845<a id="1.68.0-Cargo"></a>
3846
3847Cargo
3848-----
3849
3850- [Stabilize sparse registry support for crates.io](https://github.com/rust-lang/cargo/pull/11224/)
3851- [`cargo build --verbose` tells you more about why it recompiles.](https://github.com/rust-lang/cargo/pull/11407/)
3852- [Show progress of crates.io index update even `net.git-fetch-with-cli` option enabled](https://github.com/rust-lang/cargo/pull/11579/)
3853
3854<a id="1.68.0-Misc"></a>
3855
3856Misc
3857----
3858
3859<a id="1.68.0-Compatibility-Notes"></a>
3860
3861Compatibility Notes
3862-------------------
3863
3864- [Only support Android NDK 25 or newer](https://blog.rust-lang.org/2023/01/09/android-ndk-update-r25.html)
3865- [Add `SEMICOLON_IN_EXPRESSIONS_FROM_MACROS` to future-incompat report](https://github.com/rust-lang/rust/pull/103418/)
3866- [Only specify `--target` by default for `-Zgcc-ld=lld` on wasm](https://github.com/rust-lang/rust/pull/101792/)
3867- [Bump `IMPLIED_BOUNDS_ENTAILMENT` to Deny + ReportNow](https://github.com/rust-lang/rust/pull/106465/)
3868- [`std::task::Context` no longer implements Send and Sync](https://github.com/rust-lang/rust/pull/95985)
3869
3870<a id="1.68.0-Internal-Changes"></a>
3871
3872Internal Changes
3873----------------
3874
3875These changes do not affect any public interfaces of Rust, but they represent
3876significant improvements to the performance or internals of rustc and related
3877tools.
3878
3879- [Encode spans relative to the enclosing item](https://github.com/rust-lang/rust/pull/84762/)
3880- [Don't normalize in AstConv](https://github.com/rust-lang/rust/pull/101947/)
3881- [Find the right lower bound region in the scenario of partial order relations](https://github.com/rust-lang/rust/pull/104765/)
3882- [Fix impl block in const expr](https://github.com/rust-lang/rust/pull/104889/)
3883- [Check ADT fields for copy implementations considering regions](https://github.com/rust-lang/rust/pull/105102/)
3884- [rustdoc: simplify JS search routine by not messing with lev distance](https://github.com/rust-lang/rust/pull/105796/)
3885- [Enable ThinLTO for rustc on `x86_64-pc-windows-msvc`](https://github.com/rust-lang/rust/pull/103591/)
3886- [Enable ThinLTO for rustc on `x86_64-apple-darwin`](https://github.com/rust-lang/rust/pull/103647/)
3887
3888Version 1.67.1 (2023-02-09)
3889===========================
3890
3891- [Fix interoperability with thin archives.](https://github.com/rust-lang/rust/pull/107360)
3892- [Fix an internal error in the compiler build process.](https://github.com/rust-lang/rust/pull/105624)
3893- [Downgrade `clippy::uninlined_format_args` to pedantic.](https://github.com/rust-lang/rust-clippy/pull/10265)
3894
3895Version 1.67.0 (2023-01-26)
3896==========================
3897
3898<a id="1.67.0-Language"></a>
3899
3900Language
3901--------
3902
3903- [Make `Sized` predicates coinductive, allowing cycles.](https://github.com/rust-lang/rust/pull/100386/)
3904- [`#[must_use]` annotations on `async fn` also affect the `Future::Output`.](https://github.com/rust-lang/rust/pull/100633/)
3905- [Elaborate supertrait obligations when deducing closure signatures.](https://github.com/rust-lang/rust/pull/101834/)
3906- [Invalid literals are no longer an error under `cfg(FALSE)`.](https://github.com/rust-lang/rust/pull/102944/)
3907- [Unreserve braced enum variants in value namespace.](https://github.com/rust-lang/rust/pull/103578/)
3908
3909<a id="1.67.0-Compiler"></a>
3910
3911Compiler
3912--------
3913
3914- [Enable varargs support for calling conventions other than `C` or `cdecl`.](https://github.com/rust-lang/rust/pull/97971/)
3915- [Add new MIR constant propagation based on dataflow analysis.](https://github.com/rust-lang/rust/pull/101168/)
3916- [Optimize field ordering by grouping m\*2^n-sized fields with equivalently aligned ones.](https://github.com/rust-lang/rust/pull/102750/)
3917- [Stabilize native library modifier `verbatim`.](https://github.com/rust-lang/rust/pull/104360/)
3918
3919Added, updated, and removed targets:
3920
3921- [Add a tier 3 target for PowerPC on AIX](https://github.com/rust-lang/rust/pull/102293/), `powerpc64-ibm-aix`.
3922- [Add a tier 3 target for the Sony PlayStation 1](https://github.com/rust-lang/rust/pull/102689/), `mipsel-sony-psx`.
3923- [Add tier 3 `no_std` targets for the QNX Neutrino RTOS](https://github.com/rust-lang/rust/pull/102701/),
3924 `aarch64-unknown-nto-qnx710` and `x86_64-pc-nto-qnx710`.
3925- [Promote UEFI targets to tier 2](https://github.com/rust-lang/rust/pull/103933/), `aarch64-unknown-uefi`, `i686-unknown-uefi`, and `x86_64-unknown-uefi`.
3926- [Remove tier 3 `linuxkernel` targets](https://github.com/rust-lang/rust/pull/104015/) (not used by the actual kernel).
3927
3928Refer to Rust's [platform support page][platform-support-doc]
3929for more information on Rust's tiered platform support.
3930
3931<a id="1.67.0-Libraries"></a>
3932
3933Libraries
3934---------
3935
3936- [Merge `crossbeam-channel` into `std::sync::mpsc`.](https://github.com/rust-lang/rust/pull/93563/)
3937- [Fix inconsistent rounding of 0.5 when formatted to 0 decimal places.](https://github.com/rust-lang/rust/pull/102935/)
3938- [Derive `Eq` and `Hash` for `ControlFlow`.](https://github.com/rust-lang/rust/pull/103084/)
3939- [Don't build `compiler_builtins` with `-C panic=abort`.](https://github.com/rust-lang/rust/pull/103786/)
3940
3941<a id="1.67.0-Stabilized-APIs"></a>
3942
3943Stabilized APIs
3944---------------
3945
3946- [`{integer}::checked_ilog`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.checked_ilog)
3947- [`{integer}::checked_ilog2`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.checked_ilog2)
3948- [`{integer}::checked_ilog10`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.checked_ilog10)
3949- [`{integer}::ilog`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.ilog)
3950- [`{integer}::ilog2`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.ilog2)
3951- [`{integer}::ilog10`](https://doc.rust-lang.org/stable/std/primitive.i32.html#method.ilog10)
3952- [`NonZeroU*::ilog2`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroU32.html#method.ilog2)
3953- [`NonZeroU*::ilog10`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroU32.html#method.ilog10)
3954- [`NonZero*::BITS`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroU32.html#associatedconstant.BITS)
3955
3956These APIs are now stable in const contexts:
3957
3958- [`char::from_u32`](https://doc.rust-lang.org/stable/std/primitive.char.html#method.from_u32)
3959- [`char::from_digit`](https://doc.rust-lang.org/stable/std/primitive.char.html#method.from_digit)
3960- [`char::to_digit`](https://doc.rust-lang.org/stable/std/primitive.char.html#method.to_digit)
3961- [`core::char::from_u32`](https://doc.rust-lang.org/stable/core/char/fn.from_u32.html)
3962- [`core::char::from_digit`](https://doc.rust-lang.org/stable/core/char/fn.from_digit.html)
3963
3964<a id="1.67.0-Compatibility-Notes"></a>
3965
3966Compatibility Notes
3967-------------------
3968
3969- [The layout of `repr(Rust)` types now groups m\*2^n-sized fields with
3970 equivalently aligned ones.](https://github.com/rust-lang/rust/pull/102750/)
3971 This is intended to be an optimization, but it is also known to increase type
3972 sizes in a few cases for the placement of enum tags. As a reminder, the layout
3973 of `repr(Rust)` types is an implementation detail, subject to change.
3974- [0.5 now rounds to 0 when formatted to 0 decimal places.](https://github.com/rust-lang/rust/pull/102935/)
3975 This makes it consistent with the rest of floating point formatting that
3976 rounds ties toward even digits.
3977- [Chains of `&&` and `||` will now drop temporaries from their sub-expressions in
3978 evaluation order, left-to-right.](https://github.com/rust-lang/rust/pull/103293/)
3979 Previously, it was "twisted" such that the _first_ expression dropped its
3980 temporaries _last_, after all of the other expressions dropped in order.
3981- [Underscore suffixes on string literals are now a hard error.](https://github.com/rust-lang/rust/pull/103914/)
3982 This has been a future-compatibility warning since 1.20.0.
3983- [Stop passing `-export-dynamic` to `wasm-ld`.](https://github.com/rust-lang/rust/pull/105405/)
3984- [`main` is now mangled as `__main_void` on `wasm32-wasi`.](https://github.com/rust-lang/rust/pull/105468/)
3985- [Cargo now emits an error if there are multiple registries in the configuration
3986 with the same index URL.](https://github.com/rust-lang/cargo/pull/10592)
3987
3988<a id="1.67.0-Internal-Changes"></a>
3989
3990Internal Changes
3991----------------
3992
3993These changes do not affect any public interfaces of Rust, but they represent
3994significant improvements to the performance or internals of rustc and related
3995tools.
3996
3997- [Rewrite LLVM's archive writer in Rust.](https://github.com/rust-lang/rust/pull/97485/)
3998
3999Version 1.66.1 (2023-01-10)
4000===========================
4001
4002- Added validation of SSH host keys for git URLs in Cargo ([CVE-2022-46176](https://www.cve.org/CVERecord?id=CVE-2022-46176))
4003
4004Version 1.66.0 (2022-12-15)
4005==========================
4006
4007Language
4008--------
4009- [Permit specifying explicit discriminants on all `repr(Int)` enums](https://github.com/rust-lang/rust/pull/95710/)
4010 ```rust
4011 #[repr(u8)]
4012 enum Foo {
4013 A(u8) = 0,
4014 B(i8) = 1,
4015 C(bool) = 42,
4016 }
4017 ```
4018- [Allow transmutes between the same type differing only in lifetimes](https://github.com/rust-lang/rust/pull/101520/)
4019- [Change constant evaluation errors from a deny-by-default lint to a hard error](https://github.com/rust-lang/rust/pull/102091/)
4020- [Trigger `must_use` on `impl Trait` for supertraits](https://github.com/rust-lang/rust/pull/102287/)
4021 This makes `impl ExactSizeIterator` respect the existing `#[must_use]` annotation on `Iterator`.
4022- [Allow `..=X` in patterns](https://github.com/rust-lang/rust/pull/102275/)
4023- [Uplift `clippy::for_loops_over_fallibles` lint into rustc](https://github.com/rust-lang/rust/pull/99696/)
4024- [Stabilize `sym` operands in inline assembly](https://github.com/rust-lang/rust/pull/103168/)
4025- [Update to Unicode 15](https://github.com/rust-lang/rust/pull/101912/)
4026- [Opaque types no longer imply lifetime bounds](https://github.com/rust-lang/rust/pull/95474/)
4027 This is a soundness fix which may break code that was erroneously relying on this behavior.
4028
4029Compiler
4030--------
4031- [Add armv5te-none-eabi and thumbv5te-none-eabi tier 3 targets](https://github.com/rust-lang/rust/pull/101329/)
4032 - Refer to Rust's [platform support page][platform-support-doc] for more
4033 information on Rust's tiered platform support.
4034- [Add support for linking against macOS universal libraries](https://github.com/rust-lang/rust/pull/98736)
4035
4036Libraries
4037---------
4038- [Fix `#[derive(Default)]` on a generic `#[default]` enum adding unnecessary `Default` bounds](https://github.com/rust-lang/rust/pull/101040/)
4039- [Update to Unicode 15](https://github.com/rust-lang/rust/pull/101821/)
4040
4041Stabilized APIs
4042---------------
4043
4044- [`proc_macro::Span::source_text`](https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.source_text)
4045- [`uX::{checked_add_signed, overflowing_add_signed, saturating_add_signed, wrapping_add_signed}`](https://doc.rust-lang.org/stable/std/primitive.u8.html#method.checked_add_signed)
4046- [`iX::{checked_add_unsigned, overflowing_add_unsigned, saturating_add_unsigned, wrapping_add_unsigned}`](https://doc.rust-lang.org/stable/std/primitive.i8.html#method.checked_add_unsigned)
4047- [`iX::{checked_sub_unsigned, overflowing_sub_unsigned, saturating_sub_unsigned, wrapping_sub_unsigned}`](https://doc.rust-lang.org/stable/std/primitive.i8.html#method.checked_sub_unsigned)
4048- [`BTreeSet::{first, last, pop_first, pop_last}`](https://doc.rust-lang.org/stable/std/collections/struct.BTreeSet.html#method.first)
4049- [`BTreeMap::{first_key_value, last_key_value, first_entry, last_entry, pop_first, pop_last}`](https://doc.rust-lang.org/stable/std/collections/struct.BTreeMap.html#method.first_key_value)
4050- [Add `AsFd` implementations for stdio lock types on WASI.](https://github.com/rust-lang/rust/pull/101768/)
4051- [`impl TryFrom<Vec<T>> for Box<[T; N]>`](https://doc.rust-lang.org/stable/std/boxed/struct.Box.html#impl-TryFrom%3CVec%3CT%2C%20Global%3E%3E-for-Box%3C%5BT%3B%20N%5D%2C%20Global%3E)
4052- [`core::hint::black_box`](https://doc.rust-lang.org/stable/std/hint/fn.black_box.html)
4053- [`Duration::try_from_secs_{f32,f64}`](https://doc.rust-lang.org/stable/std/time/struct.Duration.html#method.try_from_secs_f32)
4054- [`Option::unzip`](https://doc.rust-lang.org/stable/std/option/enum.Option.html#method.unzip)
4055- [`std::os::fd`](https://doc.rust-lang.org/stable/std/os/fd/index.html)
4056
4057
4058Rustdoc
4059-------
4060
4061- [Add Rustdoc warning for invalid HTML tags in the documentation](https://github.com/rust-lang/rust/pull/101720/)
4062
4063Cargo
4064-----
4065
4066- [Added `cargo remove` to remove dependencies from Cargo.toml](https://doc.rust-lang.org/nightly/cargo/commands/cargo-remove.html)
4067- [`cargo publish` now waits for the new version to be downloadable before exiting](https://github.com/rust-lang/cargo/pull/11062)
4068
4069See [detailed release notes](https://github.com/rust-lang/cargo/blob/master/CHANGELOG.md#cargo-166-2022-12-15) for more.
4070
4071Compatibility Notes
4072-------------------
4073
4074- [Only apply `ProceduralMasquerade` hack to older versions of `rental`](https://github.com/rust-lang/rust/pull/94063/)
4075- [Don't export `__heap_base` and `__data_end` on wasm32-wasi.](https://github.com/rust-lang/rust/pull/102385/)
4076- [Don't export `__wasm_init_memory` on WebAssembly.](https://github.com/rust-lang/rust/pull/102426/)
4077- [Only export `__tls_*` on wasm32-unknown-unknown.](https://github.com/rust-lang/rust/pull/102440/)
4078- [Don't link to `libresolv` in libstd on Darwin](https://github.com/rust-lang/rust/pull/102766/)
4079- [Update libstd's libc to 0.2.135 (to make `libstd` no longer pull in `libiconv.dylib` on Darwin)](https://github.com/rust-lang/rust/pull/103277/)
4080- [Opaque types no longer imply lifetime bounds](https://github.com/rust-lang/rust/pull/95474/)
4081 This is a soundness fix which may break code that was erroneously relying on this behavior.
4082- [Make `order_dependent_trait_objects` show up in future-breakage reports](https://github.com/rust-lang/rust/pull/102635/)
4083- [Change std::process::Command spawning to default to inheriting the parent's signal mask](https://github.com/rust-lang/rust/pull/101077/)
4084
4085Internal Changes
4086----------------
4087
4088These changes do not affect any public interfaces of Rust, but they represent
4089significant improvements to the performance or internals of rustc and related
4090tools.
4091
4092- [Enable BOLT for LLVM compilation](https://github.com/rust-lang/rust/pull/94381/)
4093- [Enable LTO for rustc_driver.so](https://github.com/rust-lang/rust/pull/101403/)
4094
4095Version 1.65.0 (2022-11-03)
4096==========================
4097
4098Language
4099--------
4100- [Error on `as` casts of enums with `#[non_exhaustive]` variants](https://github.com/rust-lang/rust/pull/92744/)
4101- [Stabilize `let else`](https://github.com/rust-lang/rust/pull/93628/)
4102- [Stabilize generic associated types (GATs)](https://github.com/rust-lang/rust/pull/96709/)
4103- [Add lints `let_underscore_drop` and `let_underscore_lock` from Clippy](https://github.com/rust-lang/rust/pull/97739/)
4104- [Stabilize `break`ing from arbitrary labeled blocks ("label-break-value")](https://github.com/rust-lang/rust/pull/99332/)
4105- [Uninitialized integers, floats, and raw pointers are now considered immediate UB](https://github.com/rust-lang/rust/pull/98919/).
4106 Usage of `MaybeUninit` is the correct way to work with uninitialized memory.
4107- [Stabilize raw-dylib for Windows x86_64, aarch64, and thumbv7a](https://github.com/rust-lang/rust/pull/99916/)
4108- [Do not allow `Drop` impl on foreign ADTs](https://github.com/rust-lang/rust/pull/99576/)
4109
4110Compiler
4111--------
4112- [Stabilize -Csplit-debuginfo on Linux](https://github.com/rust-lang/rust/pull/98051/)
4113- [Use niche-filling optimization even when multiple variants have data](https://github.com/rust-lang/rust/pull/94075/)
4114- [Associated type projections are now verified to be well-formed prior to resolving the underlying type](https://github.com/rust-lang/rust/pull/99217/#issuecomment-1209365630)
4115- [Stringify non-shorthand visibility correctly](https://github.com/rust-lang/rust/pull/100350/)
4116- [Normalize struct field types when unsizing](https://github.com/rust-lang/rust/pull/101831/)
4117- [Update to LLVM 15](https://github.com/rust-lang/rust/pull/99464/)
4118- [Fix aarch64 call abi to correctly zeroext when needed](https://github.com/rust-lang/rust/pull/97800/)
4119- [debuginfo: Generalize C++-like encoding for enums](https://github.com/rust-lang/rust/pull/98393/)
4120- [Add `special_module_name` lint](https://github.com/rust-lang/rust/pull/94467/)
4121- [Add support for generating unique profraw files by default when using `-C instrument-coverage`](https://github.com/rust-lang/rust/pull/100384/)
4122- [Allow dynamic linking for iOS/tvOS targets](https://github.com/rust-lang/rust/pull/100636/)
4123
4124New targets:
4125
4126- [Add armv4t-none-eabi as a tier 3 target](https://github.com/rust-lang/rust/pull/100244/)
4127- [Add powerpc64-unknown-openbsd and riscv64-unknown-openbsd as tier 3 targets](https://github.com/rust-lang/rust/pull/101025/)
4128 - Refer to Rust's [platform support page][platform-support-doc] for more
4129 information on Rust's tiered platform support.
4130
4131Libraries
4132---------
4133
4134- [Don't generate `PartialEq::ne` in derive(PartialEq)](https://github.com/rust-lang/rust/pull/98655/)
4135- [Windows RNG: Use `BCRYPT_RNG_ALG_HANDLE` by default](https://github.com/rust-lang/rust/pull/101325/)
4136- [Forbid mixing `System` with direct system allocator calls](https://github.com/rust-lang/rust/pull/101394/)
4137- [Document no support for writing to non-blocking stdio/stderr](https://github.com/rust-lang/rust/pull/101416/)
4138- [`std::layout::Layout` size must not overflow `isize::MAX` when rounded up to `align`](https://github.com/rust-lang/rust/pull/95295)
4139 This also changes the safety conditions on `Layout::from_size_align_unchecked`.
4140
4141Stabilized APIs
4142---------------
4143
4144- [`std::backtrace::Backtrace`](https://doc.rust-lang.org/stable/std/backtrace/struct.Backtrace.html)
4145- [`Bound::as_ref`](https://doc.rust-lang.org/stable/std/ops/enum.Bound.html#method.as_ref)
4146- [`std::io::read_to_string`](https://doc.rust-lang.org/stable/std/io/fn.read_to_string.html)
4147- [`<*const T>::cast_mut`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.cast_mut)
4148- [`<*mut T>::cast_const`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.cast_const)
4149
4150These APIs are now stable in const contexts:
4151
4152- [`<*const T>::offset_from`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.offset_from)
4153- [`<*mut T>::offset_from`](https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.offset_from)
4154
4155Cargo
4156-----
4157
4158- [Apply GitHub fast path even for partial hashes](https://github.com/rust-lang/cargo/pull/10807/)
4159- [Do not add home bin path to PATH if it's already there](https://github.com/rust-lang/cargo/pull/11023/)
4160- [Take priority into account within the pending queue](https://github.com/rust-lang/cargo/pull/11032/).
4161 This slightly optimizes job scheduling by Cargo, with typically small improvements on larger crate graph builds.
4162
4163Compatibility Notes
4164-------------------
4165
4166- [`std::layout::Layout` size must not overflow `isize::MAX` when rounded up to `align`](https://github.com/rust-lang/rust/pull/95295).
4167 This also changes the safety conditions on `Layout::from_size_align_unchecked`.
4168- [`PollFn` now only implements `Unpin` if the closure is `Unpin`](https://github.com/rust-lang/rust/pull/102737).
4169 This is a possible breaking change if users were relying on the blanket unpin implementation.
4170 See discussion on the PR for details of why this change was made.
4171- [Drop ExactSizeIterator impl from std::char::EscapeAscii](https://github.com/rust-lang/rust/pull/99880)
4172 This is a backwards-incompatible change to the standard library's surface
4173 area, but is unlikely to affect real world usage.
4174- [Do not consider a single repeated lifetime eligible for elision in the return type](https://github.com/rust-lang/rust/pull/103450)
4175 This behavior was unintentionally changed in 1.64.0, and this release reverts that change by making this an error again.
4176- [Reenable disabled early syntax gates as future-incompatibility lints](https://github.com/rust-lang/rust/pull/99935/)
4177- [Update the minimum external LLVM to 13](https://github.com/rust-lang/rust/pull/100460/)
4178- [Don't duplicate file descriptors into stdio fds](https://github.com/rust-lang/rust/pull/101426/)
4179- [Sunset RLS](https://github.com/rust-lang/rust/pull/100863/)
4180- [Deny usage of `#![cfg_attr(..., crate_type = ...)]` to set the crate type](https://github.com/rust-lang/rust/pull/99784/)
4181 This strengthens the forward compatibility lint deprecated_cfg_attr_crate_type_name to deny.
4182- [`llvm-has-rust-patches` allows setting the build system to treat the LLVM as having Rust-specific patches](https://github.com/rust-lang/rust/pull/101072)
4183 This option may need to be set for distributions that are building Rust with a patched LLVM via `llvm-config`, not the built-in LLVM.
4184- Combining three or more languages (e.g. Objective C, C++ and Rust) into one binary may hit linker limitations when using `lld`. For more information, see [issue 102754][102754].
4185
4186[102754]: https://github.com/rust-lang/rust/issues/102754
4187
4188Internal Changes
4189----------------
4190
4191These changes do not affect any public interfaces of Rust, but they represent
4192significant improvements to the performance or internals of rustc and related
4193tools.
4194
4195- [Add `x.sh` and `x.ps1` shell scripts](https://github.com/rust-lang/rust/pull/99992/)
4196- [compiletest: use target cfg instead of hard-coded tables](https://github.com/rust-lang/rust/pull/100260/)
4197- [Use object instead of LLVM for reading bitcode from rlibs](https://github.com/rust-lang/rust/pull/98100/)
4198- [Enable MIR inlining for optimized compilations](https://github.com/rust-lang/rust/pull/91743)
4199 This provides a 3-10% improvement in compiletimes for real world crates. See [perf results](https://perf.rust-lang.org/compare.html?start=aedf78e56b2279cc869962feac5153b6ba7001ed&end=0075bb4fad68e64b6d1be06bf2db366c30bc75e1&stat=instructions:u).
4200
4201Version 1.64.0 (2022-09-22)
4202===========================
4203
4204Language
4205--------
4206- [Unions with mutable references or tuples of allowed types are now allowed](https://github.com/rust-lang/rust/pull/97995/)
4207- It is now considered valid to deallocate memory pointed to by a shared reference `&T` [if every byte in `T` is inside an `UnsafeCell`](https://github.com/rust-lang/rust/pull/98017/)
4208- Unused tuple struct fields are now warned against in an allow-by-default lint, [`unused_tuple_struct_fields`](https://github.com/rust-lang/rust/pull/95977/), similar to the existing warning for unused struct fields. This lint will become warn-by-default in the future.
4209
4210Compiler
4211--------
4212- [Add Nintendo Switch as tier 3 target](https://github.com/rust-lang/rust/pull/88991/)
4213 - Refer to Rust's [platform support page][platform-support-doc] for more
4214 information on Rust's tiered platform support.
4215- [Only compile `#[used]` as llvm.compiler.used for ELF targets](https://github.com/rust-lang/rust/pull/93718/)
4216- [Add the `--diagnostic-width` compiler flag to define the terminal width.](https://github.com/rust-lang/rust/pull/95635/)
4217- [Add support for link-flavor `rust-lld` for iOS, tvOS and watchOS](https://github.com/rust-lang/rust/pull/98771/)
4218
4219Libraries
4220---------
4221- [Remove restrictions on compare-exchange memory ordering.](https://github.com/rust-lang/rust/pull/98383/)
4222- You can now `write!` or `writeln!` into an `OsString`: [Implement `fmt::Write` for `OsString`](https://github.com/rust-lang/rust/pull/97915/)
4223- [Make RwLockReadGuard covariant](https://github.com/rust-lang/rust/pull/96820/)
4224- [Implement `FusedIterator` for `std::net::[Into]Incoming`](https://github.com/rust-lang/rust/pull/97300/)
4225- [`impl<T: AsRawFd> AsRawFd for {Arc,Box}<T>`](https://github.com/rust-lang/rust/pull/97437/)
4226- [`ptr::copy` and `ptr::swap` are doing untyped copies](https://github.com/rust-lang/rust/pull/97712/)
4227- [Add cgroupv1 support to `available_parallelism`](https://github.com/rust-lang/rust/pull/97925/)
4228- [Mitigate many incorrect uses of `mem::uninitialized`](https://github.com/rust-lang/rust/pull/99182/)
4229
4230Stabilized APIs
4231---------------
4232
4233- [`future::IntoFuture`](https://doc.rust-lang.org/stable/std/future/trait.IntoFuture.html)
4234- [`future::poll_fn`](https://doc.rust-lang.org/stable/std/future/fn.poll_fn.html)
4235- [`task::ready!`](https://doc.rust-lang.org/stable/std/task/macro.ready.html)
4236- [`num::NonZero*::checked_mul`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroUsize.html#method.checked_mul)
4237- [`num::NonZero*::checked_pow`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroUsize.html#method.checked_pow)
4238- [`num::NonZero*::saturating_mul`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroUsize.html#method.saturating_mul)
4239- [`num::NonZero*::saturating_pow`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroUsize.html#method.saturating_pow)
4240- [`num::NonZeroI*::abs`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroIsize.html#method.abs)
4241- [`num::NonZeroI*::checked_abs`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroIsize.html#method.checked_abs)
4242- [`num::NonZeroI*::overflowing_abs`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroIsize.html#method.overflowing_abs)
4243- [`num::NonZeroI*::saturating_abs`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroIsize.html#method.saturating_abs)
4244- [`num::NonZeroI*::unsigned_abs`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroIsize.html#method.unsigned_abs)
4245- [`num::NonZeroI*::wrapping_abs`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroIsize.html#method.wrapping_abs)
4246- [`num::NonZeroU*::checked_add`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroUsize.html#method.checked_add)
4247- [`num::NonZeroU*::checked_next_power_of_two`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroUsize.html#method.checked_next_power_of_two)
4248- [`num::NonZeroU*::saturating_add`](https://doc.rust-lang.org/stable/std/num/struct.NonZeroUsize.html#method.saturating_add)
4249- [`os::unix::process::CommandExt::process_group`](https://doc.rust-lang.org/stable/std/os/unix/process/trait.CommandExt.html#tymethod.process_group)
4250- [`os::windows::fs::FileTypeExt::is_symlink_dir`](https://doc.rust-lang.org/stable/std/os/windows/fs/trait.FileTypeExt.html#tymethod.is_symlink_dir)
4251- [`os::windows::fs::FileTypeExt::is_symlink_file`](https://doc.rust-lang.org/stable/std/os/windows/fs/trait.FileTypeExt.html#tymethod.is_symlink_file)
4252
4253These types were previously stable in `std::ffi`, but are now also available in `core` and `alloc`:
4254
4255- [`core::ffi::CStr`](https://doc.rust-lang.org/stable/core/ffi/struct.CStr.html)
4256- [`core::ffi::FromBytesWithNulError`](https://doc.rust-lang.org/stable/core/ffi/struct.FromBytesWithNulError.html)
4257- [`alloc::ffi::CString`](https://doc.rust-lang.org/stable/alloc/ffi/struct.CString.html)
4258- [`alloc::ffi::FromVecWithNulError`](https://doc.rust-lang.org/stable/alloc/ffi/struct.FromVecWithNulError.html)
4259- [`alloc::ffi::IntoStringError`](https://doc.rust-lang.org/stable/alloc/ffi/struct.IntoStringError.html)
4260- [`alloc::ffi::NulError`](https://doc.rust-lang.org/stable/alloc/ffi/struct.NulError.html)
4261
4262These types were previously stable in `std::os::raw`, but are now also available in `core::ffi` and `std::ffi`:
4263
4264- [`ffi::c_char`](https://doc.rust-lang.org/stable/std/ffi/type.c_char.html)
4265- [`ffi::c_double`](https://doc.rust-lang.org/stable/std/ffi/type.c_double.html)
4266- [`ffi::c_float`](https://doc.rust-lang.org/stable/std/ffi/type.c_float.html)
4267- [`ffi::c_int`](https://doc.rust-lang.org/stable/std/ffi/type.c_int.html)
4268- [`ffi::c_long`](https://doc.rust-lang.org/stable/std/ffi/type.c_long.html)
4269- [`ffi::c_longlong`](https://doc.rust-lang.org/stable/std/ffi/type.c_longlong.html)
4270- [`ffi::c_schar`](https://doc.rust-lang.org/stable/std/ffi/type.c_schar.html)
4271- [`ffi::c_short`](https://doc.rust-lang.org/stable/std/ffi/type.c_short.html)
4272- [`ffi::c_uchar`](https://doc.rust-lang.org/stable/std/ffi/type.c_uchar.html)
4273- [`ffi::c_uint`](https://doc.rust-lang.org/stable/std/ffi/type.c_uint.html)
4274- [`ffi::c_ulong`](https://doc.rust-lang.org/stable/std/ffi/type.c_ulong.html)
4275- [`ffi::c_ulonglong`](https://doc.rust-lang.org/stable/std/ffi/type.c_ulonglong.html)
4276- [`ffi::c_ushort`](https://doc.rust-lang.org/stable/std/ffi/type.c_ushort.html)
4277
4278These APIs are now usable in const contexts:
4279
4280- [`slice::from_raw_parts`](https://doc.rust-lang.org/stable/core/slice/fn.from_raw_parts.html)
4281
4282Cargo
4283-----
4284- [Packages can now inherit settings from the workspace so that the settings
4285 can be centralized in one place.](https://github.com/rust-lang/cargo/pull/10859) See
4286 [`workspace.package`](https://doc.rust-lang.org/nightly/cargo/reference/workspaces.html#the-workspacepackage-table)
4287 and
4288 [`workspace.dependencies`](https://doc.rust-lang.org/nightly/cargo/reference/workspaces.html#the-workspacedependencies-table)
4289 for more details on how to define these common settings.
4290- [Cargo commands can now accept multiple `--target` flags to build for
4291 multiple targets at once](https://github.com/rust-lang/cargo/pull/10766), and the
4292 [`build.target`](https://doc.rust-lang.org/nightly/cargo/reference/config.html#buildtarget)
4293 config option may now take an array of multiple targets.
4294- [The `--jobs` argument can now take a negative number to count backwards from
4295 the max CPUs.](https://github.com/rust-lang/cargo/pull/10844)
4296- [`cargo add` will now update `Cargo.lock`.](https://github.com/rust-lang/cargo/pull/10902)
4297- [Added](https://github.com/rust-lang/cargo/pull/10838) the
4298 [`--crate-type`](https://doc.rust-lang.org/nightly/cargo/commands/cargo-rustc.html#option-cargo-rustc---crate-type)
4299 flag to `cargo rustc` to override the crate type.
4300- [Significantly improved the performance fetching git dependencies from GitHub
4301 when using a hash in the `rev` field.](https://github.com/rust-lang/cargo/pull/10079)
4302
4303Misc
4304----
4305- [The `rust-analyzer` rustup component is now available on the stable channel.](https://github.com/rust-lang/rust/pull/98640/)
4306
4307Compatibility Notes
4308-------------------
4309- The minimum required versions for all `-linux-gnu` targets are now at least kernel 3.2 and glibc 2.17, for targets that previously supported older versions: [Increase the minimum linux-gnu versions](https://github.com/rust-lang/rust/pull/95026/)
4310- [Network primitives are now implemented with the ideal Rust layout, not the C system layout](https://github.com/rust-lang/rust/pull/78802/). This can cause problems when transmuting the types.
4311- [Add assertion that `transmute_copy`'s `U` is not larger than `T`](https://github.com/rust-lang/rust/pull/98839/)
4312- [A soundness bug in `BTreeMap` was fixed](https://github.com/rust-lang/rust/pull/99413/) that allowed data it was borrowing to be dropped before the container.
4313- [The Drop behavior of C-like enums cast to ints has changed](https://github.com/rust-lang/rust/pull/96862/). These are already discouraged by a compiler warning.
4314- [Relate late-bound closure lifetimes to parent fn in NLL](https://github.com/rust-lang/rust/pull/98835/)
4315- [Errors at const-eval time are now in future incompatibility reports](https://github.com/rust-lang/rust/pull/97743/)
4316- On the `thumbv6m-none-eabi` target, some incorrect `asm!` statements were erroneously accepted if they used the high registers (r8 to r14) as an input/output operand. [This is no longer accepted](https://github.com/rust-lang/rust/pull/99155/).
4317- [`impl Trait` was accidentally accepted as the associated type value of return-position `impl Trait`](https://github.com/rust-lang/rust/pull/97346/), without fulfilling all the trait bounds of that associated type, as long as the hidden type satisfies said bounds. This has been fixed.
4318
4319Internal Changes
4320----------------
4321
4322These changes do not affect any public interfaces of Rust, but they represent
4323significant improvements to the performance or internals of rustc and related
4324tools.
4325
4326- Windows builds now use profile-guided optimization, providing 10-20% improvements to compiler performance: [Utilize PGO for windows x64 rustc dist builds](https://github.com/rust-lang/rust/pull/96978/)
4327- [Stop keeping metadata in memory before writing it to disk](https://github.com/rust-lang/rust/pull/96544/)
4328- [compiletest: strip debuginfo by default for mode=ui](https://github.com/rust-lang/rust/pull/98140/)
4329- Many improvements to generated code for derives, including performance improvements:
4330 - [Don't use match-destructuring for derived ops on structs.](https://github.com/rust-lang/rust/pull/98446/)
4331 - [Many small deriving cleanups](https://github.com/rust-lang/rust/pull/98741/)
4332 - [More derive output improvements](https://github.com/rust-lang/rust/pull/98758/)
4333 - [Clarify deriving code](https://github.com/rust-lang/rust/pull/98915/)
4334 - [Final derive output improvements](https://github.com/rust-lang/rust/pull/99046/)
4335 - [Stop injecting `#[allow(unused_qualifications)]` in generated `derive` implementations](https://github.com/rust-lang/rust/pull/99485/)
4336 - [Improve `derive(Debug)`](https://github.com/rust-lang/rust/pull/98190/)
4337- [Bump to clap 3](https://github.com/rust-lang/rust/pull/98213/)
4338- [fully move dropck to mir](https://github.com/rust-lang/rust/pull/98641/)
4339- [Optimize `Vec::insert` for the case where `index == len`.](https://github.com/rust-lang/rust/pull/98755/)
4340- [Convert rust-analyzer to an in-tree tool](https://github.com/rust-lang/rust/pull/99603/)
4341
4342Version 1.63.0 (2022-08-11)
4343==========================
4344
4345Language
4346--------
4347- [Remove migrate borrowck mode for pre-NLL errors.][95565]
4348- [Modify MIR building to drop repeat expressions with length zero.][95953]
4349- [Remove label/lifetime shadowing warnings.][96296]
4350- [Allow explicit generic arguments in the presence of `impl Trait` args.][96868]
4351- [Make `cenum_impl_drop_cast` warnings deny-by-default.][97652]
4352- [Prevent unwinding when `-C panic=abort` is used regardless of declared ABI.][96959]
4353- [lub: don't bail out due to empty binders.][97867]
4354
4355Compiler
4356--------
4357- [Stabilize the `bundle` native library modifier,][95818] also removing the
4358 deprecated `static-nobundle` linking kind.
4359- [Add Apple WatchOS compile targets\*.][95243]
4360- [Add a Windows application manifest to rustc-main.][96737]
4361
4362\* Refer to Rust's [platform support page][platform-support-doc] for more
4363 information on Rust's tiered platform support.
4364
4365Libraries
4366---------
4367- [Implement `Copy`, `Clone`, `PartialEq` and `Eq` for `core::fmt::Alignment`.][94530]
4368- [Extend `ptr::null` and `null_mut` to all thin (including extern) types.][94954]
4369- [`impl Read and Write for VecDeque<u8>`.][95632]
4370- [STD support for the Nintendo 3DS.][95897]
4371- [Use rounding in float to Duration conversion methods.][96051]
4372- [Make write/print macros eagerly drop temporaries.][96455]
4373- [Implement internal traits that enable `[OsStr]::join`.][96881]
4374- [Implement `Hash` for `core::alloc::Layout`.][97034]
4375- [Add capacity documentation for `OsString`.][97202]
4376- [Put a bound on collection misbehavior.][97316]
4377- [Make `std::mem::needs_drop` accept `?Sized`.][97675]
4378- [`impl Termination for Infallible` and then make the `Result` impls of `Termination` more generic.][97803]
4379- [Document Rust's stance on `/proc/self/mem`.][97837]
4380
4381Stabilized APIs
4382---------------
4383
4384- [`array::from_fn`]
4385- [`Box::into_pin`]
4386- [`BinaryHeap::try_reserve`]
4387- [`BinaryHeap::try_reserve_exact`]
4388- [`OsString::try_reserve`]
4389- [`OsString::try_reserve_exact`]
4390- [`PathBuf::try_reserve`]
4391- [`PathBuf::try_reserve_exact`]
4392- [`Path::try_exists`]
4393- [`Ref::filter_map`]
4394- [`RefMut::filter_map`]
4395- [`NonNull::<[T]>::len`][`NonNull::<slice>::len`]
4396- [`ToOwned::clone_into`]
4397- [`Ipv6Addr::to_ipv4_mapped`]
4398- [`unix::io::AsFd`]
4399- [`unix::io::BorrowedFd<'fd>`]
4400- [`unix::io::OwnedFd`]
4401- [`windows::io::AsHandle`]
4402- [`windows::io::BorrowedHandle<'handle>`]
4403- [`windows::io::OwnedHandle`]
4404- [`windows::io::HandleOrInvalid`]
4405- [`windows::io::HandleOrNull`]
4406- [`windows::io::InvalidHandleError`]
4407- [`windows::io::NullHandleError`]
4408- [`windows::io::AsSocket`]
4409- [`windows::io::BorrowedSocket<'handle>`]
4410- [`windows::io::OwnedSocket`]
4411- [`thread::scope`]
4412- [`thread::Scope`]
4413- [`thread::ScopedJoinHandle`]
4414
4415These APIs are now usable in const contexts:
4416
4417- [`array::from_ref`]
4418- [`slice::from_ref`]
4419- [`intrinsics::copy`]
4420- [`intrinsics::copy_nonoverlapping`]
4421- [`<*const T>::copy_to`]
4422- [`<*const T>::copy_to_nonoverlapping`]
4423- [`<*mut T>::copy_to`]
4424- [`<*mut T>::copy_to_nonoverlapping`]
4425- [`<*mut T>::copy_from`]
4426- [`<*mut T>::copy_from_nonoverlapping`]
4427- [`str::from_utf8`]
4428- [`Utf8Error::error_len`]
4429- [`Utf8Error::valid_up_to`]
4430- [`Condvar::new`]
4431- [`Mutex::new`]
4432- [`RwLock::new`]
4433
4434Cargo
4435-----
4436- [Stabilize the `--config path` command-line argument.][cargo/10755]
4437- [Expose rust-version in the environment as `CARGO_PKG_RUST_VERSION`.][cargo/10713]
4438
4439Compatibility Notes
4440-------------------
4441
4442- [`#[link]` attributes are now checked more strictly,][96885] which may introduce
4443 errors for invalid attribute arguments that were previously ignored.
4444- [Rounding is now used when converting a float to a `Duration`.][96051] The converted
4445 duration can differ slightly from what it was.
4446
4447Internal Changes
4448----------------
4449
4450These changes provide no direct user facing benefits, but represent significant
4451improvements to the internals and overall performance of rustc
4452and related tools.
4453
4454- [Prepare Rust for LLVM opaque pointers.][94214]
4455
4456[94214]: https://github.com/rust-lang/rust/pull/94214/
4457[94530]: https://github.com/rust-lang/rust/pull/94530/
4458[94954]: https://github.com/rust-lang/rust/pull/94954/
4459[95243]: https://github.com/rust-lang/rust/pull/95243/
4460[95565]: https://github.com/rust-lang/rust/pull/95565/
4461[95632]: https://github.com/rust-lang/rust/pull/95632/
4462[95818]: https://github.com/rust-lang/rust/pull/95818/
4463[95897]: https://github.com/rust-lang/rust/pull/95897/
4464[95953]: https://github.com/rust-lang/rust/pull/95953/
4465[96051]: https://github.com/rust-lang/rust/pull/96051/
4466[96296]: https://github.com/rust-lang/rust/pull/96296/
4467[96455]: https://github.com/rust-lang/rust/pull/96455/
4468[96737]: https://github.com/rust-lang/rust/pull/96737/
4469[96868]: https://github.com/rust-lang/rust/pull/96868/
4470[96881]: https://github.com/rust-lang/rust/pull/96881/
4471[96885]: https://github.com/rust-lang/rust/pull/96885/
4472[96959]: https://github.com/rust-lang/rust/pull/96959/
4473[97034]: https://github.com/rust-lang/rust/pull/97034/
4474[97202]: https://github.com/rust-lang/rust/pull/97202/
4475[97316]: https://github.com/rust-lang/rust/pull/97316/
4476[97652]: https://github.com/rust-lang/rust/pull/97652/
4477[97675]: https://github.com/rust-lang/rust/pull/97675/
4478[97803]: https://github.com/rust-lang/rust/pull/97803/
4479[97837]: https://github.com/rust-lang/rust/pull/97837/
4480[97867]: https://github.com/rust-lang/rust/pull/97867/
4481[cargo/10713]: https://github.com/rust-lang/cargo/pull/10713/
4482[cargo/10755]: https://github.com/rust-lang/cargo/pull/10755/
4483
4484[`array::from_fn`]: https://doc.rust-lang.org/stable/std/array/fn.from_fn.html
4485[`Box::into_pin`]: https://doc.rust-lang.org/stable/std/boxed/struct.Box.html#method.into_pin
4486[`BinaryHeap::try_reserve_exact`]: https://doc.rust-lang.org/stable/alloc/collections/binary_heap/struct.BinaryHeap.html#method.try_reserve_exact
4487[`BinaryHeap::try_reserve`]: https://doc.rust-lang.org/stable/std/collections/struct.BinaryHeap.html#method.try_reserve
4488[`OsString::try_reserve`]: https://doc.rust-lang.org/stable/std/ffi/struct.OsString.html#method.try_reserve
4489[`OsString::try_reserve_exact`]: https://doc.rust-lang.org/stable/std/ffi/struct.OsString.html#method.try_reserve_exact
4490[`PathBuf::try_reserve`]: https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#method.try_reserve
4491[`PathBuf::try_reserve_exact`]: https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#method.try_reserve_exact
4492[`Path::try_exists`]: https://doc.rust-lang.org/stable/std/path/struct.Path.html#method.try_exists
4493[`Ref::filter_map`]: https://doc.rust-lang.org/stable/std/cell/struct.Ref.html#method.filter_map
4494[`RefMut::filter_map`]: https://doc.rust-lang.org/stable/std/cell/struct.RefMut.html#method.filter_map
4495[`NonNull::<slice>::len`]: https://doc.rust-lang.org/stable/std/ptr/struct.NonNull.html#method.len
4496[`ToOwned::clone_into`]: https://doc.rust-lang.org/stable/std/borrow/trait.ToOwned.html#method.clone_into
4497[`Ipv6Addr::to_ipv4_mapped`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv6Addr.html#method.to_ipv4_mapped
4498[`unix::io::AsFd`]: https://doc.rust-lang.org/stable/std/os/unix/io/trait.AsFd.html
4499[`unix::io::BorrowedFd<'fd>`]: https://doc.rust-lang.org/stable/std/os/unix/io/struct.BorrowedFd.html
4500[`unix::io::OwnedFd`]: https://doc.rust-lang.org/stable/std/os/unix/io/struct.OwnedFd.html
4501[`windows::io::AsHandle`]: https://doc.rust-lang.org/stable/std/os/windows/io/trait.AsHandle.html
4502[`windows::io::BorrowedHandle<'handle>`]: https://doc.rust-lang.org/stable/std/os/windows/io/struct.BorrowedHandle.html
4503[`windows::io::OwnedHandle`]: https://doc.rust-lang.org/stable/std/os/windows/io/struct.OwnedHandle.html
4504[`windows::io::HandleOrInvalid`]: https://doc.rust-lang.org/stable/std/os/windows/io/struct.HandleOrInvalid.html
4505[`windows::io::HandleOrNull`]: https://doc.rust-lang.org/stable/std/os/windows/io/struct.HandleOrNull.html
4506[`windows::io::InvalidHandleError`]: https://doc.rust-lang.org/stable/std/os/windows/io/struct.InvalidHandleError.html
4507[`windows::io::NullHandleError`]: https://doc.rust-lang.org/stable/std/os/windows/io/struct.NullHandleError.html
4508[`windows::io::AsSocket`]: https://doc.rust-lang.org/stable/std/os/windows/io/trait.AsSocket.html
4509[`windows::io::BorrowedSocket<'handle>`]: https://doc.rust-lang.org/stable/std/os/windows/io/struct.BorrowedSocket.html
4510[`windows::io::OwnedSocket`]: https://doc.rust-lang.org/stable/std/os/windows/io/struct.OwnedSocket.html
4511[`thread::scope`]: https://doc.rust-lang.org/stable/std/thread/fn.scope.html
4512[`thread::Scope`]: https://doc.rust-lang.org/stable/std/thread/struct.Scope.html
4513[`thread::ScopedJoinHandle`]: https://doc.rust-lang.org/stable/std/thread/struct.ScopedJoinHandle.html
4514
4515[`array::from_ref`]: https://doc.rust-lang.org/stable/std/array/fn.from_ref.html
4516[`slice::from_ref`]: https://doc.rust-lang.org/stable/std/slice/fn.from_ref.html
4517[`intrinsics::copy`]: https://doc.rust-lang.org/stable/std/intrinsics/fn.copy.html
4518[`intrinsics::copy_nonoverlapping`]: https://doc.rust-lang.org/stable/std/intrinsics/fn.copy_nonoverlapping.html
4519[`<*const T>::copy_to`]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.copy_to
4520[`<*const T>::copy_to_nonoverlapping`]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.copy_to_nonoverlapping
4521[`<*mut T>::copy_to`]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.copy_to-1
4522[`<*mut T>::copy_to_nonoverlapping`]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.copy_to_nonoverlapping-1
4523[`<*mut T>::copy_from`]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.copy_from
4524[`<*mut T>::copy_from_nonoverlapping`]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.copy_from_nonoverlapping
4525[`str::from_utf8`]: https://doc.rust-lang.org/stable/std/str/fn.from_utf8.html
4526[`Utf8Error::error_len`]: https://doc.rust-lang.org/stable/std/str/struct.Utf8Error.html#method.error_len
4527[`Utf8Error::valid_up_to`]: https://doc.rust-lang.org/stable/std/str/struct.Utf8Error.html#method.valid_up_to
4528[`Condvar::new`]: https://doc.rust-lang.org/stable/std/sync/struct.Condvar.html#method.new
4529[`Mutex::new`]: https://doc.rust-lang.org/stable/std/sync/struct.Mutex.html#method.new
4530[`RwLock::new`]: https://doc.rust-lang.org/stable/std/sync/struct.RwLock.html#method.new
4531
4532Version 1.62.1 (2022-07-19)
4533==========================
4534
4535Rust 1.62.1 addresses a few recent regressions in the compiler and standard
4536library, and also mitigates a CPU vulnerability on Intel SGX.
4537
4538* [The compiler fixed unsound function coercions involving `impl Trait` return types.][98608]
4539* [The compiler fixed an incremental compilation bug with `async fn` lifetimes.][98890]
4540* [Windows added a fallback for overlapped I/O in synchronous reads and writes.][98950]
4541* [The `x86_64-fortanix-unknown-sgx` target added a mitigation for the
4542 MMIO stale data vulnerability][98126], advisory [INTEL-SA-00615].
4543
4544[98608]: https://github.com/rust-lang/rust/issues/98608
4545[98890]: https://github.com/rust-lang/rust/issues/98890
4546[98950]: https://github.com/rust-lang/rust/pull/98950
4547[98126]: https://github.com/rust-lang/rust/pull/98126
4548[INTEL-SA-00615]: https://www.intel.com/content/www/us/en/security-center/advisory/intel-sa-00615.html
4549
4550Version 1.62.0 (2022-06-30)
4551==========================
4552
4553Language
4554--------
4555
4556- [Stabilize `#[derive(Default)]` on enums with a `#[default]` variant][94457]
4557- [Teach flow sensitive checks that visibly uninhabited call expressions never return][93313]
4558- [Fix constants not getting dropped if part of a diverging expression][94775]
4559- [Support unit struct/enum variant in destructuring assignment][95380]
4560- [Remove mutable_borrow_reservation_conflict lint and allow the code pattern][96268]
4561- [`const` functions may now specify `extern "C"` or `extern "Rust"`][95346]
4562
4563Compiler
4564--------
4565
4566- [linker: Stop using whole-archive on dependencies of dylibs][96436]
4567- [Make `unaligned_references` lint deny-by-default][95372]
4568 This lint is also a future compatibility lint, and is expected to eventually
4569 become a hard error.
4570- [Only add codegen backend to dep info if -Zbinary-dep-depinfo is used][93969]
4571- [Reject `#[thread_local]` attribute on non-static items][95006]
4572- [Add tier 3 `aarch64-pc-windows-gnullvm` and `x86_64-pc-windows-gnullvm` targets\*][94872]
4573- [Implement a lint to warn about unused macro rules][96150]
4574- [Promote `x86_64-unknown-none` target to Tier 2\*][95705]
4575
4576\* Refer to Rust's [platform support page][platform-support-doc] for more
4577 information on Rust's tiered platform support.
4578
4579Libraries
4580---------
4581
4582- [Windows: Use a pipe relay for chaining pipes][95841]
4583- [Replace Linux Mutex and Condvar with futex based ones.][95035]
4584- [Replace RwLock by a futex based one on Linux][95801]
4585- [std: directly use pthread in UNIX parker implementation][96393]
4586
4587Stabilized APIs
4588---------------
4589
4590- [`bool::then_some`]
4591- [`f32::total_cmp`]
4592- [`f64::total_cmp`]
4593- [`Stdin::lines`]
4594- [`windows::CommandExt::raw_arg`]
4595- [`impl<T: Default> Default for AssertUnwindSafe<T>`]
4596- [`From<Rc<str>> for Rc<[u8]>`][rc-u8-from-str]
4597- [`From<Arc<str>> for Arc<[u8]>`][arc-u8-from-str]
4598- [`FusedIterator for EncodeWide`]
4599- [RDM intrinsics on aarch64][stdarch/1285]
4600
4601Clippy
4602------
4603
4604- [Create clippy lint against unexpectedly late drop for temporaries in match scrutinee expressions][94206]
4605
4606Cargo
4607-----
4608
4609- Added the `cargo add` command for adding dependencies to `Cargo.toml` from
4610 the command-line.
4611 [docs](https://doc.rust-lang.org/nightly/cargo/commands/cargo-add.html)
4612- Package ID specs now support `name@version` syntax in addition to the
4613 previous `name:version` to align with the behavior in `cargo add` and other
4614 tools. `cargo install` and `cargo yank` also now support this syntax so the
4615 version does not need to passed as a separate flag.
4616- The `git` and `registry` directories in Cargo's home directory (usually
4617 `~/.cargo`) are now marked as cache directories so that they are not
4618 included in backups or content indexing (on Windows).
4619- Added automatic `@` argfile support, which will use "response files" if the
4620 command-line to `rustc` exceeds the operating system's limit.
4621
4622Compatibility Notes
4623-------------------
4624
4625- `cargo test` now passes `--target` to `rustdoc` if the specified target is
4626 the same as the host target.
4627 [#10594](https://github.com/rust-lang/cargo/pull/10594)
4628- [rustdoc: doctests are now run on unexported `macro_rules!` macros, matching other private items][96630]
4629- [rustdoc: Remove .woff font files][96279]
4630- [Enforce Copy bounds for repeat elements while considering lifetimes][95819]
4631- [Windows: Fix potential unsoundness by aborting if `File` reads or writes cannot
4632 complete synchronously][95469].
4633
4634Internal Changes
4635----------------
4636
4637- [Unify ReentrantMutex implementations across all platforms][96042]
4638
4639These changes provide no direct user facing benefits, but represent significant
4640improvements to the internals and overall performance of rustc
4641and related tools.
4642
4643[93313]: https://github.com/rust-lang/rust/pull/93313/
4644[93969]: https://github.com/rust-lang/rust/pull/93969/
4645[94206]: https://github.com/rust-lang/rust/pull/94206/
4646[94457]: https://github.com/rust-lang/rust/pull/94457/
4647[94775]: https://github.com/rust-lang/rust/pull/94775/
4648[94872]: https://github.com/rust-lang/rust/pull/94872/
4649[95006]: https://github.com/rust-lang/rust/pull/95006/
4650[95035]: https://github.com/rust-lang/rust/pull/95035/
4651[95346]: https://github.com/rust-lang/rust/pull/95346/
4652[95372]: https://github.com/rust-lang/rust/pull/95372/
4653[95380]: https://github.com/rust-lang/rust/pull/95380/
4654[95431]: https://github.com/rust-lang/rust/pull/95431/
4655[95469]: https://github.com/rust-lang/rust/pull/95469/
4656[95705]: https://github.com/rust-lang/rust/pull/95705/
4657[95801]: https://github.com/rust-lang/rust/pull/95801/
4658[95819]: https://github.com/rust-lang/rust/pull/95819/
4659[95841]: https://github.com/rust-lang/rust/pull/95841/
4660[96042]: https://github.com/rust-lang/rust/pull/96042/
4661[96150]: https://github.com/rust-lang/rust/pull/96150/
4662[96268]: https://github.com/rust-lang/rust/pull/96268/
4663[96279]: https://github.com/rust-lang/rust/pull/96279/
4664[96393]: https://github.com/rust-lang/rust/pull/96393/
4665[96436]: https://github.com/rust-lang/rust/pull/96436/
4666[96557]: https://github.com/rust-lang/rust/pull/96557/
4667[96630]: https://github.com/rust-lang/rust/pull/96630/
4668
4669[`bool::then_some`]: https://doc.rust-lang.org/stable/std/primitive.bool.html#method.then_some
4670[`f32::total_cmp`]: https://doc.rust-lang.org/stable/std/primitive.f32.html#method.total_cmp
4671[`f64::total_cmp`]: https://doc.rust-lang.org/stable/std/primitive.f64.html#method.total_cmp
4672[`Stdin::lines`]: https://doc.rust-lang.org/stable/std/io/struct.Stdin.html#method.lines
4673[`impl<T: Default> Default for AssertUnwindSafe<T>`]: https://doc.rust-lang.org/stable/std/panic/struct.AssertUnwindSafe.html#impl-Default
4674[rc-u8-from-str]: https://doc.rust-lang.org/stable/std/rc/struct.Rc.html#impl-From%3CRc%3Cstr%3E%3E
4675[arc-u8-from-str]: https://doc.rust-lang.org/stable/std/sync/struct.Arc.html#impl-From%3CArc%3Cstr%3E%3E
4676[stdarch/1285]: https://github.com/rust-lang/stdarch/pull/1285
4677[`windows::CommandExt::raw_arg`]: https://doc.rust-lang.org/stable/std/os/windows/process/trait.CommandExt.html#tymethod.raw_arg
4678[`FusedIterator for EncodeWide`]: https://doc.rust-lang.org/stable/std/os/windows/ffi/struct.EncodeWide.html#impl-FusedIterator
4679
4680Version 1.61.0 (2022-05-19)
4681==========================
4682
4683Language
4684--------
4685
4686- [`const fn` signatures can now include generic trait bounds][93827]
4687- [`const fn` signatures can now use `impl Trait` in argument and return position][93827]
4688- [Function pointers can now be created, cast, and passed around in a `const fn`][93827]
4689- [Recursive calls can now set the value of a function's opaque `impl Trait` return type][94081]
4690
4691Compiler
4692--------
4693
4694- [Linking modifier syntax in `#[link]` attributes and on the command line, as well as the `whole-archive` modifier specifically, are now supported][93901]
4695- [The `char` type is now described as UTF-32 in debuginfo][89887]
4696- The [`#[target_feature]`][target_feature] attribute [can now be used with aarch64 features][90621]
4697- X86 [`#[target_feature = "adx"]` is now stable][93745]
4698
4699Libraries
4700---------
4701
4702- [`ManuallyDrop<T>` is now documented to have the same layout as `T`][88375]
4703- [`#[ignore = "…"]` messages are printed when running tests][92714]
4704- [Consistently show absent stdio handles on Windows as NULL handles][93263]
4705- [Make `std::io::stdio::lock()` return `'static` handles.][93965] Previously, the creation of locked handles to stdin/stdout/stderr would borrow the handles being locked, which prevented writing `let out = std::io::stdout().lock();` because `out` would outlive the return value of `stdout()`. Such code now works, eliminating a common pitfall that affected many Rust users.
4706- [`Vec::from_raw_parts` is now less restrictive about its inputs][95016]
4707- [`std::thread::available_parallelism` now takes cgroup quotas into account.][92697] Since `available_parallelism` is often used to create a thread pool for parallel computation, which may be CPU-bound for performance, `available_parallelism` will return a value consistent with the ability to use that many threads continuously, if possible. For instance, in a container with 8 virtual CPUs but quotas only allowing for 50% usage, `available_parallelism` will return 4.
4708
4709Stabilized APIs
4710---------------
4711
4712- [`Pin::static_mut`]
4713- [`Pin::static_ref`]
4714- [`Vec::retain_mut`]
4715- [`VecDeque::retain_mut`]
4716- [`Write` for `Cursor<[u8; N]>`][cursor-write-array]
4717- [`std::os::unix::net::SocketAddr::from_pathname`]
4718- [`std::process::ExitCode`] and [`std::process::Termination`]. The stabilization of these two APIs now makes it possible for programs to return errors from `main` with custom exit codes.
4719- [`std::thread::JoinHandle::is_finished`]
4720
4721These APIs are now usable in const contexts:
4722
4723- [`<*const T>::offset` and `<*mut T>::offset`][ptr-offset]
4724- [`<*const T>::wrapping_offset` and `<*mut T>::wrapping_offset`][ptr-wrapping_offset]
4725- [`<*const T>::add` and `<*mut T>::add`][ptr-add]
4726- [`<*const T>::sub` and `<*mut T>::sub`][ptr-sub]
4727- [`<*const T>::wrapping_add` and `<*mut T>::wrapping_add`][ptr-wrapping_add]
4728- [`<*const T>::wrapping_sub` and `<*mut T>::wrapping_sub`][ptr-wrapping_sub]
4729- [`<[T]>::as_mut_ptr`][slice-as_mut_ptr]
4730- [`<[T]>::as_ptr_range`][slice-as_ptr_range]
4731- [`<[T]>::as_mut_ptr_range`][slice-as_mut_ptr_range]
4732
4733Cargo
4734-----
4735
4736No feature changes, but see compatibility notes.
4737
4738Compatibility Notes
4739-------------------
4740
4741- Previously native static libraries were linked as `whole-archive` in some cases, but now rustc tries not to use `whole-archive` unless explicitly requested. This [change][93901] may result in linking errors in some cases. To fix such errors, native libraries linked from the command line, build scripts, or [`#[link]` attributes][link-attr] need to
4742 - (more common) either be reordered to respect dependencies between them (if `a` depends on `b` then `a` should go first and `b` second)
4743 - (less common) or be updated to use the [`+whole-archive`] modifier.
4744- [Catching a second unwind from FFI code while cleaning up from a Rust panic now causes the process to abort][92911]
4745- [Proc macros no longer see `ident` matchers wrapped in groups][92472]
4746- [The number of `#` in `r#` raw string literals is now required to be less than 256][95251]
4747- [When checking that a dyn type satisfies a trait bound, supertrait bounds are now enforced][92285]
4748- [`cargo vendor` now only accepts one value for each `--sync` flag][cargo/10448]
4749- [`cfg` predicates in `all()` and `any()` are always evaluated to detect errors, instead of short-circuiting.][94295] The compatibility considerations here arise in nightly-only code that used the short-circuiting behavior of `all` to write something like `cfg(all(feature = "nightly", syntax-requiring-nightly))`, which will now fail to compile. Instead, use either `cfg_attr(feature = "nightly", ...)` or nested uses of `cfg`.
4750- [bootstrap: static-libstdcpp is now enabled by default, and can now be disabled when llvm-tools is enabled][94832]
4751
4752Internal Changes
4753----------------
4754
4755These changes provide no direct user facing benefits, but represent significant
4756improvements to the internals and overall performance of rustc
4757and related tools.
4758
4759- [debuginfo: Refactor debuginfo generation for types][94261]
4760- [Remove the everybody loops pass][93913]
4761
4762[88375]: https://github.com/rust-lang/rust/pull/88375/
4763[89887]: https://github.com/rust-lang/rust/pull/89887/
4764[90621]: https://github.com/rust-lang/rust/pull/90621/
4765[92285]: https://github.com/rust-lang/rust/pull/92285/
4766[92472]: https://github.com/rust-lang/rust/pull/92472/
4767[92697]: https://github.com/rust-lang/rust/pull/92697/
4768[92714]: https://github.com/rust-lang/rust/pull/92714/
4769[92911]: https://github.com/rust-lang/rust/pull/92911/
4770[93263]: https://github.com/rust-lang/rust/pull/93263/
4771[93745]: https://github.com/rust-lang/rust/pull/93745/
4772[93827]: https://github.com/rust-lang/rust/pull/93827/
4773[93901]: https://github.com/rust-lang/rust/pull/93901/
4774[93913]: https://github.com/rust-lang/rust/pull/93913/
4775[93965]: https://github.com/rust-lang/rust/pull/93965/
4776[94081]: https://github.com/rust-lang/rust/pull/94081/
4777[94261]: https://github.com/rust-lang/rust/pull/94261/
4778[94295]: https://github.com/rust-lang/rust/pull/94295/
4779[94832]: https://github.com/rust-lang/rust/pull/94832/
4780[95016]: https://github.com/rust-lang/rust/pull/95016/
4781[95251]: https://github.com/rust-lang/rust/pull/95251/
4782[`+whole-archive`]: https://doc.rust-lang.org/stable/rustc/command-line-arguments.html#linking-modifiers-whole-archive
4783[`Pin::static_mut`]: https://doc.rust-lang.org/stable/std/pin/struct.Pin.html#method.static_mut
4784[`Pin::static_ref`]: https://doc.rust-lang.org/stable/std/pin/struct.Pin.html#method.static_ref
4785[`Vec::retain_mut`]: https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.retain_mut
4786[`VecDeque::retain_mut`]: https://doc.rust-lang.org/stable/std/collections/struct.VecDeque.html#method.retain_mut
4787[`std::os::unix::net::SocketAddr::from_pathname`]: https://doc.rust-lang.org/stable/std/os/unix/net/struct.SocketAddr.html#method.from_pathname
4788[`std::process::ExitCode`]: https://doc.rust-lang.org/stable/std/process/struct.ExitCode.html
4789[`std::process::Termination`]: https://doc.rust-lang.org/stable/std/process/trait.Termination.html
4790[`std::thread::JoinHandle::is_finished`]: https://doc.rust-lang.org/stable/std/thread/struct.JoinHandle.html#method.is_finished
4791[cargo/10448]: https://github.com/rust-lang/cargo/pull/10448/
4792[cursor-write-array]: https://doc.rust-lang.org/stable/std/io/struct.Cursor.html#impl-Write-4
4793[link-attr]: https://doc.rust-lang.org/stable/reference/items/external-blocks.html#the-link-attribute
4794[ptr-add]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.add
4795[ptr-offset]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.offset
4796[ptr-sub]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.sub
4797[ptr-wrapping_add]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.wrapping_add
4798[ptr-wrapping_offset]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.wrapping_offset
4799[ptr-wrapping_sub]: https://doc.rust-lang.org/stable/std/primitive.pointer.html#method.wrapping_sub
4800[slice-as_mut_ptr]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_mut_ptr
4801[slice-as_mut_ptr_range]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_mut_ptr_range
4802[slice-as_ptr_range]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.as_ptr_range
4803[target_feature]: https://doc.rust-lang.org/reference/attributes/codegen.html#the-target_feature-attribute
4804
4805
4806Version 1.60.0 (2022-04-07)
4807==========================
4808
4809Language
4810--------
4811- [Stabilize `#[cfg(panic = "...")]` for either `"unwind"` or `"abort"`.][93658]
4812- [Stabilize `#[cfg(target_has_atomic = "...")]` for each integer size and `"ptr"`.][93824]
4813
4814Compiler
4815--------
4816- [Enable combining `+crt-static` and `relocation-model=pic` on `x86_64-unknown-linux-gnu`][86374]
4817- [Fixes wrong `unreachable_pub` lints on nested and glob public reexport][87487]
4818- [Stabilize `-Z instrument-coverage` as `-C instrument-coverage`][90132]
4819- [Stabilize `-Z print-link-args` as `--print link-args`][91606]
4820- [Add new Tier 3 target `mips64-openwrt-linux-musl`\*][92300]
4821- [Add new Tier 3 target `armv7-unknown-linux-uclibceabi` (softfloat)\*][92383]
4822- [Fix invalid removal of newlines from doc comments][92357]
4823- [Add kernel target for RustyHermit][92670]
4824- [Deny mixing bin crate type with lib crate types][92933]
4825- [Make rustc use `RUST_BACKTRACE=full` by default][93566]
4826- [Upgrade to LLVM 14][93577]
4827
4828\* Refer to Rust's [platform support page][platform-support-doc] for more
4829 information on Rust's tiered platform support.
4830
4831Libraries
4832---------
4833- [Guarantee call order for `sort_by_cached_key`][89621]
4834- [Improve `Duration::try_from_secs_f32`/`f64` accuracy by directly processing exponent and mantissa][90247]
4835- [Make `Instant::{duration_since, elapsed, sub}` saturating][89926]
4836- [Remove non-monotonic clocks workarounds in `Instant::now`][89926]
4837- [Make `BuildHasherDefault`, `iter::Empty` and `future::Pending` covariant][92630]
4838
4839Stabilized APIs
4840---------------
4841- [`Arc::new_cyclic`][arc_new_cyclic]
4842- [`Rc::new_cyclic`][rc_new_cyclic]
4843- [`slice::EscapeAscii`][slice_escape_ascii]
4844- [`<[u8]>::escape_ascii`][slice_u8_escape_ascii]
4845- [`u8::escape_ascii`][u8_escape_ascii]
4846- [`Vec::spare_capacity_mut`][vec_spare_capacity_mut]
4847- [`MaybeUninit::assume_init_drop`][assume_init_drop]
4848- [`MaybeUninit::assume_init_read`][assume_init_read]
4849- [`i8::abs_diff`][i8_abs_diff]
4850- [`i16::abs_diff`][i16_abs_diff]
4851- [`i32::abs_diff`][i32_abs_diff]
4852- [`i64::abs_diff`][i64_abs_diff]
4853- [`i128::abs_diff`][i128_abs_diff]
4854- [`isize::abs_diff`][isize_abs_diff]
4855- [`u8::abs_diff`][u8_abs_diff]
4856- [`u16::abs_diff`][u16_abs_diff]
4857- [`u32::abs_diff`][u32_abs_diff]
4858- [`u64::abs_diff`][u64_abs_diff]
4859- [`u128::abs_diff`][u128_abs_diff]
4860- [`usize::abs_diff`][usize_abs_diff]
4861- [`Display for io::ErrorKind`][display_error_kind]
4862- [`From<u8> for ExitCode`][from_u8_exit_code]
4863- [`Not for !` (the "never" type)][not_never]
4864- [_Op_`Assign<$t> for Wrapping<$t>`][wrapping_assign_ops]
4865- [`arch::is_aarch64_feature_detected!`][is_aarch64_feature_detected]
4866
4867Cargo
4868-----
4869- [Port cargo from `toml-rs` to `toml_edit`][cargo/10086]
4870- [Stabilize `-Ztimings` as `--timings`][cargo/10245]
4871- [Stabilize namespaced and weak dependency features.][cargo/10269]
4872- [Accept more `cargo:rustc-link-arg-*` types from build script output.][cargo/10274]
4873- [cargo-new should not add ignore rule on Cargo.lock inside subdirs][cargo/10379]
4874
4875Misc
4876----
4877- [Ship docs on Tier 2 platforms by reusing the closest Tier 1 platform docs][92800]
4878- [Drop rustc-docs from complete profile][93742]
4879- [bootstrap: tidy up flag handling for llvm build][93918]
4880
4881Compatibility Notes
4882-------------------
4883- [Remove compiler-rt linking hack on Android][83822]
4884- [Mitigations for platforms with non-monotonic clocks have been removed from
4885 `Instant::now`][89926]. On platforms that don't provide monotonic clocks, an
4886 instant is not guaranteed to be greater than an earlier instant anymore.
4887- [`Instant::{duration_since, elapsed, sub}` do not panic anymore on underflow,
4888 saturating to `0` instead][89926]. In the real world the panic happened mostly
4889 on platforms with buggy monotonic clock implementations rather than catching
4890 programming errors like reversing the start and end times. Such programming
4891 errors will now result in `0` rather than a panic.
4892- In a future release we're planning to increase the baseline requirements for
4893 the Linux kernel to version 3.2, and for glibc to version 2.17. We'd love
4894 your feedback in [PR #95026][95026].
4895
4896Internal Changes
4897----------------
4898
4899These changes provide no direct user facing benefits, but represent significant
4900improvements to the internals and overall performance of rustc
4901and related tools.
4902
4903- [Switch all libraries to the 2021 edition][92068]
4904
4905[83822]: https://github.com/rust-lang/rust/pull/83822
4906[86374]: https://github.com/rust-lang/rust/pull/86374
4907[87487]: https://github.com/rust-lang/rust/pull/87487
4908[89621]: https://github.com/rust-lang/rust/pull/89621
4909[89926]: https://github.com/rust-lang/rust/pull/89926
4910[90132]: https://github.com/rust-lang/rust/pull/90132
4911[90247]: https://github.com/rust-lang/rust/pull/90247
4912[91606]: https://github.com/rust-lang/rust/pull/91606
4913[92068]: https://github.com/rust-lang/rust/pull/92068
4914[92300]: https://github.com/rust-lang/rust/pull/92300
4915[92357]: https://github.com/rust-lang/rust/pull/92357
4916[92383]: https://github.com/rust-lang/rust/pull/92383
4917[92630]: https://github.com/rust-lang/rust/pull/92630
4918[92670]: https://github.com/rust-lang/rust/pull/92670
4919[92800]: https://github.com/rust-lang/rust/pull/92800
4920[92933]: https://github.com/rust-lang/rust/pull/92933
4921[93566]: https://github.com/rust-lang/rust/pull/93566
4922[93577]: https://github.com/rust-lang/rust/pull/93577
4923[93658]: https://github.com/rust-lang/rust/pull/93658
4924[93742]: https://github.com/rust-lang/rust/pull/93742
4925[93824]: https://github.com/rust-lang/rust/pull/93824
4926[93918]: https://github.com/rust-lang/rust/pull/93918
4927[95026]: https://github.com/rust-lang/rust/pull/95026
4928
4929[cargo/10086]: https://github.com/rust-lang/cargo/pull/10086
4930[cargo/10245]: https://github.com/rust-lang/cargo/pull/10245
4931[cargo/10269]: https://github.com/rust-lang/cargo/pull/10269
4932[cargo/10274]: https://github.com/rust-lang/cargo/pull/10274
4933[cargo/10379]: https://github.com/rust-lang/cargo/pull/10379
4934
4935[arc_new_cyclic]: https://doc.rust-lang.org/stable/std/sync/struct.Arc.html#method.new_cyclic
4936[rc_new_cyclic]: https://doc.rust-lang.org/stable/std/rc/struct.Rc.html#method.new_cyclic
4937[slice_escape_ascii]: https://doc.rust-lang.org/stable/std/slice/struct.EscapeAscii.html
4938[slice_u8_escape_ascii]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.escape_ascii
4939[u8_escape_ascii]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.escape_ascii
4940[vec_spare_capacity_mut]: https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.spare_capacity_mut
4941[assume_init_drop]: https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#method.assume_init_drop
4942[assume_init_read]: https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#method.assume_init_read
4943[i8_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.abs_diff
4944[i16_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.abs_diff
4945[i32_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.abs_diff
4946[i64_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.abs_diff
4947[i128_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.i128.html#method.abs_diff
4948[isize_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.abs_diff
4949[u8_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.abs_diff
4950[u16_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.abs_diff
4951[u32_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.abs_diff
4952[u64_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.abs_diff
4953[u128_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.u128.html#method.abs_diff
4954[usize_abs_diff]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.abs_diff
4955[display_error_kind]: https://doc.rust-lang.org/stable/std/io/enum.ErrorKind.html#impl-Display
4956[from_u8_exit_code]: https://doc.rust-lang.org/stable/std/process/struct.ExitCode.html#impl-From%3Cu8%3E
4957[not_never]: https://doc.rust-lang.org/stable/std/primitive.never.html#impl-Not
4958[wrapping_assign_ops]: https://doc.rust-lang.org/stable/std/num/struct.Wrapping.html#trait-implementations
4959[is_aarch64_feature_detected]: https://doc.rust-lang.org/stable/std/arch/macro.is_aarch64_feature_detected.html
4960
4961Version 1.59.0 (2022-02-24)
4962==========================
4963
4964Language
4965--------
4966
4967- [Stabilize default arguments for const parameters and remove the ordering restriction for type and const parameters][90207]
4968- [Stabilize destructuring assignment][90521]
4969- [Relax private in public lint on generic bounds and where clauses of trait impls][90586]
4970- [Stabilize asm! and global_asm! for x86, x86_64, ARM, Aarch64, and RISC-V][91728]
4971
4972Compiler
4973--------
4974
4975- [Stabilize new symbol mangling format, leaving it opt-in (-Csymbol-mangling-version=v0)][90128]
4976- [Emit LLVM optimization remarks when enabled with `-Cremark`][90833]
4977- [Fix sparc64 ABI for aggregates with floating point members][91003]
4978- [Warn when a `#[test]`-like built-in attribute macro is present multiple times.][91172]
4979- [Add support for riscv64gc-unknown-freebsd][91284]
4980- [Stabilize `-Z emit-future-incompat` as `--json future-incompat`][91535]
4981- [Soft disable incremental compilation][94124]
4982
4983This release disables incremental compilation, unless the user has explicitly
4984opted in via the newly added RUSTC_FORCE_INCREMENTAL=1 environment variable.
4985This is due to a known and relatively frequently occurring bug in incremental
4986compilation, which causes builds to issue internal compiler errors. This
4987particular bug is already fixed on nightly, but that fix has not yet rolled out
4988to stable and is deemed too risky for a direct stable backport.
4989
4990As always, we encourage users to test with nightly and report bugs so that we
4991can track failures and fix issues earlier.
4992
4993See [94124] for more details.
4994
4995[94124]: https://github.com/rust-lang/rust/issues/94124
4996
4997Libraries
4998---------
4999
5000- [Remove unnecessary bounds for some Hash{Map,Set} methods][91593]
5001
5002Stabilized APIs
5003---------------
5004
5005- [`std::thread::available_parallelism`][available_parallelism]
5006- [`Result::copied`][result-copied]
5007- [`Result::cloned`][result-cloned]
5008- [`arch::asm!`][asm]
5009- [`arch::global_asm!`][global_asm]
5010- [`ops::ControlFlow::is_break`][is_break]
5011- [`ops::ControlFlow::is_continue`][is_continue]
5012- [`TryFrom<char> for u8`][try_from_char_u8]
5013- [`char::TryFromCharError`][try_from_char_err]
5014 implementing `Clone`, `Debug`, `Display`, `PartialEq`, `Copy`, `Eq`, `Error`
5015- [`iter::zip`][zip]
5016- [`NonZeroU8::is_power_of_two`][is_power_of_two8]
5017- [`NonZeroU16::is_power_of_two`][is_power_of_two16]
5018- [`NonZeroU32::is_power_of_two`][is_power_of_two32]
5019- [`NonZeroU64::is_power_of_two`][is_power_of_two64]
5020- [`NonZeroU128::is_power_of_two`][is_power_of_two128]
5021- [`NonZeroUsize::is_power_of_two`][is_power_of_two_usize]
5022- [`DoubleEndedIterator for ToLowercase`][lowercase]
5023- [`DoubleEndedIterator for ToUppercase`][uppercase]
5024- [`TryFrom<&mut [T]> for [T; N]`][tryfrom_ref_arr]
5025- [`UnwindSafe for Once`][unwindsafe_once]
5026- [`RefUnwindSafe for Once`][refunwindsafe_once]
5027- [armv8 neon intrinsics for aarch64][stdarch/1266]
5028
5029Const-stable:
5030
5031- [`mem::MaybeUninit::as_ptr`][muninit_ptr]
5032- [`mem::MaybeUninit::assume_init`][muninit_init]
5033- [`mem::MaybeUninit::assume_init_ref`][muninit_init_ref]
5034- [`ffi::CStr::from_bytes_with_nul_unchecked`][cstr_from_bytes]
5035
5036Cargo
5037-----
5038
5039- [Stabilize the `strip` profile option][cargo/10088]
5040- [Stabilize future-incompat-report][cargo/10165]
5041- [Support abbreviating `--release` as `-r`][cargo/10133]
5042- [Support `term.quiet` configuration][cargo/10152]
5043- [Remove `--host` from cargo {publish,search,login}][cargo/10145]
5044
5045Compatibility Notes
5046-------------------
5047
5048- [Refactor weak symbols in std::sys::unix][90846]
5049 This may add new, versioned, symbols when building with a newer glibc, as the
5050 standard library uses weak linkage rather than dynamically attempting to load
5051 certain symbols at runtime.
5052- [Deprecate crate_type and crate_name nested inside `#![cfg_attr]`][83744]
5053 This adds a future compatibility lint to supporting the use of cfg_attr
5054 wrapping either crate_type or crate_name specification within Rust files;
5055 it is recommended that users migrate to setting the equivalent command line
5056 flags.
5057- [Remove effect of `#[no_link]` attribute on name resolution][92034]
5058 This may expose new names, leading to conflicts with preexisting names in a
5059 given namespace and a compilation failure.
5060- [Cargo will document libraries before binaries.][cargo/10172]
5061- [Respect doc=false in dependencies, not just the root crate][cargo/10201]
5062- [Weaken guarantee around advancing underlying iterators in zip][83791]
5063- [Make split_inclusive() on an empty slice yield an empty output][89825]
5064- [Update std::env::temp_dir to use GetTempPath2 on Windows when available.][89999]
5065- [unreachable! was updated to match other formatting macro behavior on Rust 2021][92137]
5066
5067Internal Changes
5068----------------
5069
5070These changes provide no direct user facing benefits, but represent significant
5071improvements to the internals and overall performance of rustc
5072and related tools.
5073
5074- [Fix many cases of normalization-related ICEs][91255]
5075- [Replace dominators algorithm with simple Lengauer-Tarjan][85013]
5076- [Store liveness in interval sets for region inference][90637]
5077
5078- [Remove `in_band_lifetimes` from the compiler and standard library, in preparation for removing this
5079 unstable feature.][91867]
5080
5081[91867]: https://github.com/rust-lang/rust/issues/91867
5082[83744]: https://github.com/rust-lang/rust/pull/83744/
5083[83791]: https://github.com/rust-lang/rust/pull/83791/
5084[85013]: https://github.com/rust-lang/rust/pull/85013/
5085[89825]: https://github.com/rust-lang/rust/pull/89825/
5086[89999]: https://github.com/rust-lang/rust/pull/89999/
5087[90128]: https://github.com/rust-lang/rust/pull/90128/
5088[90207]: https://github.com/rust-lang/rust/pull/90207/
5089[90521]: https://github.com/rust-lang/rust/pull/90521/
5090[90586]: https://github.com/rust-lang/rust/pull/90586/
5091[90637]: https://github.com/rust-lang/rust/pull/90637/
5092[90833]: https://github.com/rust-lang/rust/pull/90833/
5093[90846]: https://github.com/rust-lang/rust/pull/90846/
5094[91003]: https://github.com/rust-lang/rust/pull/91003/
5095[91172]: https://github.com/rust-lang/rust/pull/91172/
5096[91255]: https://github.com/rust-lang/rust/pull/91255/
5097[91284]: https://github.com/rust-lang/rust/pull/91284/
5098[91535]: https://github.com/rust-lang/rust/pull/91535/
5099[91593]: https://github.com/rust-lang/rust/pull/91593/
5100[91728]: https://github.com/rust-lang/rust/pull/91728/
5101[91878]: https://github.com/rust-lang/rust/pull/91878/
5102[91896]: https://github.com/rust-lang/rust/pull/91896/
5103[91926]: https://github.com/rust-lang/rust/pull/91926/
5104[91984]: https://github.com/rust-lang/rust/pull/91984/
5105[92020]: https://github.com/rust-lang/rust/pull/92020/
5106[92034]: https://github.com/rust-lang/rust/pull/92034/
5107[92137]: https://github.com/rust-lang/rust/pull/92137/
5108[92483]: https://github.com/rust-lang/rust/pull/92483/
5109[cargo/10088]: https://github.com/rust-lang/cargo/pull/10088/
5110[cargo/10133]: https://github.com/rust-lang/cargo/pull/10133/
5111[cargo/10145]: https://github.com/rust-lang/cargo/pull/10145/
5112[cargo/10152]: https://github.com/rust-lang/cargo/pull/10152/
5113[cargo/10165]: https://github.com/rust-lang/cargo/pull/10165/
5114[cargo/10172]: https://github.com/rust-lang/cargo/pull/10172/
5115[cargo/10201]: https://github.com/rust-lang/cargo/pull/10201/
5116[cargo/10269]: https://github.com/rust-lang/cargo/pull/10269/
5117
5118[cstr_from_bytes]: https://doc.rust-lang.org/stable/std/ffi/struct.CStr.html#method.from_bytes_with_nul_unchecked
5119[muninit_ptr]: https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#method.as_ptr
5120[muninit_init]: https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#method.assume_init
5121[muninit_init_ref]: https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#method.assume_init_ref
5122[unwindsafe_once]: https://doc.rust-lang.org/stable/std/sync/struct.Once.html#impl-UnwindSafe
5123[refunwindsafe_once]: https://doc.rust-lang.org/stable/std/sync/struct.Once.html#impl-RefUnwindSafe
5124[tryfrom_ref_arr]: https://doc.rust-lang.org/stable/std/convert/trait.TryFrom.html#impl-TryFrom%3C%26%27_%20mut%20%5BT%5D%3E
5125[lowercase]: https://doc.rust-lang.org/stable/std/char/struct.ToLowercase.html#impl-DoubleEndedIterator
5126[uppercase]: https://doc.rust-lang.org/stable/std/char/struct.ToUppercase.html#impl-DoubleEndedIterator
5127[try_from_char_err]: https://doc.rust-lang.org/stable/std/char/struct.TryFromCharError.html
5128[available_parallelism]: https://doc.rust-lang.org/stable/std/thread/fn.available_parallelism.html
5129[result-copied]: https://doc.rust-lang.org/stable/std/result/enum.Result.html#method.copied
5130[result-cloned]: https://doc.rust-lang.org/stable/std/result/enum.Result.html#method.cloned
5131[asm]: https://doc.rust-lang.org/stable/core/arch/macro.asm.html
5132[global_asm]: https://doc.rust-lang.org/stable/core/arch/macro.global_asm.html
5133[is_break]: https://doc.rust-lang.org/stable/std/ops/enum.ControlFlow.html#method.is_break
5134[is_continue]: https://doc.rust-lang.org/stable/std/ops/enum.ControlFlow.html#method.is_continue
5135[try_from_char_u8]: https://doc.rust-lang.org/stable/std/primitive.char.html#impl-TryFrom%3Cchar%3E
5136[zip]: https://doc.rust-lang.org/stable/std/iter/fn.zip.html
5137[is_power_of_two8]: https://doc.rust-lang.org/stable/core/num/struct.NonZeroU8.html#method.is_power_of_two
5138[is_power_of_two16]: https://doc.rust-lang.org/stable/core/num/struct.NonZeroU16.html#method.is_power_of_two
5139[is_power_of_two32]: https://doc.rust-lang.org/stable/core/num/struct.NonZeroU32.html#method.is_power_of_two
5140[is_power_of_two64]: https://doc.rust-lang.org/stable/core/num/struct.NonZeroU64.html#method.is_power_of_two
5141[is_power_of_two128]: https://doc.rust-lang.org/stable/core/num/struct.NonZeroU128.html#method.is_power_of_two
5142[is_power_of_two_usize]: https://doc.rust-lang.org/stable/core/num/struct.NonZeroUsize.html#method.is_power_of_two
5143[stdarch/1266]: https://github.com/rust-lang/stdarch/pull/1266
5144
5145Version 1.58.1 (2022-01-20)
5146===========================
5147
5148* Fix race condition in `std::fs::remove_dir_all` ([CVE-2022-21658])
5149* [Handle captured arguments in the `useless_format` Clippy lint][clippy/8295]
5150* [Move `non_send_fields_in_send_ty` Clippy lint to nursery][clippy/8075]
5151* [Fix wrong error message displayed when some imports are missing][91254]
5152* [Fix rustfmt not formatting generated files from stdin][92912]
5153
5154[CVE-2022-21658]: https://www.cve.org/CVERecord?id=CVE-2022-21658
5155[91254]: https://github.com/rust-lang/rust/pull/91254
5156[92912]: https://github.com/rust-lang/rust/pull/92912
5157[clippy/8075]: https://github.com/rust-lang/rust-clippy/pull/8075
5158[clippy/8295]: https://github.com/rust-lang/rust-clippy/pull/8295
5159
5160Version 1.58.0 (2022-01-13)
5161==========================
5162
5163Language
5164--------
5165
5166- [Format strings can now capture arguments simply by writing `{ident}` in the string.][90473] This works in all macros accepting format strings. Support for this in `panic!` (`panic!("{ident}")`) requires the 2021 edition; panic invocations in previous editions that appear to be trying to use this will result in a warning lint about not having the intended effect.
5167- [`*const T` pointers can now be dereferenced in const contexts.][89551]
5168- [The rules for when a generic struct implements `Unsize` have been relaxed.][90417]
5169
5170Compiler
5171--------
5172
5173- [Add LLVM CFI support to the Rust compiler][89652]
5174- [Stabilize -Z strip as -C strip][90058]. Note that while release builds already don't add debug symbols for the code you compile, the compiled standard library that ships with Rust includes debug symbols, so you may want to use the `strip` option to remove these symbols to produce smaller release binaries. Note that this release only includes support in rustc, not directly in cargo.
5175- [Add support for LLVM coverage mapping format versions 5 and 6][91207]
5176- [Emit LLVM optimization remarks when enabled with `-Cremark`][90833]
5177- [Update the minimum external LLVM to 12][90175]
5178- [Add `x86_64-unknown-none` at Tier 3*][89062]
5179- [Build musl dist artifacts with debuginfo enabled][90733]. When building release binaries using musl, you may want to use the newly stabilized strip option to remove these debug symbols, reducing the size of your binaries.
5180- [Don't abort compilation after giving a lint error][87337]
5181- [Error messages point at the source of trait bound obligations in more places][89580]
5182
5183\* Refer to Rust's [platform support page][platform-support-doc] for more
5184 information on Rust's tiered platform support.
5185
5186Libraries
5187---------
5188
5189- [All remaining functions in the standard library have `#[must_use]` annotations where appropriate][89692], producing a warning when ignoring their return value. This helps catch mistakes such as expecting a function to mutate a value in place rather than return a new value.
5190- [Paths are automatically canonicalized on Windows for operations that support it][89174]
5191- [Re-enable debug checks for `copy` and `copy_nonoverlapping`][90041]
5192- [Implement `RefUnwindSafe` for `Rc<T>`][87467]
5193- [Make RSplit<T, P>: Clone not require T: Clone][90117]
5194- [Implement `Termination` for `Result<Infallible, E>`][88601]. This allows writing `fn main() -> Result<Infallible, ErrorType>`, for a program whose successful exits never involve returning from `main` (for instance, a program that calls `exit`, or that uses `exec` to run another program).
5195
5196Stabilized APIs
5197---------------
5198
5199- [`Metadata::is_symlink`]
5200- [`Path::is_symlink`]
5201- [`{integer}::saturating_div`]
5202- [`Option::unwrap_unchecked`]
5203- [`Result::unwrap_unchecked`]
5204- [`Result::unwrap_err_unchecked`]
5205- [`File::options`]
5206
5207These APIs are now usable in const contexts:
5208
5209- [`Duration::new`]
5210- [`Duration::checked_add`]
5211- [`Duration::saturating_add`]
5212- [`Duration::checked_sub`]
5213- [`Duration::saturating_sub`]
5214- [`Duration::checked_mul`]
5215- [`Duration::saturating_mul`]
5216- [`Duration::checked_div`]
5217
5218Cargo
5219-----
5220
5221- [Add --message-format for install command][cargo/10107]
5222- [Warn when alias shadows external subcommand][cargo/10082]
5223
5224Rustdoc
5225-------
5226
5227- [Show all Deref implementations recursively in rustdoc][90183]
5228- [Use computed visibility in rustdoc][88447]
5229
5230Compatibility Notes
5231-------------------
5232
5233- [Try all stable method candidates first before trying unstable ones][90329]. This change ensures that adding new nightly-only methods to the Rust standard library will not break code invoking methods of the same name from traits outside the standard library.
5234- Windows: [`std::process::Command` will no longer search the current directory for executables.][87704]
5235- [All proc-macro backward-compatibility lints are now deny-by-default.][88041]
5236- [proc_macro: Append .0 to unsuffixed float if it would otherwise become int token][90297]
5237- [Refactor weak symbols in std::sys::unix][90846]. This optimizes accesses to glibc functions, by avoiding the use of dlopen. This does not increase the [minimum expected version of glibc](https://doc.rust-lang.org/nightly/rustc/platform-support.html). However, software distributions that use symbol versions to detect library dependencies, and which take weak symbols into account in that analysis, may detect rust binaries as requiring newer versions of glibc.
5238- [rustdoc now rejects some unexpected semicolons in doctests][91026]
5239
5240Internal Changes
5241----------------
5242
5243These changes provide no direct user facing benefits, but represent significant
5244improvements to the internals and overall performance of rustc
5245and related tools.
5246
5247- [Implement coherence checks for negative trait impls][90104]
5248- [Add rustc lint, warning when iterating over hashmaps][89558]
5249- [Optimize live point computation][90491]
5250- [Enable verification for 1/32nd of queries loaded from disk][90361]
5251- [Implement version of normalize_erasing_regions that allows for normalization failure][91255]
5252
5253[87337]: https://github.com/rust-lang/rust/pull/87337/
5254[87467]: https://github.com/rust-lang/rust/pull/87467/
5255[87704]: https://github.com/rust-lang/rust/pull/87704/
5256[88041]: https://github.com/rust-lang/rust/pull/88041/
5257[88447]: https://github.com/rust-lang/rust/pull/88447/
5258[88601]: https://github.com/rust-lang/rust/pull/88601/
5259[89062]: https://github.com/rust-lang/rust/pull/89062/
5260[89174]: https://github.com/rust-lang/rust/pull/89174/
5261[89551]: https://github.com/rust-lang/rust/pull/89551/
5262[89558]: https://github.com/rust-lang/rust/pull/89558/
5263[89580]: https://github.com/rust-lang/rust/pull/89580/
5264[89652]: https://github.com/rust-lang/rust/pull/89652/
5265[90041]: https://github.com/rust-lang/rust/pull/90041/
5266[90058]: https://github.com/rust-lang/rust/pull/90058/
5267[90104]: https://github.com/rust-lang/rust/pull/90104/
5268[90117]: https://github.com/rust-lang/rust/pull/90117/
5269[90175]: https://github.com/rust-lang/rust/pull/90175/
5270[90183]: https://github.com/rust-lang/rust/pull/90183/
5271[90297]: https://github.com/rust-lang/rust/pull/90297/
5272[90329]: https://github.com/rust-lang/rust/pull/90329/
5273[90361]: https://github.com/rust-lang/rust/pull/90361/
5274[90417]: https://github.com/rust-lang/rust/pull/90417/
5275[90473]: https://github.com/rust-lang/rust/pull/90473/
5276[90491]: https://github.com/rust-lang/rust/pull/90491/
5277[90733]: https://github.com/rust-lang/rust/pull/90733/
5278[90833]: https://github.com/rust-lang/rust/pull/90833/
5279[90846]: https://github.com/rust-lang/rust/pull/90846/
5280[91026]: https://github.com/rust-lang/rust/pull/91026/
5281[91207]: https://github.com/rust-lang/rust/pull/91207/
5282[91255]: https://github.com/rust-lang/rust/pull/91255/
5283[cargo/10082]: https://github.com/rust-lang/cargo/pull/10082/
5284[cargo/10107]: https://github.com/rust-lang/cargo/pull/10107/
5285[`Metadata::is_symlink`]: https://doc.rust-lang.org/stable/std/fs/struct.Metadata.html#method.is_symlink
5286[`Path::is_symlink`]: https://doc.rust-lang.org/stable/std/path/struct.Path.html#method.is_symlink
5287[`{integer}::saturating_div`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.saturating_div
5288[`Option::unwrap_unchecked`]: https://doc.rust-lang.org/stable/std/option/enum.Option.html#method.unwrap_unchecked
5289[`Result::unwrap_unchecked`]: https://doc.rust-lang.org/stable/std/result/enum.Result.html#method.unwrap_unchecked
5290[`Result::unwrap_err_unchecked`]: https://doc.rust-lang.org/stable/std/result/enum.Result.html#method.unwrap_err_unchecked
5291[`File::options`]: https://doc.rust-lang.org/stable/std/fs/struct.File.html#method.options
5292[`Duration::new`]: https://doc.rust-lang.org/stable/std/time/struct.Duration.html#method.new
5293
5294Version 1.57.0 (2021-12-02)
5295==========================
5296
5297Language
5298--------
5299
5300- [Macro attributes may follow `#[derive]` and will see the original (pre-`cfg`) input.][87220]
5301- [Accept curly-brace macros in expressions, like `m!{ .. }.method()` and `m!{ .. }?`.][88690]
5302- [Allow panicking in constant evaluation.][89508]
5303- [Ignore derived `Clone` and `Debug` implementations during dead code analysis.][85200]
5304
5305Compiler
5306--------
5307
5308- [Create more accurate debuginfo for vtables.][89597]
5309- [Add `armv6k-nintendo-3ds` at Tier 3\*.][88529]
5310- [Add `armv7-unknown-linux-uclibceabihf` at Tier 3\*.][88952]
5311- [Add `m68k-unknown-linux-gnu` at Tier 3\*.][88321]
5312- [Add SOLID targets at Tier 3\*:][86191] `aarch64-kmc-solid_asp3`, `armv7a-kmc-solid_asp3-eabi`, `armv7a-kmc-solid_asp3-eabihf`
5313
5314\* Refer to Rust's [platform support page][platform-support-doc] for more
5315 information on Rust's tiered platform support.
5316
5317Libraries
5318---------
5319
5320- [Avoid allocations and copying in `Vec::leak`][89337]
5321- [Add `#[repr(i8)]` to `Ordering`][89507]
5322- [Optimize `File::read_to_end` and `read_to_string`][89582]
5323- [Update to Unicode 14.0][89614]
5324- [Many more functions are marked `#[must_use]`][89692], producing a warning
5325 when ignoring their return value. This helps catch mistakes such as expecting
5326 a function to mutate a value in place rather than return a new value.
5327
5328Stabilised APIs
5329---------------
5330
5331- [`[T; N]::as_mut_slice`][`array::as_mut_slice`]
5332- [`[T; N]::as_slice`][`array::as_slice`]
5333- [`collections::TryReserveError`]
5334- [`HashMap::try_reserve`]
5335- [`HashSet::try_reserve`]
5336- [`String::try_reserve`]
5337- [`String::try_reserve_exact`]
5338- [`Vec::try_reserve`]
5339- [`Vec::try_reserve_exact`]
5340- [`VecDeque::try_reserve`]
5341- [`VecDeque::try_reserve_exact`]
5342- [`Iterator::map_while`]
5343- [`iter::MapWhile`]
5344- [`proc_macro::is_available`]
5345- [`Command::get_program`]
5346- [`Command::get_args`]
5347- [`Command::get_envs`]
5348- [`Command::get_current_dir`]
5349- [`CommandArgs`]
5350- [`CommandEnvs`]
5351
5352These APIs are now usable in const contexts:
5353
5354- [`hint::unreachable_unchecked`]
5355
5356Cargo
5357-----
5358
5359- [Stabilize custom profiles][cargo/9943]
5360
5361Compatibility notes
5362-------------------
5363
5364- [Ignore derived `Clone` and `Debug` implementations during dead code analysis.][85200]
5365 This will break some builds that set `#![deny(dead_code)]`.
5366
5367Internal changes
5368----------------
5369These changes provide no direct user facing benefits, but represent significant
5370improvements to the internals and overall performance of rustc
5371and related tools.
5372
5373- [Added an experimental backend for codegen with `libgccjit`.][87260]
5374
5375[85200]: https://github.com/rust-lang/rust/pull/85200/
5376[86191]: https://github.com/rust-lang/rust/pull/86191/
5377[87220]: https://github.com/rust-lang/rust/pull/87220/
5378[87260]: https://github.com/rust-lang/rust/pull/87260/
5379[88321]: https://github.com/rust-lang/rust/pull/88321/
5380[88529]: https://github.com/rust-lang/rust/pull/88529/
5381[88690]: https://github.com/rust-lang/rust/pull/88690/
5382[88952]: https://github.com/rust-lang/rust/pull/88952/
5383[89337]: https://github.com/rust-lang/rust/pull/89337/
5384[89507]: https://github.com/rust-lang/rust/pull/89507/
5385[89508]: https://github.com/rust-lang/rust/pull/89508/
5386[89582]: https://github.com/rust-lang/rust/pull/89582/
5387[89597]: https://github.com/rust-lang/rust/pull/89597/
5388[89614]: https://github.com/rust-lang/rust/pull/89614/
5389[89692]: https://github.com/rust-lang/rust/issues/89692/
5390[cargo/9943]: https://github.com/rust-lang/cargo/pull/9943/
5391[`array::as_mut_slice`]: https://doc.rust-lang.org/std/primitive.array.html#method.as_mut_slice
5392[`array::as_slice`]: https://doc.rust-lang.org/std/primitive.array.html#method.as_slice
5393[`collections::TryReserveError`]: https://doc.rust-lang.org/std/collections/struct.TryReserveError.html
5394[`HashMap::try_reserve`]: https://doc.rust-lang.org/std/collections/hash_map/struct.HashMap.html#method.try_reserve
5395[`HashSet::try_reserve`]: https://doc.rust-lang.org/std/collections/hash_set/struct.HashSet.html#method.try_reserve
5396[`String::try_reserve`]: https://doc.rust-lang.org/alloc/string/struct.String.html#method.try_reserve
5397[`String::try_reserve_exact`]: https://doc.rust-lang.org/alloc/string/struct.String.html#method.try_reserve_exact
5398[`Vec::try_reserve`]: https://doc.rust-lang.org/std/vec/struct.Vec.html#method.try_reserve
5399[`Vec::try_reserve_exact`]: https://doc.rust-lang.org/std/vec/struct.Vec.html#method.try_reserve_exact
5400[`VecDeque::try_reserve`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.try_reserve
5401[`VecDeque::try_reserve_exact`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.try_reserve_exact
5402[`Iterator::map_while`]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.map_while
5403[`iter::MapWhile`]: https://doc.rust-lang.org/std/iter/struct.MapWhile.html
5404[`proc_macro::is_available`]: https://doc.rust-lang.org/proc_macro/fn.is_available.html
5405[`Command::get_program`]: https://doc.rust-lang.org/std/process/struct.Command.html#method.get_program
5406[`Command::get_args`]: https://doc.rust-lang.org/std/process/struct.Command.html#method.get_args
5407[`Command::get_envs`]: https://doc.rust-lang.org/std/process/struct.Command.html#method.get_envs
5408[`Command::get_current_dir`]: https://doc.rust-lang.org/std/process/struct.Command.html#method.get_current_dir
5409[`CommandArgs`]: https://doc.rust-lang.org/std/process/struct.CommandArgs.html
5410[`CommandEnvs`]: https://doc.rust-lang.org/std/process/struct.CommandEnvs.html
5411
5412Version 1.56.1 (2021-11-01)
5413===========================
5414
5415- New lints to detect the presence of bidirectional-override Unicode
5416 codepoints in the compiled source code ([CVE-2021-42574])
5417
5418[CVE-2021-42574]: https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-42574
5419
5420Version 1.56.0 (2021-10-21)
5421========================
5422
5423Language
5424--------
5425
5426- [The 2021 Edition is now stable.][rust#88100]
5427 See [the edition guide][rust-2021-edition-guide] for more details.
5428- [The pattern in `binding @ pattern` can now also introduce new bindings.][rust#85305]
5429- [Union field access is permitted in `const fn`.][rust#85769]
5430
5431[rust-2021-edition-guide]: https://doc.rust-lang.org/nightly/edition-guide/rust-2021/index.html
5432
5433Compiler
5434--------
5435
5436- [Upgrade to LLVM 13.][rust#87570]
5437- [Support memory, address, and thread sanitizers on aarch64-unknown-freebsd.][rust#88023]
5438- [Allow specifying a deployment target version for all iOS targets][rust#87699]
5439- [Warnings can be forced on with `--force-warn`.][rust#87472]
5440 This feature is primarily intended for usage by `cargo fix`, rather than end users.
5441- [Promote `aarch64-apple-ios-sim` to Tier 2\*.][rust#87760]
5442- [Add `powerpc-unknown-freebsd` at Tier 3\*.][rust#87370]
5443- [Add `riscv32imc-esp-espidf` at Tier 3\*.][rust#87666]
5444
5445\* Refer to Rust's [platform support page][platform-support-doc] for more
5446information on Rust's tiered platform support.
5447
5448Libraries
5449---------
5450
5451- [Allow writing of incomplete UTF-8 sequences via stdout/stderr on Windows.][rust#83342]
5452 The Windows console still requires valid Unicode, but this change allows
5453 splitting a UTF-8 character across multiple write calls. This allows, for
5454 instance, programs that just read and write data buffers (e.g. copying a file
5455 to stdout) without regard for Unicode or character boundaries.
5456- [Prefer `AtomicU{64,128}` over Mutex for Instant backsliding protection.][rust#83093]
5457 For this use case, atomics scale much better under contention.
5458- [Implement `Extend<(A, B)>` for `(Extend<A>, Extend<B>)`][rust#85835]
5459- [impl Default, Copy, Clone for std::io::Sink and std::io::Empty][rust#86744]
5460- [`impl From<[(K, V); N]>` for all collections.][rust#84111]
5461- [Remove `P: Unpin` bound on impl Future for Pin.][rust#81363]
5462- [Treat invalid environment variable names as nonexistent.][rust#86183]
5463 Previously, the environment functions would panic if given a variable name
5464 with an internal null character or equal sign (`=`). Now, these functions will
5465 just treat such names as nonexistent variables, since the OS cannot represent
5466 the existence of a variable with such a name.
5467
5468Stabilised APIs
5469---------------
5470
5471- [`std::os::unix::fs::chroot`]
5472- [`UnsafeCell::raw_get`]
5473- [`BufWriter::into_parts`]
5474- [`core::panic::{UnwindSafe, RefUnwindSafe, AssertUnwindSafe}`]
5475 These APIs were previously stable in `std`, but are now also available in `core`.
5476- [`Vec::shrink_to`]
5477- [`String::shrink_to`]
5478- [`OsString::shrink_to`]
5479- [`PathBuf::shrink_to`]
5480- [`BinaryHeap::shrink_to`]
5481- [`VecDeque::shrink_to`]
5482- [`HashMap::shrink_to`]
5483- [`HashSet::shrink_to`]
5484
5485These APIs are now usable in const contexts:
5486
5487- [`std::mem::transmute`]
5488- [`[T]::first`][`slice::first`]
5489- [`[T]::split_first`][`slice::split_first`]
5490- [`[T]::last`][`slice::last`]
5491- [`[T]::split_last`][`slice::split_last`]
5492
5493Cargo
5494-----
5495
5496- [Cargo supports specifying a minimum supported Rust version in Cargo.toml.][`rust-version`]
5497 This has no effect at present on dependency version selection.
5498 We encourage crates to specify their minimum supported Rust version, and we encourage CI systems
5499 that support Rust code to include a crate's specified minimum version in the test matrix for that
5500 crate by default.
5501
5502Compatibility notes
5503-------------------
5504
5505- [Update to new argument parsing rules on Windows.][rust#87580]
5506 This adjusts Rust's standard library to match the behavior of the standard
5507 libraries for C/C++. The rules have changed slightly over time, and this PR
5508 brings us to the latest set of rules (changed in 2008).
5509- [Disallow the aapcs calling convention on aarch64][rust#88399]
5510 This was already not supported by LLVM; this change surfaces this lack of
5511 support with a better error message.
5512- [Make `SEMICOLON_IN_EXPRESSIONS_FROM_MACROS` warn by default][rust#87385]
5513- [Warn when an escaped newline skips multiple lines.][rust#87671]
5514- [Calls to `libc::getpid` / `std::process::id` from `Command::pre_exec`
5515 may return different values on glibc <= 2.24.][rust#81825]
5516 Rust now invokes the `clone3` system call directly, when available, to use new functionality
5517 available via that system call. Older versions of glibc cache the result of `getpid`, and only
5518 update that cache when calling glibc's clone/fork functions, so a direct system call bypasses
5519 that cache update. glibc 2.25 and newer no longer cache `getpid` for exactly this reason.
5520
5521Internal changes
5522----------------
5523These changes provide no direct user facing benefits, but represent significant
5524improvements to the internals and overall performance of rustc
5525and related tools.
5526
5527- [LLVM is compiled with PGO in published x86_64-unknown-linux-gnu artifacts.][rust#88069]
5528 This improves the performance of most Rust builds.
5529- [Unify representation of macros in internal data structures.][rust#88019]
5530 This change fixes a host of bugs with the handling of macros by the compiler,
5531 as well as rustdoc.
5532
5533[`std::os::unix::fs::chroot`]: https://doc.rust-lang.org/stable/std/os/unix/fs/fn.chroot.html
5534[`UnsafeCell::raw_get`]: https://doc.rust-lang.org/stable/std/cell/struct.UnsafeCell.html#method.raw_get
5535[`BufWriter::into_parts`]: https://doc.rust-lang.org/stable/std/io/struct.BufWriter.html#method.into_parts
5536[`core::panic::{UnwindSafe, RefUnwindSafe, AssertUnwindSafe}`]: https://github.com/rust-lang/rust/pull/84662
5537[`Vec::shrink_to`]: https://doc.rust-lang.org/stable/std/vec/struct.Vec.html#method.shrink_to
5538[`String::shrink_to`]: https://doc.rust-lang.org/stable/std/string/struct.String.html#method.shrink_to
5539[`OsString::shrink_to`]: https://doc.rust-lang.org/stable/std/ffi/struct.OsString.html#method.shrink_to
5540[`PathBuf::shrink_to`]: https://doc.rust-lang.org/stable/std/path/struct.PathBuf.html#method.shrink_to
5541[`BinaryHeap::shrink_to`]: https://doc.rust-lang.org/stable/std/collections/struct.BinaryHeap.html#method.shrink_to
5542[`VecDeque::shrink_to`]: https://doc.rust-lang.org/stable/std/collections/struct.VecDeque.html#method.shrink_to
5543[`HashMap::shrink_to`]: https://doc.rust-lang.org/stable/std/collections/hash_map/struct.HashMap.html#method.shrink_to
5544[`HashSet::shrink_to`]: https://doc.rust-lang.org/stable/std/collections/hash_set/struct.HashSet.html#method.shrink_to
5545[`std::mem::transmute`]: https://doc.rust-lang.org/stable/std/mem/fn.transmute.html
5546[`slice::first`]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.first
5547[`slice::split_first`]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_first
5548[`slice::last`]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.last
5549[`slice::split_last`]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.split_last
5550[`rust-version`]: https://doc.rust-lang.org/nightly/cargo/reference/manifest.html#the-rust-version-field
5551[rust#87671]: https://github.com/rust-lang/rust/pull/87671
5552[rust#86183]: https://github.com/rust-lang/rust/pull/86183
5553[rust#87385]: https://github.com/rust-lang/rust/pull/87385
5554[rust#88100]: https://github.com/rust-lang/rust/pull/88100
5555[rust#85305]: https://github.com/rust-lang/rust/pull/85305
5556[rust#88069]: https://github.com/rust-lang/rust/pull/88069
5557[rust#87472]: https://github.com/rust-lang/rust/pull/87472
5558[rust#87699]: https://github.com/rust-lang/rust/pull/87699
5559[rust#87570]: https://github.com/rust-lang/rust/pull/87570
5560[rust#88023]: https://github.com/rust-lang/rust/pull/88023
5561[rust#87760]: https://github.com/rust-lang/rust/pull/87760
5562[rust#87370]: https://github.com/rust-lang/rust/pull/87370
5563[rust#87580]: https://github.com/rust-lang/rust/pull/87580
5564[rust#83342]: https://github.com/rust-lang/rust/pull/83342
5565[rust#83093]: https://github.com/rust-lang/rust/pull/83093
5566[rust#85835]: https://github.com/rust-lang/rust/pull/85835
5567[rust#86744]: https://github.com/rust-lang/rust/pull/86744
5568[rust#81363]: https://github.com/rust-lang/rust/pull/81363
5569[rust#84111]: https://github.com/rust-lang/rust/pull/84111
5570[rust#85769]: https://github.com/rust-lang/rust/pull/85769#issuecomment-854363720
5571[rust#88399]: https://github.com/rust-lang/rust/pull/88399
5572[rust#81825]: https://github.com/rust-lang/rust/pull/81825#issuecomment-808406918
5573[rust#88019]: https://github.com/rust-lang/rust/pull/88019
5574[rust#87666]: https://github.com/rust-lang/rust/pull/87666
5575
5576Version 1.55.0 (2021-09-09)
5577============================
5578
5579Language
5580--------
5581- [You can now write open "from" range patterns (`X..`), which will start at `X` and
5582 will end at the maximum value of the integer.][83918]
5583- [You can now explicitly import the prelude of different editions
5584 through `std::prelude` (e.g. `use std::prelude::rust_2021::*;`).][86294]
5585
5586Compiler
5587--------
5588- [Added tier 3\* support for `powerpc64le-unknown-freebsd`.][83572]
5589
5590\* Refer to Rust's [platform support page][platform-support-doc] for more
5591 information on Rust's tiered platform support.
5592
5593Libraries
5594---------
5595
5596- [Updated std's float parsing to use the Eisel-Lemire algorithm.][86761]
5597 These improvements should in general provide faster string parsing of floats,
5598 no longer reject certain valid floating point values, and reduce
5599 the produced code size for non-stripped artifacts.
5600- [`string::Drain` now implements `AsRef<str>` and `AsRef<[u8]>`.][86858]
5601
5602Stabilised APIs
5603---------------
5604
5605- [`Bound::cloned`]
5606- [`Drain::as_str`]
5607- [`IntoInnerError::into_error`]
5608- [`IntoInnerError::into_parts`]
5609- [`MaybeUninit::assume_init_mut`]
5610- [`MaybeUninit::assume_init_ref`]
5611- [`MaybeUninit::write`]
5612- [`array::map`]
5613- [`ops::ControlFlow`]
5614- [`x86::_bittest`]
5615- [`x86::_bittestandcomplement`]
5616- [`x86::_bittestandreset`]
5617- [`x86::_bittestandset`]
5618- [`x86_64::_bittest64`]
5619- [`x86_64::_bittestandcomplement64`]
5620- [`x86_64::_bittestandreset64`]
5621- [`x86_64::_bittestandset64`]
5622
5623The following previously stable functions are now `const`.
5624
5625- [`str::from_utf8_unchecked`]
5626
5627
5628Cargo
5629-----
5630- [Cargo will now deduplicate compiler diagnostics to the terminal when invoking
5631 rustc in parallel such as when using `cargo test`.][cargo/9675]
5632- [The package definition in `cargo metadata` now includes the `"default_run"`
5633 field from the manifest.][cargo/9550]
5634- [Added `cargo d` as an alias for `cargo doc`.][cargo/9680]
5635- [Added `{lib}` as formatting option for `cargo tree` to print the `"lib_name"`
5636 of packages.][cargo/9663]
5637
5638Rustdoc
5639-------
5640- [Added "Go to item on exact match" search option.][85876]
5641- [The "Implementors" section on traits no longer shows redundant
5642 method definitions.][85970]
5643- [Trait implementations are toggled open by default.][86260] This should make the
5644 implementations more searchable by tools like `CTRL+F` in your browser.
5645- [Intra-doc links should now correctly resolve associated items (e.g. methods)
5646 through type aliases.][86334]
5647- [Traits which are marked with `#[doc(hidden)]` will no longer appear in the
5648 "Trait Implementations" section.][86513]
5649
5650
5651Compatibility Notes
5652-------------------
5653- [std functions that return an `io::Error` will no longer use the
5654 `ErrorKind::Other` variant.][85746] This is to better reflect that these
5655 kinds of errors could be categorised [into newer more specific `ErrorKind`
5656 variants][79965], and that they do not represent a user error.
5657- [Using environment variable names with `process::Command` on Windows now
5658 behaves as expected.][85270] Previously using environment variables with
5659 `Command` would cause them to be ASCII-uppercased.
5660- [Rustdoc will now warn on using rustdoc lints that aren't prefixed
5661 with `rustdoc::`][86849]
5662- `RUSTFLAGS` is no longer set for build scripts. Build scripts
5663 should use `CARGO_ENCODED_RUSTFLAGS` instead. See the
5664 [documentation](https://doc.rust-lang.org/nightly/cargo/reference/environment-variables.html#environment-variables-cargo-sets-for-build-scripts)
5665 for more details.
5666
5667[86849]: https://github.com/rust-lang/rust/pull/86849
5668[86513]: https://github.com/rust-lang/rust/pull/86513
5669[86334]: https://github.com/rust-lang/rust/pull/86334
5670[86260]: https://github.com/rust-lang/rust/pull/86260
5671[85970]: https://github.com/rust-lang/rust/pull/85970
5672[85876]: https://github.com/rust-lang/rust/pull/85876
5673[83572]: https://github.com/rust-lang/rust/pull/83572
5674[86294]: https://github.com/rust-lang/rust/pull/86294
5675[86858]: https://github.com/rust-lang/rust/pull/86858
5676[86761]: https://github.com/rust-lang/rust/pull/86761
5677[85746]: https://github.com/rust-lang/rust/pull/85746
5678[85270]: https://github.com/rust-lang/rust/pull/85270
5679[83918]: https://github.com/rust-lang/rust/pull/83918
5680[79965]: https://github.com/rust-lang/rust/pull/79965
5681[cargo/9663]: https://github.com/rust-lang/cargo/pull/9663
5682[cargo/9675]: https://github.com/rust-lang/cargo/pull/9675
5683[cargo/9550]: https://github.com/rust-lang/cargo/pull/9550
5684[cargo/9680]: https://github.com/rust-lang/cargo/pull/9680
5685[`array::map`]: https://doc.rust-lang.org/stable/std/primitive.array.html#method.map
5686[`Bound::cloned`]: https://doc.rust-lang.org/stable/std/ops/enum.Bound.html#method.cloned
5687[`Drain::as_str`]: https://doc.rust-lang.org/stable/std/string/struct.Drain.html#method.as_str
5688[`IntoInnerError::into_error`]: https://doc.rust-lang.org/stable/std/io/struct.IntoInnerError.html#method.into_error
5689[`IntoInnerError::into_parts`]: https://doc.rust-lang.org/stable/std/io/struct.IntoInnerError.html#method.into_parts
5690[`MaybeUninit::assume_init_mut`]: https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#method.assume_init_mut
5691[`MaybeUninit::assume_init_ref`]: https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#method.assume_init_ref
5692[`MaybeUninit::write`]: https://doc.rust-lang.org/stable/std/mem/union.MaybeUninit.html#method.write
5693[`ops::ControlFlow`]: https://doc.rust-lang.org/stable/std/ops/enum.ControlFlow.html
5694[`str::from_utf8_unchecked`]: https://doc.rust-lang.org/stable/std/str/fn.from_utf8_unchecked.html
5695[`x86::_bittest`]: https://doc.rust-lang.org/stable/core/arch/x86/fn._bittest.html
5696[`x86::_bittestandcomplement`]: https://doc.rust-lang.org/stable/core/arch/x86/fn._bittestandcomplement.html
5697[`x86::_bittestandreset`]: https://doc.rust-lang.org/stable/core/arch/x86/fn._bittestandreset.html
5698[`x86::_bittestandset`]: https://doc.rust-lang.org/stable/core/arch/x86/fn._bittestandset.html
5699[`x86_64::_bittest64`]: https://doc.rust-lang.org/stable/core/arch/x86_64/fn._bittest64.html
5700[`x86_64::_bittestandcomplement64`]: https://doc.rust-lang.org/stable/core/arch/x86_64/fn._bittestandcomplement64.html
5701[`x86_64::_bittestandreset64`]: https://doc.rust-lang.org/stable/core/arch/x86_64/fn._bittestandreset64.html
5702[`x86_64::_bittestandset64`]: https://doc.rust-lang.org/stable/core/arch/x86_64/fn._bittestandset64.html
5703
5704
5705Version 1.54.0 (2021-07-29)
5706============================
5707
5708Language
5709-----------------------
5710
5711- [You can now use macros for values in some built-in attributes.][83366]
5712 This primarily allows you to call macros within the `#[doc]` attribute. For
5713 example, to include external documentation in your crate, you can now write
5714 the following:
5715 ```rust
5716 #![doc = include_str!("README.md")]
5717 ```
5718
5719- [You can now cast between unsized slice types (and types which contain
5720 unsized slices) in `const fn`.][85078]
5721- [You can now use multiple generic lifetimes with `impl Trait` where the
5722 lifetimes don't explicitly outlive another.][84701] In code this means
5723 that you can now have `impl Trait<'a, 'b>` where as before you could
5724 only have `impl Trait<'a, 'b> where 'b: 'a`.
5725
5726Compiler
5727-----------------------
5728
5729- [Rustc will now search for custom JSON targets in
5730 `/lib/rustlib/<target-triple>/target.json` where `/` is the "sysroot"
5731 directory.][83800] You can find your sysroot directory by running
5732 `rustc --print sysroot`.
5733- [Added `wasm` as a `target_family` for WebAssembly platforms.][84072]
5734- [You can now use `#[target_feature]` on safe functions when targeting
5735 WebAssembly platforms.][84988]
5736- [Improved debugger output for enums on Windows MSVC platforms.][85292]
5737- [Added tier 3\* support for `bpfel-unknown-none`
5738 and `bpfeb-unknown-none`.][79608]
5739- [`-Zmutable-noalias=yes`][82834] is enabled by default when using LLVM 12 or above.
5740
5741\* Refer to Rust's [platform support page][platform-support-doc] for more
5742 information on Rust's tiered platform support.
5743
5744Libraries
5745-----------------------
5746
5747- [`panic::panic_any` will now `#[track_caller]`.][85745]
5748- [Added `OutOfMemory` as a variant of `io::ErrorKind`.][84744]
5749- [ `proc_macro::Literal` now implements `FromStr`.][84717]
5750- [The implementations of vendor intrinsics in core::arch have been
5751 significantly refactored.][83278] The main user-visible changes are
5752 a 50% reduction in the size of libcore.rlib and stricter validation
5753 of constant operands passed to intrinsics. The latter is technically
5754 a breaking change, but allows Rust to more closely match the C vendor
5755 intrinsics API.
5756
5757Stabilized APIs
5758---------------
5759
5760- [`BTreeMap::into_keys`]
5761- [`BTreeMap::into_values`]
5762- [`HashMap::into_keys`]
5763- [`HashMap::into_values`]
5764- [`arch::wasm32`]
5765- [`VecDeque::binary_search`]
5766- [`VecDeque::binary_search_by`]
5767- [`VecDeque::binary_search_by_key`]
5768- [`VecDeque::partition_point`]
5769
5770Cargo
5771-----
5772
5773- [Added the `--prune <spec>` option to `cargo-tree` to remove a package from
5774 the dependency graph.][cargo/9520]
5775- [Added the `--depth` option to `cargo-tree` to print only to a certain depth
5776 in the tree ][cargo/9499]
5777- [Added the `no-proc-macro` value to `cargo-tree --edges` to hide procedural
5778 macro dependencies.][cargo/9488]
5779- [A new environment variable named `CARGO_TARGET_TMPDIR` is available.][cargo/9375]
5780 This variable points to a directory that integration tests and benches
5781 can use as a "scratchpad" for testing filesystem operations.
5782
5783Compatibility Notes
5784-------------------
5785- [Mixing Option and Result via `?` is no longer permitted in closures for inferred types.][86831]
5786- [Previously unsound code is no longer permitted where different constructors in branches
5787 could require different lifetimes.][85574]
5788- As previously mentioned the [`std::arch` intrinsics now uses stricter const checking][83278]
5789 than before and may reject some previously accepted code.
5790- [`i128` multiplication on Cortex M0+ platforms currently unconditionally causes overflow
5791 when compiled with `codegen-units = 1`.][86063]
5792
5793[85574]: https://github.com/rust-lang/rust/issues/85574
5794[86831]: https://github.com/rust-lang/rust/issues/86831
5795[86063]: https://github.com/rust-lang/rust/issues/86063
5796[79608]: https://github.com/rust-lang/rust/pull/79608
5797[84988]: https://github.com/rust-lang/rust/pull/84988
5798[84701]: https://github.com/rust-lang/rust/pull/84701
5799[84072]: https://github.com/rust-lang/rust/pull/84072
5800[85745]: https://github.com/rust-lang/rust/pull/85745
5801[84744]: https://github.com/rust-lang/rust/pull/84744
5802[85078]: https://github.com/rust-lang/rust/pull/85078
5803[84717]: https://github.com/rust-lang/rust/pull/84717
5804[83800]: https://github.com/rust-lang/rust/pull/83800
5805[83366]: https://github.com/rust-lang/rust/pull/83366
5806[83278]: https://github.com/rust-lang/rust/pull/83278
5807[85292]: https://github.com/rust-lang/rust/pull/85292
5808[82834]: https://github.com/rust-lang/rust/pull/82834
5809[cargo/9520]: https://github.com/rust-lang/cargo/pull/9520
5810[cargo/9499]: https://github.com/rust-lang/cargo/pull/9499
5811[cargo/9488]: https://github.com/rust-lang/cargo/pull/9488
5812[cargo/9375]: https://github.com/rust-lang/cargo/pull/9375
5813[`BTreeMap::into_keys`]: https://doc.rust-lang.org/std/collections/struct.BTreeMap.html#method.into_keys
5814[`BTreeMap::into_values`]: https://doc.rust-lang.org/std/collections/struct.BTreeMap.html#method.into_values
5815[`HashMap::into_keys`]: https://doc.rust-lang.org/std/collections/struct.HashMap.html#method.into_keys
5816[`HashMap::into_values`]: https://doc.rust-lang.org/std/collections/struct.HashMap.html#method.into_values
5817[`arch::wasm32`]: https://doc.rust-lang.org/core/arch/wasm32/index.html
5818[`VecDeque::binary_search`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.binary_search
5819[`VecDeque::binary_search_by`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.binary_search_by
5820
5821[`VecDeque::binary_search_by_key`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.binary_search_by_key
5822
5823[`VecDeque::partition_point`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.partition_point
5824
5825Version 1.53.0 (2021-06-17)
5826============================
5827
5828Language
5829-----------------------
5830- [You can now use unicode for identifiers.][83799] This allows multilingual
5831 identifiers but still doesn't allow glyphs that are not considered characters
5832 such as `◆` or `🦀`. More specifically you can now use any identifier that
5833 matches the UAX #31 "Unicode Identifier and Pattern Syntax" standard. This
5834 is the same standard as languages like Python, however Rust uses NFC
5835 normalization which may be different from other languages.
5836- [You can now specify "or patterns" inside pattern matches.][79278]
5837 Previously you could only use `|` (OR) on complete patterns. E.g.
5838 ```rust
5839 let x = Some(2u8);
5840 // Before
5841 matches!(x, Some(1) | Some(2));
5842 // Now
5843 matches!(x, Some(1 | 2));
5844 ```
5845- [Added the `:pat_param` `macro_rules!` matcher.][83386] This matcher
5846 has the same semantics as the `:pat` matcher. This is to allow `:pat`
5847 to change semantics to being a pattern fragment in a future edition.
5848
5849Compiler
5850-----------------------
5851- [Updated the minimum external LLVM version to LLVM 10.][83387]
5852- [Added Tier 3\* support for the `wasm64-unknown-unknown` target.][80525]
5853- [Improved debuginfo for closures and async functions on Windows MSVC.][83941]
5854
5855\* Refer to Rust's [platform support page][platform-support-doc] for more
5856information on Rust's tiered platform support.
5857
5858Libraries
5859-----------------------
5860- [Abort messages will now forward to `android_set_abort_message` on
5861 Android platforms when available.][81469]
5862- [`slice::IterMut<'_, T>` now implements `AsRef<[T]>`][82771]
5863- [Arrays of any length now implement `IntoIterator`.][84147]
5864 Currently calling `.into_iter()` as a method on an array will
5865 return `impl Iterator<Item=&T>`, but this may change in a
5866 future edition to change `Item` to `T`. Calling `IntoIterator::into_iter`
5867 directly on arrays will provide `impl Iterator<Item=T>` as expected.
5868- [`leading_zeros`, and `trailing_zeros` are now available on all
5869 `NonZero` integer types.][84082]
5870- [`{f32, f64}::from_str` now parse and print special values
5871 (`NaN`, `-0`) according to IEEE 754.][78618]
5872- [You can now index into slices using `(Bound<usize>, Bound<usize>)`.][77704]
5873- [Add the `BITS` associated constant to all numeric types.][82565]
5874
5875Stabilised APIs
5876---------------
5877- [`AtomicBool::fetch_update`]
5878- [`AtomicPtr::fetch_update`]
5879- [`BTreeMap::retain`]
5880- [`BTreeSet::retain`]
5881- [`BufReader::seek_relative`]
5882- [`DebugStruct::non_exhaustive`]
5883- [`Duration::MAX`]
5884- [`Duration::ZERO`]
5885- [`Duration::is_zero`]
5886- [`Duration::saturating_add`]
5887- [`Duration::saturating_mul`]
5888- [`Duration::saturating_sub`]
5889- [`ErrorKind::Unsupported`]
5890- [`Option::insert`]
5891- [`Ordering::is_eq`]
5892- [`Ordering::is_ge`]
5893- [`Ordering::is_gt`]
5894- [`Ordering::is_le`]
5895- [`Ordering::is_lt`]
5896- [`Ordering::is_ne`]
5897- [`OsStr::is_ascii`]
5898- [`OsStr::make_ascii_lowercase`]
5899- [`OsStr::make_ascii_uppercase`]
5900- [`OsStr::to_ascii_lowercase`]
5901- [`OsStr::to_ascii_uppercase`]
5902- [`Peekable::peek_mut`]
5903- [`Rc::decrement_strong_count`]
5904- [`Rc::increment_strong_count`]
5905- [`Vec::extend_from_within`]
5906- [`array::from_mut`]
5907- [`array::from_ref`]
5908- [`cmp::max_by_key`]
5909- [`cmp::max_by`]
5910- [`cmp::min_by_key`]
5911- [`cmp::min_by`]
5912- [`f32::is_subnormal`]
5913- [`f64::is_subnormal`]
5914
5915Cargo
5916-----------------------
5917- [Cargo now supports git repositories where the default `HEAD` branch is not
5918 "master".][cargo/9392] This also includes a switch to the version 3 `Cargo.lock` format
5919 which can handle default branches correctly.
5920- [macOS targets now default to `unpacked` split-debuginfo.][cargo/9298]
5921- [The `authors` field is no longer included in `Cargo.toml` for new
5922 projects.][cargo/9282]
5923
5924Rustdoc
5925-----------------------
5926- [Added the `rustdoc::bare_urls` lint that warns when you have URLs
5927 without hyperlinks.][81764]
5928
5929Compatibility Notes
5930-------------------
5931- [Implement token-based handling of attributes during expansion][82608]
5932- [`Ipv4::from_str` will now reject octal format IP addresses in addition
5933 to rejecting hexadecimal IP addresses.][83652] The octal format can lead
5934 to confusion and potential security vulnerabilities and [is no
5935 longer recommended][ietf6943].
5936- [The added `BITS` constant may conflict with external definitions.][85667]
5937 In particular, this was known to be a problem in the `lexical-core` crate,
5938 but they have published fixes for semantic versions 0.4 through 0.7. To
5939 update this dependency alone, use `cargo update -p lexical-core`.
5940- Incremental compilation remains off by default, unless one uses the `RUSTC_FORCE_INCREMENTAL=1` environment variable added in 1.52.1.
5941
5942Internal Only
5943-------------
5944These changes provide no direct user facing benefits, but represent significant
5945improvements to the internals and overall performance of rustc and
5946related tools.
5947
5948- [Rework the `std::sys::windows::alloc` implementation.][83065]
5949- [rustdoc: Don't enter an infer_ctxt in get_blanket_impls for impls that aren't blanket impls.][82864]
5950- [rustdoc: Only look at blanket impls in `get_blanket_impls`][83681]
5951- [Rework rustdoc const type][82873]
5952
5953[85667]: https://github.com/rust-lang/rust/pull/85667
5954[83386]: https://github.com/rust-lang/rust/pull/83386
5955[82771]: https://github.com/rust-lang/rust/pull/82771
5956[84147]: https://github.com/rust-lang/rust/pull/84147
5957[84082]: https://github.com/rust-lang/rust/pull/84082
5958[83799]: https://github.com/rust-lang/rust/pull/83799
5959[83681]: https://github.com/rust-lang/rust/pull/83681
5960[83652]: https://github.com/rust-lang/rust/pull/83652
5961[83387]: https://github.com/rust-lang/rust/pull/83387
5962[82873]: https://github.com/rust-lang/rust/pull/82873
5963[82864]: https://github.com/rust-lang/rust/pull/82864
5964[82608]: https://github.com/rust-lang/rust/pull/82608
5965[82565]: https://github.com/rust-lang/rust/pull/82565
5966[80525]: https://github.com/rust-lang/rust/pull/80525
5967[79278]: https://github.com/rust-lang/rust/pull/79278
5968[78618]: https://github.com/rust-lang/rust/pull/78618
5969[77704]: https://github.com/rust-lang/rust/pull/77704
5970[83941]: https://github.com/rust-lang/rust/pull/83941
5971[83065]: https://github.com/rust-lang/rust/pull/83065
5972[81764]: https://github.com/rust-lang/rust/pull/81764
5973[81469]: https://github.com/rust-lang/rust/pull/81469
5974[cargo/9298]: https://github.com/rust-lang/cargo/pull/9298
5975[cargo/9282]: https://github.com/rust-lang/cargo/pull/9282
5976[cargo/9392]: https://github.com/rust-lang/cargo/pull/9392
5977[`AtomicBool::fetch_update`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicBool.html#method.fetch_update
5978[`AtomicPtr::fetch_update`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicPtr.html#method.fetch_update
5979[`BTreeMap::retain`]: https://doc.rust-lang.org/std/collections/struct.BTreeMap.html#method.retain
5980[`BTreeSet::retain`]: https://doc.rust-lang.org/std/collections/struct.BTreeSet.html#method.retain
5981[`BufReader::seek_relative`]: https://doc.rust-lang.org/std/io/struct.BufReader.html#method.seek_relative
5982[`DebugStruct::non_exhaustive`]: https://doc.rust-lang.org/std/fmt/struct.DebugStruct.html#method.finish_non_exhaustive
5983[`Duration::MAX`]: https://doc.rust-lang.org/std/time/struct.Duration.html#associatedconstant.MAX
5984[`Duration::ZERO`]: https://doc.rust-lang.org/std/time/struct.Duration.html#associatedconstant.ZERO
5985[`Duration::is_zero`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.is_zero
5986[`Duration::saturating_add`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.saturating_add
5987[`Duration::saturating_mul`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.saturating_mul
5988[`Duration::saturating_sub`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.saturating_sub
5989[`ErrorKind::Unsupported`]: https://doc.rust-lang.org/std/io/enum.ErrorKind.html#variant.Unsupported
5990[`Option::insert`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.insert
5991[`Ordering::is_eq`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.is_eq
5992[`Ordering::is_ge`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.is_ge
5993[`Ordering::is_gt`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.is_gt
5994[`Ordering::is_le`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.is_le
5995[`Ordering::is_lt`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.is_lt
5996[`Ordering::is_ne`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.is_ne
5997[`OsStr::is_ascii`]: https://doc.rust-lang.org/std/ffi/struct.OsStr.html#method.is_ascii
5998[`OsStr::make_ascii_lowercase`]: https://doc.rust-lang.org/std/ffi/struct.OsStr.html#method.make_ascii_lowercase
5999[`OsStr::make_ascii_uppercase`]: https://doc.rust-lang.org/std/ffi/struct.OsStr.html#method.make_ascii_uppercase
6000[`OsStr::to_ascii_lowercase`]: https://doc.rust-lang.org/std/ffi/struct.OsStr.html#method.to_ascii_lowercase
6001[`OsStr::to_ascii_uppercase`]: https://doc.rust-lang.org/std/ffi/struct.OsStr.html#method.to_ascii_uppercase
6002[`Peekable::peek_mut`]: https://doc.rust-lang.org/std/iter/struct.Peekable.html#method.peek_mut
6003[`Rc::decrement_strong_count`]: https://doc.rust-lang.org/std/rc/struct.Rc.html#method.decrement_strong_count
6004[`Rc::increment_strong_count`]: https://doc.rust-lang.org/std/rc/struct.Rc.html#method.increment_strong_count
6005[`Vec::extend_from_within`]: https://doc.rust-lang.org/beta/std/vec/struct.Vec.html#method.extend_from_within
6006[`array::from_mut`]: https://doc.rust-lang.org/beta/std/array/fn.from_mut.html
6007[`array::from_ref`]: https://doc.rust-lang.org/beta/std/array/fn.from_ref.html
6008[`cmp::max_by_key`]: https://doc.rust-lang.org/beta/std/cmp/fn.max_by_key.html
6009[`cmp::max_by`]: https://doc.rust-lang.org/beta/std/cmp/fn.max_by.html
6010[`cmp::min_by_key`]: https://doc.rust-lang.org/beta/std/cmp/fn.min_by_key.html
6011[`cmp::min_by`]: https://doc.rust-lang.org/beta/std/cmp/fn.min_by.html
6012[`f32::is_subnormal`]: https://doc.rust-lang.org/std/primitive.f32.html#method.is_subnormal
6013[`f64::is_subnormal`]: https://doc.rust-lang.org/std/primitive.f64.html#method.is_subnormal
6014[ietf6943]: https://datatracker.ietf.org/doc/html/rfc6943#section-3.1.1
6015
6016
6017Version 1.52.1 (2021-05-10)
6018============================
6019
6020This release disables incremental compilation, unless the user has explicitly
6021opted in via the newly added RUSTC_FORCE_INCREMENTAL=1 environment variable.
6022
6023This is due to the widespread, and frequently occurring, breakage encountered by
6024Rust users due to newly enabled incremental verification in 1.52.0. Notably,
6025Rust users **should** upgrade to 1.52.0 or 1.52.1: the bugs that are detected by
6026newly added incremental verification are still present in past stable versions,
6027and are not yet fixed on any channel. These bugs can lead to miscompilation of
6028Rust binaries.
6029
6030These problems only affect incremental builds, so release builds with Cargo
6031should not be affected unless the user has explicitly opted into incremental.
6032Debug and check builds are affected.
6033
6034See [84970] for more details.
6035
6036[84970]: https://github.com/rust-lang/rust/issues/84970
6037
6038Version 1.52.0 (2021-05-06)
6039============================
6040
6041Language
6042--------
6043- [Added the `unsafe_op_in_unsafe_fn` lint, which checks whether the unsafe code
6044 in an `unsafe fn` is wrapped in a `unsafe` block.][79208] This lint
6045 is allowed by default, and may become a warning or hard error in a
6046 future edition.
6047- [You can now cast mutable references to arrays to a pointer of the same type as
6048 the element.][81479]
6049
6050Compiler
6051--------
6052- [Upgraded the default LLVM to LLVM 12.][81451]
6053
6054Added tier 3\* support for the following targets.
6055
6056- [`s390x-unknown-linux-musl`][82166]
6057- [`riscv32gc-unknown-linux-musl` & `riscv64gc-unknown-linux-musl`][82202]
6058- [`powerpc-unknown-openbsd`][82733]
6059
6060\* Refer to Rust's [platform support page][platform-support-doc] for more
6061information on Rust's tiered platform support.
6062
6063Libraries
6064---------
6065- [`OsString` now implements `Extend` and `FromIterator`.][82121]
6066- [`cmp::Reverse` now has `#[repr(transparent)]` representation.][81879]
6067- [`Arc<impl Error>` now implements `error::Error`.][80553]
6068- [All integer division and remainder operations are now `const`.][80962]
6069
6070Stabilised APIs
6071-------------
6072- [`Arguments::as_str`]
6073- [`char::MAX`]
6074- [`char::REPLACEMENT_CHARACTER`]
6075- [`char::UNICODE_VERSION`]
6076- [`char::decode_utf16`]
6077- [`char::from_digit`]
6078- [`char::from_u32_unchecked`]
6079- [`char::from_u32`]
6080- [`slice::partition_point`]
6081- [`str::rsplit_once`]
6082- [`str::split_once`]
6083
6084The following previously stable APIs are now `const`.
6085
6086- [`char::len_utf8`]
6087- [`char::len_utf16`]
6088- [`char::to_ascii_uppercase`]
6089- [`char::to_ascii_lowercase`]
6090- [`char::eq_ignore_ascii_case`]
6091- [`u8::to_ascii_uppercase`]
6092- [`u8::to_ascii_lowercase`]
6093- [`u8::eq_ignore_ascii_case`]
6094
6095Rustdoc
6096-------
6097- [Rustdoc lints are now treated as a tool lint, meaning that
6098 lints are now prefixed with `rustdoc::` (e.g. `#[warn(rustdoc::broken_intra_doc_links)]`).][80527]
6099 Using the old style is still allowed, and will become a warning in
6100 a future release.
6101- [Rustdoc now supports argument files.][82261]
6102- [Rustdoc now generates smart punctuation for documentation.][79423]
6103- [You can now use "task lists" in Rustdoc Markdown.][81766] E.g.
6104 ```markdown
6105 - [x] Complete
6106 - [ ] Todo
6107 ```
6108
6109Misc
6110----
6111- [You can now pass multiple filters to tests.][81356] E.g.
6112 `cargo test -- foo bar` will run all tests that match `foo` and `bar`.
6113- [Rustup now distributes PDB symbols for the `std` library on Windows,
6114 allowing you to see `std` symbols when debugging.][82218]
6115
6116Internal Only
6117-------------
6118These changes provide no direct user facing benefits, but represent significant
6119improvements to the internals and overall performance of rustc and
6120related tools.
6121
6122- [Check the result cache before the DepGraph when ensuring queries][81855]
6123- [Try fast_reject::simplify_type in coherence before doing full check][81744]
6124- [Only store a LocalDefId in some HIR nodes][81611]
6125- [Store HIR attributes in a side table][79519]
6126
6127Compatibility Notes
6128-------------------
6129- [Cargo build scripts are now forbidden from setting `RUSTC_BOOTSTRAP`.][cargo/9181]
6130- [Removed support for the `x86_64-rumprun-netbsd` target.][82594]
6131- [Deprecated the `x86_64-sun-solaris` target in favor of `x86_64-pc-solaris`.][82216]
6132- [Rustdoc now only accepts `,`, ` `, and `\t` as delimiters for specifying
6133 languages in code blocks.][78429]
6134- [Rustc now catches more cases of `pub_use_of_private_extern_crate`][80763]
6135- [Changes in how proc macros handle whitespace may lead to panics when used
6136 with older `proc-macro-hack` versions. A `cargo update` should be sufficient to fix this in all cases.][84136]
6137- [Turn `#[derive]` into a regular macro attribute][79078]
6138
6139[84136]: https://github.com/rust-lang/rust/issues/84136
6140[80763]: https://github.com/rust-lang/rust/pull/80763
6141[82166]: https://github.com/rust-lang/rust/pull/82166
6142[82121]: https://github.com/rust-lang/rust/pull/82121
6143[81879]: https://github.com/rust-lang/rust/pull/81879
6144[82261]: https://github.com/rust-lang/rust/pull/82261
6145[82218]: https://github.com/rust-lang/rust/pull/82218
6146[82216]: https://github.com/rust-lang/rust/pull/82216
6147[82202]: https://github.com/rust-lang/rust/pull/82202
6148[81855]: https://github.com/rust-lang/rust/pull/81855
6149[81766]: https://github.com/rust-lang/rust/pull/81766
6150[81744]: https://github.com/rust-lang/rust/pull/81744
6151[81611]: https://github.com/rust-lang/rust/pull/81611
6152[81479]: https://github.com/rust-lang/rust/pull/81479
6153[81451]: https://github.com/rust-lang/rust/pull/81451
6154[81356]: https://github.com/rust-lang/rust/pull/81356
6155[80962]: https://github.com/rust-lang/rust/pull/80962
6156[80553]: https://github.com/rust-lang/rust/pull/80553
6157[80527]: https://github.com/rust-lang/rust/pull/80527
6158[79519]: https://github.com/rust-lang/rust/pull/79519
6159[79423]: https://github.com/rust-lang/rust/pull/79423
6160[79208]: https://github.com/rust-lang/rust/pull/79208
6161[78429]: https://github.com/rust-lang/rust/pull/78429
6162[82733]: https://github.com/rust-lang/rust/pull/82733
6163[82594]: https://github.com/rust-lang/rust/pull/82594
6164[79078]: https://github.com/rust-lang/rust/pull/79078
6165[cargo/9181]: https://github.com/rust-lang/cargo/pull/9181
6166[`char::MAX`]: https://doc.rust-lang.org/std/primitive.char.html#associatedconstant.MAX
6167[`char::REPLACEMENT_CHARACTER`]: https://doc.rust-lang.org/std/primitive.char.html#associatedconstant.REPLACEMENT_CHARACTER
6168[`char::UNICODE_VERSION`]: https://doc.rust-lang.org/std/primitive.char.html#associatedconstant.UNICODE_VERSION
6169[`char::decode_utf16`]: https://doc.rust-lang.org/std/primitive.char.html#method.decode_utf16
6170[`char::from_u32`]: https://doc.rust-lang.org/std/primitive.char.html#method.from_u32
6171[`char::from_u32_unchecked`]: https://doc.rust-lang.org/std/primitive.char.html#method.from_u32_unchecked
6172[`char::from_digit`]: https://doc.rust-lang.org/std/primitive.char.html#method.from_digit
6173[`Peekable::next_if`]: https://doc.rust-lang.org/stable/std/iter/struct.Peekable.html#method.next_if
6174[`Peekable::next_if_eq`]: https://doc.rust-lang.org/stable/std/iter/struct.Peekable.html#method.next_if_eq
6175[`Arguments::as_str`]: https://doc.rust-lang.org/stable/std/fmt/struct.Arguments.html#method.as_str
6176[`str::split_once`]: https://doc.rust-lang.org/stable/std/primitive.str.html#method.split_once
6177[`str::rsplit_once`]: https://doc.rust-lang.org/stable/std/primitive.str.html#method.rsplit_once
6178[`slice::partition_point`]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.partition_point
6179[`char::len_utf8`]: https://doc.rust-lang.org/stable/std/primitive.char.html#method.len_utf8
6180[`char::len_utf16`]: https://doc.rust-lang.org/stable/std/primitive.char.html#method.len_utf16
6181[`char::to_ascii_uppercase`]: https://doc.rust-lang.org/stable/std/primitive.char.html#method.to_ascii_uppercase
6182[`char::to_ascii_lowercase`]: https://doc.rust-lang.org/stable/std/primitive.char.html#method.to_ascii_lowercase
6183[`char::eq_ignore_ascii_case`]: https://doc.rust-lang.org/stable/std/primitive.char.html#method.eq_ignore_ascii_case
6184[`u8::to_ascii_uppercase`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.to_ascii_uppercase
6185[`u8::to_ascii_lowercase`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.to_ascii_lowercase
6186[`u8::eq_ignore_ascii_case`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.eq_ignore_ascii_case
6187
6188Version 1.51.0 (2021-03-25)
6189============================
6190
6191Language
6192--------
6193- [You can now parameterize items such as functions, traits, and `struct`s by constant
6194 values in addition to by types and lifetimes.][79135] Also known as "const generics"
6195 E.g. you can now write the following. Note: Only values of primitive integers,
6196 `bool`, or `char` types are currently permitted.
6197 ```rust
6198 struct GenericArray<T, const LENGTH: usize> {
6199 inner: [T; LENGTH]
6200 }
6201
6202 impl<T, const LENGTH: usize> GenericArray<T, LENGTH> {
6203 const fn last(&self) -> Option<&T> {
6204 if LENGTH == 0 {
6205 None
6206 } else {
6207 Some(&self.inner[LENGTH - 1])
6208 }
6209 }
6210 }
6211 ```
6212
6213
6214Compiler
6215--------
6216
6217- [Added the `-Csplit-debuginfo` codegen option for macOS platforms.][79570]
6218 This option controls whether debug information is split across multiple files
6219 or packed into a single file. **Note** This option is unstable on other platforms.
6220- [Added tier 3\* support for `aarch64_be-unknown-linux-gnu`,
6221 `aarch64-unknown-linux-gnu_ilp32`, and `aarch64_be-unknown-linux-gnu_ilp32` targets.][81455]
6222- [Added tier 3 support for `i386-unknown-linux-gnu` and `i486-unknown-linux-gnu` targets.][80662]
6223- [The `target-cpu=native` option will now detect individual features of CPUs.][80749]
6224
6225\* Refer to Rust's [platform support page][platform-support-doc] for more
6226information on Rust's tiered platform support.
6227
6228Libraries
6229---------
6230
6231- [`Box::downcast` is now also implemented for any `dyn Any + Send + Sync` object.][80945]
6232- [`str` now implements `AsMut<str>`.][80279]
6233- [`u64` and `u128` now implement `From<char>`.][79502]
6234- [`Error` is now implemented for `&T` where `T` implements `Error`.][75180]
6235- [`Poll::{map_ok, map_err}` are now implemented for `Poll<Option<Result<T, E>>>`.][80968]
6236- [`unsigned_abs` is now implemented for all signed integer types.][80959]
6237- [`io::Empty` now implements `io::Seek`.][78044]
6238- [`rc::Weak<T>` and `sync::Weak<T>`'s methods such as `as_ptr` are now implemented for
6239 `T: ?Sized` types.][80764]
6240- [`Div` and `Rem` by their `NonZero` variant is now implemented for all unsigned integers.][79134]
6241
6242
6243Stabilized APIs
6244---------------
6245
6246- [`Arc::decrement_strong_count`]
6247- [`Arc::increment_strong_count`]
6248- [`Once::call_once_force`]
6249- [`Peekable::next_if_eq`]
6250- [`Peekable::next_if`]
6251- [`Seek::stream_position`]
6252- [`array::IntoIter`]
6253- [`panic::panic_any`]
6254- [`ptr::addr_of!`]
6255- [`ptr::addr_of_mut!`]
6256- [`slice::fill_with`]
6257- [`slice::split_inclusive_mut`]
6258- [`slice::split_inclusive`]
6259- [`slice::strip_prefix`]
6260- [`slice::strip_suffix`]
6261- [`str::split_inclusive`]
6262- [`sync::OnceState`]
6263- [`task::Wake`]
6264- [`VecDeque::range`]
6265- [`VecDeque::range_mut`]
6266
6267Cargo
6268-----
6269- [Added the `split-debuginfo` profile option to control the -Csplit-debuginfo
6270 codegen option.][cargo/9112]
6271- [Added the `resolver` field to `Cargo.toml` to enable the new feature resolver
6272 and CLI option behavior.][cargo/8997] Version 2 of the feature resolver will try
6273 to avoid unifying features of dependencies where that unification could be unwanted.
6274 Such as using the same dependency with a `std` feature in a build scripts and
6275 proc-macros, while using the `no-std` feature in the final binary. See the
6276 [Cargo book documentation][feature-resolver@2.0] for more information on the feature.
6277
6278Rustdoc
6279-------
6280
6281- [Rustdoc will now include documentation for methods available from _nested_ `Deref` traits.][80653]
6282- [You can now provide a `--default-theme` flag which sets the default theme to use for
6283 documentation.][79642]
6284
6285Various improvements to intra-doc links:
6286
6287- [You can link to non-path primitives such as `slice`.][80181]
6288- [You can link to associated items.][74489]
6289- [You can now include generic parameters when linking to items, like `Vec<T>`.][76934]
6290
6291Misc
6292----
6293- [You can now pass `--include-ignored` to tests (e.g. with
6294 `cargo test -- --include-ignored`) to include testing tests marked `#[ignore]`.][80053]
6295
6296Compatibility Notes
6297-------------------
6298
6299- [WASI platforms no longer use the `wasm-bindgen` ABI, and instead use the wasm32 ABI.][79998]
6300- [`rustc` no longer promotes division, modulo and indexing operations to `const` that
6301 could fail.][80579]
6302- [The minimum version of glibc for the following platforms has been bumped to version 2.31
6303 for the distributed artifacts.][81521]
6304 - `armv5te-unknown-linux-gnueabi`
6305 - `sparc64-unknown-linux-gnu`
6306 - `thumbv7neon-unknown-linux-gnueabihf`
6307 - `armv7-unknown-linux-gnueabi`
6308 - `x86_64-unknown-linux-gnux32`
6309- [`atomic::spin_loop_hint` has been deprecated.][80966] It's recommended to use `hint::spin_loop` instead.
6310
6311Internal Only
6312-------------
6313
6314- [Consistently avoid constructing optimized MIR when not doing codegen][80718]
6315
6316[79135]: https://github.com/rust-lang/rust/pull/79135
6317[74489]: https://github.com/rust-lang/rust/pull/74489
6318[76934]: https://github.com/rust-lang/rust/pull/76934
6319[79570]: https://github.com/rust-lang/rust/pull/79570
6320[80181]: https://github.com/rust-lang/rust/pull/80181
6321[79642]: https://github.com/rust-lang/rust/pull/79642
6322[80945]: https://github.com/rust-lang/rust/pull/80945
6323[80279]: https://github.com/rust-lang/rust/pull/80279
6324[80053]: https://github.com/rust-lang/rust/pull/80053
6325[79502]: https://github.com/rust-lang/rust/pull/79502
6326[75180]: https://github.com/rust-lang/rust/pull/75180
6327[81521]: https://github.com/rust-lang/rust/pull/81521
6328[80968]: https://github.com/rust-lang/rust/pull/80968
6329[80959]: https://github.com/rust-lang/rust/pull/80959
6330[80718]: https://github.com/rust-lang/rust/pull/80718
6331[80653]: https://github.com/rust-lang/rust/pull/80653
6332[80579]: https://github.com/rust-lang/rust/pull/80579
6333[79998]: https://github.com/rust-lang/rust/pull/79998
6334[78044]: https://github.com/rust-lang/rust/pull/78044
6335[81455]: https://github.com/rust-lang/rust/pull/81455
6336[80764]: https://github.com/rust-lang/rust/pull/80764
6337[80749]: https://github.com/rust-lang/rust/pull/80749
6338[80662]: https://github.com/rust-lang/rust/pull/80662
6339[79134]: https://github.com/rust-lang/rust/pull/79134
6340[80966]: https://github.com/rust-lang/rust/pull/80966
6341[cargo/8997]: https://github.com/rust-lang/cargo/pull/8997
6342[cargo/9112]: https://github.com/rust-lang/cargo/pull/9112
6343[feature-resolver@2.0]: https://doc.rust-lang.org/nightly/cargo/reference/features.html#feature-resolver-version-2
6344[`Once::call_once_force`]: https://doc.rust-lang.org/stable/std/sync/struct.Once.html#method.call_once_force
6345[`sync::OnceState`]: https://doc.rust-lang.org/stable/std/sync/struct.OnceState.html
6346[`panic::panic_any`]: https://doc.rust-lang.org/stable/std/panic/fn.panic_any.html
6347[`slice::strip_prefix`]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.strip_prefix
6348[`slice::strip_suffix`]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.strip_suffix
6349[`Arc::increment_strong_count`]: https://doc.rust-lang.org/nightly/std/sync/struct.Arc.html#method.increment_strong_count
6350[`Arc::decrement_strong_count`]: https://doc.rust-lang.org/nightly/std/sync/struct.Arc.html#method.decrement_strong_count
6351[`slice::fill_with`]: https://doc.rust-lang.org/nightly/std/primitive.slice.html#method.fill_with
6352[`ptr::addr_of!`]: https://doc.rust-lang.org/nightly/std/ptr/macro.addr_of.html
6353[`ptr::addr_of_mut!`]: https://doc.rust-lang.org/nightly/std/ptr/macro.addr_of_mut.html
6354[`array::IntoIter`]: https://doc.rust-lang.org/nightly/std/array/struct.IntoIter.html
6355[`slice::split_inclusive`]: https://doc.rust-lang.org/nightly/std/primitive.slice.html#method.split_inclusive
6356[`slice::split_inclusive_mut`]: https://doc.rust-lang.org/nightly/std/primitive.slice.html#method.split_inclusive_mut
6357[`str::split_inclusive`]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.split_inclusive
6358[`task::Wake`]: https://doc.rust-lang.org/nightly/std/task/trait.Wake.html
6359[`Seek::stream_position`]: https://doc.rust-lang.org/nightly/std/io/trait.Seek.html#method.stream_position
6360[`Peekable::next_if`]: https://doc.rust-lang.org/nightly/std/iter/struct.Peekable.html#method.next_if
6361[`Peekable::next_if_eq`]: https://doc.rust-lang.org/nightly/std/iter/struct.Peekable.html#method.next_if_eq
6362[`VecDeque::range`]: https://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.range
6363[`VecDeque::range_mut`]: https://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.range_mut
6364
6365Version 1.50.0 (2021-02-11)
6366============================
6367
6368Language
6369-----------------------
6370- [You can now use `const` values for `x` in `[x; N]` array expressions.][79270]
6371 This has been technically possible since 1.38.0, as it was unintentionally stabilized.
6372- [Assignments to `ManuallyDrop<T>` union fields are now considered safe.][78068]
6373
6374Compiler
6375-----------------------
6376- [Added tier 3\* support for the `armv5te-unknown-linux-uclibceabi` target.][78142]
6377- [Added tier 3 support for the `aarch64-apple-ios-macabi` target.][77484]
6378- [The `x86_64-unknown-freebsd` is now built with the full toolset.][79484]
6379- [Dropped support for all cloudabi targets.][78439]
6380
6381\* Refer to Rust's [platform support page][platform-support-doc] for more
6382information on Rust's tiered platform support.
6383
6384Libraries
6385-----------------------
6386
6387- [`proc_macro::Punct` now implements `PartialEq<char>`.][78636]
6388- [`ops::{Index, IndexMut}` are now implemented for fixed sized arrays of any length.][74989]
6389- [On Unix platforms, the `std::fs::File` type now has a "niche" of `-1`.][74699]
6390 This value cannot be a valid file descriptor, and now means `Option<File>` takes
6391 up the same amount of space as `File`.
6392
6393Stabilized APIs
6394---------------
6395
6396- [`bool::then`]
6397- [`btree_map::Entry::or_insert_with_key`]
6398- [`f32::clamp`]
6399- [`f64::clamp`]
6400- [`hash_map::Entry::or_insert_with_key`]
6401- [`Ord::clamp`]
6402- [`RefCell::take`]
6403- [`slice::fill`]
6404- [`UnsafeCell::get_mut`]
6405
6406The following previously stable methods are now `const`.
6407
6408- [`IpAddr::is_ipv4`]
6409- [`IpAddr::is_ipv6`]
6410- [`IpAddr::is_unspecified`]
6411- [`IpAddr::is_loopback`]
6412- [`IpAddr::is_multicast`]
6413- [`Ipv4Addr::octets`]
6414- [`Ipv4Addr::is_loopback`]
6415- [`Ipv4Addr::is_private`]
6416- [`Ipv4Addr::is_link_local`]
6417- [`Ipv4Addr::is_multicast`]
6418- [`Ipv4Addr::is_broadcast`]
6419- [`Ipv4Addr::is_documentation`]
6420- [`Ipv4Addr::to_ipv6_compatible`]
6421- [`Ipv4Addr::to_ipv6_mapped`]
6422- [`Ipv6Addr::segments`]
6423- [`Ipv6Addr::is_unspecified`]
6424- [`Ipv6Addr::is_loopback`]
6425- [`Ipv6Addr::is_multicast`]
6426- [`Ipv6Addr::to_ipv4`]
6427- [`Layout::size`]
6428- [`Layout::align`]
6429- [`Layout::from_size_align`]
6430- `pow` for all integer types.
6431- `checked_pow` for all integer types.
6432- `saturating_pow` for all integer types.
6433- `wrapping_pow` for all integer types.
6434- `next_power_of_two` for all unsigned integer types.
6435- `checked_next_power_of_two` for all unsigned integer types.
6436
6437Cargo
6438-----------------------
6439
6440- [Added the `[build.rustc-workspace-wrapper]` option.][cargo/8976]
6441 This option sets a wrapper to execute instead of `rustc`, for workspace members only.
6442- [`cargo:rerun-if-changed` will now, if provided a directory, scan the entire
6443 contents of that directory for changes.][cargo/8973]
6444- [Added the `--workspace` flag to the `cargo update` command.][cargo/8725]
6445
6446Misc
6447----
6448
6449- [The search results tab and the help button are focusable with keyboard in rustdoc.][79896]
6450- [Running tests will now print the total time taken to execute.][75752]
6451
6452Compatibility Notes
6453-------------------
6454
6455- [The `compare_and_swap` method on atomics has been deprecated.][79261] It's
6456 recommended to use the `compare_exchange` and `compare_exchange_weak` methods instead.
6457- [Changes in how `TokenStream`s are checked have fixed some cases where you could write
6458 unhygenic `macro_rules!` macros.][79472]
6459- [`#![test]` as an inner attribute is now considered unstable like other inner macro
6460 attributes, and reports an error by default through the `soft_unstable` lint.][79003]
6461- [Overriding a `forbid` lint at the same level that it was set is now a hard error.][78864]
6462- [You can no longer intercept `panic!` calls by supplying your own macro.][78343] It's
6463 recommended to use the `#[panic_handler]` attribute to provide your own implementation.
6464- [Semi-colons after item statements (e.g. `struct Foo {};`) now produce a warning.][78296]
6465
6466[74989]: https://github.com/rust-lang/rust/pull/74989
6467[79261]: https://github.com/rust-lang/rust/pull/79261
6468[79896]: https://github.com/rust-lang/rust/pull/79896
6469[79484]: https://github.com/rust-lang/rust/pull/79484
6470[79472]: https://github.com/rust-lang/rust/pull/79472
6471[79270]: https://github.com/rust-lang/rust/pull/79270
6472[79003]: https://github.com/rust-lang/rust/pull/79003
6473[78864]: https://github.com/rust-lang/rust/pull/78864
6474[78636]: https://github.com/rust-lang/rust/pull/78636
6475[78439]: https://github.com/rust-lang/rust/pull/78439
6476[78343]: https://github.com/rust-lang/rust/pull/78343
6477[78296]: https://github.com/rust-lang/rust/pull/78296
6478[78068]: https://github.com/rust-lang/rust/pull/78068
6479[75752]: https://github.com/rust-lang/rust/pull/75752
6480[74699]: https://github.com/rust-lang/rust/pull/74699
6481[78142]: https://github.com/rust-lang/rust/pull/78142
6482[77484]: https://github.com/rust-lang/rust/pull/77484
6483[cargo/8976]: https://github.com/rust-lang/cargo/pull/8976
6484[cargo/8973]: https://github.com/rust-lang/cargo/pull/8973
6485[cargo/8725]: https://github.com/rust-lang/cargo/pull/8725
6486[`IpAddr::is_ipv4`]: https://doc.rust-lang.org/stable/std/net/enum.IpAddr.html#method.is_ipv4
6487[`IpAddr::is_ipv6`]: https://doc.rust-lang.org/stable/std/net/enum.IpAddr.html#method.is_ipv6
6488[`IpAddr::is_unspecified`]: https://doc.rust-lang.org/stable/std/net/enum.IpAddr.html#method.is_unspecified
6489[`IpAddr::is_loopback`]: https://doc.rust-lang.org/stable/std/net/enum.IpAddr.html#method.is_loopback
6490[`IpAddr::is_multicast`]: https://doc.rust-lang.org/stable/std/net/enum.IpAddr.html#method.is_multicast
6491[`Ipv4Addr::octets`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.octets
6492[`Ipv4Addr::is_loopback`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.is_loopback
6493[`Ipv4Addr::is_private`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.is_private
6494[`Ipv4Addr::is_link_local`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.is_link_local
6495[`Ipv4Addr::is_multicast`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.is_multicast
6496[`Ipv4Addr::is_broadcast`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.is_broadcast
6497[`Ipv4Addr::is_documentation`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.is_documentation
6498[`Ipv4Addr::to_ipv6_compatible`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.to_ipv6_compatible
6499[`Ipv4Addr::to_ipv6_mapped`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv4Addr.html#method.to_ipv6_mapped
6500[`Ipv6Addr::segments`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv6Addr.html#method.segments
6501[`Ipv6Addr::is_unspecified`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv6Addr.html#method.is_unspecified
6502[`Ipv6Addr::is_loopback`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv6Addr.html#method.is_loopback
6503[`Ipv6Addr::is_multicast`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv6Addr.html#method.is_multicast
6504[`Ipv6Addr::to_ipv4`]: https://doc.rust-lang.org/stable/std/net/struct.Ipv6Addr.html#method.to_ipv4
6505[`Layout::align`]: https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.align
6506[`Layout::from_size_align`]: https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.from_size_align
6507[`Layout::size`]: https://doc.rust-lang.org/stable/std/alloc/struct.Layout.html#method.size
6508[`Ord::clamp`]: https://doc.rust-lang.org/stable/std/cmp/trait.Ord.html#method.clamp
6509[`RefCell::take`]: https://doc.rust-lang.org/stable/std/cell/struct.RefCell.html#method.take
6510[`UnsafeCell::get_mut`]: https://doc.rust-lang.org/stable/std/cell/struct.UnsafeCell.html#method.get_mut
6511[`bool::then`]: https://doc.rust-lang.org/stable/std/primitive.bool.html#method.then
6512[`btree_map::Entry::or_insert_with_key`]: https://doc.rust-lang.org/stable/std/collections/btree_map/enum.Entry.html#method.or_insert_with_key
6513[`f32::clamp`]: https://doc.rust-lang.org/stable/std/primitive.f32.html#method.clamp
6514[`f64::clamp`]: https://doc.rust-lang.org/stable/std/primitive.f64.html#method.clamp
6515[`hash_map::Entry::or_insert_with_key`]: https://doc.rust-lang.org/stable/std/collections/hash_map/enum.Entry.html#method.or_insert_with_key
6516[`slice::fill`]: https://doc.rust-lang.org/stable/std/primitive.slice.html#method.fill
6517
6518
6519Version 1.49.0 (2020-12-31)
6520============================
6521
6522Language
6523-----------------------
6524
6525- [Unions can now implement `Drop`, and you can now have a field in a union
6526 with `ManuallyDrop<T>`.][77547]
6527- [You can now cast uninhabited enums to integers.][76199]
6528- [You can now bind by reference and by move in patterns.][76119] This
6529 allows you to selectively borrow individual components of a type. E.g.
6530 ```rust
6531 #[derive(Debug)]
6532 struct Person {
6533 name: String,
6534 age: u8,
6535 }
6536
6537 let person = Person {
6538 name: String::from("Alice"),
6539 age: 20,
6540 };
6541
6542 // `name` is moved out of person, but `age` is referenced.
6543 let Person { name, ref age } = person;
6544 println!("{} {}", name, age);
6545 ```
6546
6547Compiler
6548-----------------------
6549
6550- [Added tier 1\* support for `aarch64-unknown-linux-gnu`.][78228]
6551- [Added tier 2 support for `aarch64-apple-darwin`.][75991]
6552- [Added tier 2 support for `aarch64-pc-windows-msvc`.][75914]
6553- [Added tier 3 support for `mipsel-unknown-none`.][78676]
6554- [Raised the minimum supported LLVM version to LLVM 9.][78848]
6555- [Output from threads spawned in tests is now captured.][78227]
6556- [Change os and vendor values to "none" and "unknown" for some targets][78951]
6557
6558\* Refer to Rust's [platform support page][platform-support-doc] for more
6559information on Rust's tiered platform support.
6560
6561Libraries
6562-----------------------
6563
6564- [`RangeInclusive` now checks for exhaustion when calling `contains` and indexing.][78109]
6565- [`ToString::to_string` now no longer shrinks the internal buffer in the default implementation.][77997]
6566
6567Stabilized APIs
6568---------------
6569
6570- [`slice::select_nth_unstable`]
6571- [`slice::select_nth_unstable_by`]
6572- [`slice::select_nth_unstable_by_key`]
6573
6574The following previously stable methods are now `const`.
6575
6576- [`Poll::is_ready`]
6577- [`Poll::is_pending`]
6578
6579Cargo
6580-----------------------
6581- [Building a crate with `cargo-package` should now be independently reproducible.][cargo/8864]
6582- [`cargo-tree` now marks proc-macro crates.][cargo/8765]
6583- [Added `CARGO_PRIMARY_PACKAGE` build-time environment variable.][cargo/8758] This
6584 variable will be set if the crate being built is one the user selected to build, either
6585 with `-p` or through defaults.
6586- [You can now use glob patterns when specifying packages & targets.][cargo/8752]
6587
6588
6589Compatibility Notes
6590-------------------
6591
6592- [Demoted `i686-unknown-freebsd` from host tier 2 to target tier 2 support.][78746]
6593- [Macros that end with a semi-colon are now treated as statements even if they expand to nothing.][78376]
6594- [Rustc will now check for the validity of some built-in attributes on enum variants.][77015]
6595 Previously such invalid or unused attributes could be ignored.
6596- Leading whitespace is stripped more uniformly in documentation comments, which may change behavior. You
6597 read [this post about the changes][rustdoc-ws-post] for more details.
6598- [Trait bounds are no longer inferred for associated types.][79904]
6599
6600Internal Only
6601-------------
6602These changes provide no direct user facing benefits, but represent significant
6603improvements to the internals and overall performance of rustc and
6604related tools.
6605
6606- [rustc's internal crates are now compiled using the `initial-exec` Thread
6607 Local Storage model.][78201]
6608- [Calculate visibilities once in resolve.][78077]
6609- [Added `system` to the `llvm-libunwind` bootstrap config option.][77703]
6610- [Added `--color` for configuring terminal color support to bootstrap.][79004]
6611
6612
6613[75991]: https://github.com/rust-lang/rust/pull/75991
6614[78951]: https://github.com/rust-lang/rust/pull/78951
6615[78848]: https://github.com/rust-lang/rust/pull/78848
6616[78746]: https://github.com/rust-lang/rust/pull/78746
6617[78376]: https://github.com/rust-lang/rust/pull/78376
6618[78228]: https://github.com/rust-lang/rust/pull/78228
6619[78227]: https://github.com/rust-lang/rust/pull/78227
6620[78201]: https://github.com/rust-lang/rust/pull/78201
6621[78109]: https://github.com/rust-lang/rust/pull/78109
6622[78077]: https://github.com/rust-lang/rust/pull/78077
6623[77997]: https://github.com/rust-lang/rust/pull/77997
6624[77703]: https://github.com/rust-lang/rust/pull/77703
6625[77547]: https://github.com/rust-lang/rust/pull/77547
6626[77015]: https://github.com/rust-lang/rust/pull/77015
6627[76199]: https://github.com/rust-lang/rust/pull/76199
6628[76119]: https://github.com/rust-lang/rust/pull/76119
6629[75914]: https://github.com/rust-lang/rust/pull/75914
6630[79004]: https://github.com/rust-lang/rust/pull/79004
6631[78676]: https://github.com/rust-lang/rust/pull/78676
6632[79904]: https://github.com/rust-lang/rust/issues/79904
6633[cargo/8864]: https://github.com/rust-lang/cargo/pull/8864
6634[cargo/8765]: https://github.com/rust-lang/cargo/pull/8765
6635[cargo/8758]: https://github.com/rust-lang/cargo/pull/8758
6636[cargo/8752]: https://github.com/rust-lang/cargo/pull/8752
6637[`slice::select_nth_unstable`]: https://doc.rust-lang.org/nightly/std/primitive.slice.html#method.select_nth_unstable
6638[`slice::select_nth_unstable_by`]: https://doc.rust-lang.org/nightly/std/primitive.slice.html#method.select_nth_unstable_by
6639[`slice::select_nth_unstable_by_key`]: https://doc.rust-lang.org/nightly/std/primitive.slice.html#method.select_nth_unstable_by_key
6640[`Poll::is_ready`]: https://doc.rust-lang.org/stable/std/task/enum.Poll.html#method.is_ready
6641[`Poll::is_pending`]: https://doc.rust-lang.org/stable/std/task/enum.Poll.html#method.is_pending
6642[rustdoc-ws-post]: https://blog.guillaume-gomez.fr/articles/2020-11-11+New+doc+comment+handling+in+rustdoc
6643
6644Version 1.48.0 (2020-11-19)
6645==========================
6646
6647Language
6648--------
6649
6650- [The `unsafe` keyword is now syntactically permitted on modules.][75857] This
6651 is still rejected *semantically*, but can now be parsed by procedural macros.
6652
6653Compiler
6654--------
6655- [Stabilised the `-C link-self-contained=<yes|no>` compiler flag.][76158] This tells
6656 `rustc` whether to link its own C runtime and libraries or to rely on a external
6657 linker to find them. (Supported only on `windows-gnu`, `linux-musl`, and `wasi` platforms.)
6658- [You can now use `-C target-feature=+crt-static` on `linux-gnu` targets.][77386]
6659 Note: If you're using cargo you must explicitly pass the `--target` flag.
6660- [Added tier 2\* support for `aarch64-unknown-linux-musl`.][76420]
6661
6662\* Refer to Rust's [platform support page][platform-support-doc] for more
6663information on Rust's tiered platform support.
6664
6665Libraries
6666---------
6667- [`io::Write` is now implemented for `&ChildStdin` `&Sink`, `&Stdout`,
6668 and `&Stderr`.][76275]
6669- [All arrays of any length now implement `TryFrom<Vec<T>>`.][76310]
6670- [The `matches!` macro now supports having a trailing comma.][74880]
6671- [`Vec<A>` now implements `PartialEq<[B]>` where `A: PartialEq<B>`.][74194]
6672- [The `RefCell::{replace, replace_with, clone}` methods now all use `#[track_caller]`.][77055]
6673
6674Stabilized APIs
6675---------------
6676- [`slice::as_ptr_range`]
6677- [`slice::as_mut_ptr_range`]
6678- [`VecDeque::make_contiguous`]
6679- [`future::pending`]
6680- [`future::ready`]
6681
6682The following previously stable methods are now `const fn`'s:
6683
6684- [`Option::is_some`]
6685- [`Option::is_none`]
6686- [`Option::as_ref`]
6687- [`Result::is_ok`]
6688- [`Result::is_err`]
6689- [`Result::as_ref`]
6690- [`Ordering::reverse`]
6691- [`Ordering::then`]
6692
6693Cargo
6694-----
6695
6696Rustdoc
6697-------
6698- [You can now link to items in `rustdoc` using the intra-doc link
6699 syntax.][74430] E.g. ``/// Uses [`std::future`]`` will automatically generate
6700 a link to `std::future`'s documentation. See ["Linking to items by
6701 name"][intradoc-links] for more information.
6702- [You can now specify `#[doc(alias = "<alias>")]` on items to add search aliases
6703 when searching through `rustdoc`'s UI.][75740]
6704
6705Compatibility Notes
6706-------------------
6707- [Promotion of references to `'static` lifetime inside `const fn` now follows the
6708 same rules as inside a `fn` body.][75502] In particular, `&foo()` will not be
6709 promoted to `'static` lifetime any more inside `const fn`s.
6710- [Associated type bindings on trait objects are now verified to meet the bounds
6711 declared on the trait when checking that they implement the trait.][27675]
6712- [When trait bounds on associated types or opaque types are ambiguous, the
6713 compiler no longer makes an arbitrary choice on which bound to use.][54121]
6714- [Fixed recursive nonterminals not being expanded in macros during
6715 pretty-print/reparse check.][77153] This may cause errors if your macro wasn't
6716 correctly handling recursive nonterminal tokens.
6717- [`&mut` references to non zero-sized types are no longer promoted.][75585]
6718- [`rustc` will now warn if you use attributes like `#[link_name]` or `#[cold]`
6719 in places where they have no effect.][73461]
6720- [Updated `_mm256_extract_epi8` and `_mm256_extract_epi16` signatures in
6721 `arch::{x86, x86_64}` to return `i32` to match the vendor signatures.][73166]
6722- [`mem::uninitialized` will now panic if any inner types inside a struct or enum
6723 disallow zero-initialization.][71274]
6724- [`#[target_feature]` will now error if used in a place where it has no effect.][78143]
6725- [Foreign exceptions are now caught by `catch_unwind` and will cause an abort.][70212]
6726 Note: This behaviour is not guaranteed and is still considered undefined behaviour,
6727 see the [`catch_unwind`] documentation for further information.
6728
6729
6730
6731Internal Only
6732-------------
6733These changes provide no direct user facing benefits, but represent significant
6734improvements to the internals and overall performance of rustc and
6735related tools.
6736
6737- [Building `rustc` from source now uses `ninja` by default over `make`.][74922]
6738 You can continue building with `make` by setting `ninja=false` in
6739 your `bootstrap.toml`.
6740- [cg_llvm: `fewer_names` in `uncached_llvm_type`][76030]
6741- [Made `ensure_sufficient_stack()` non-generic][76680]
6742
6743[78143]: https://github.com/rust-lang/rust/issues/78143
6744[76680]: https://github.com/rust-lang/rust/pull/76680/
6745[76030]: https://github.com/rust-lang/rust/pull/76030/
6746[70212]: https://github.com/rust-lang/rust/pull/70212/
6747[27675]: https://github.com/rust-lang/rust/issues/27675/
6748[54121]: https://github.com/rust-lang/rust/issues/54121/
6749[71274]: https://github.com/rust-lang/rust/pull/71274/
6750[77386]: https://github.com/rust-lang/rust/pull/77386/
6751[77153]: https://github.com/rust-lang/rust/pull/77153/
6752[77055]: https://github.com/rust-lang/rust/pull/77055/
6753[76275]: https://github.com/rust-lang/rust/pull/76275/
6754[76310]: https://github.com/rust-lang/rust/pull/76310/
6755[76420]: https://github.com/rust-lang/rust/pull/76420/
6756[76158]: https://github.com/rust-lang/rust/pull/76158/
6757[75857]: https://github.com/rust-lang/rust/pull/75857/
6758[75585]: https://github.com/rust-lang/rust/pull/75585/
6759[75740]: https://github.com/rust-lang/rust/pull/75740/
6760[75502]: https://github.com/rust-lang/rust/pull/75502/
6761[74880]: https://github.com/rust-lang/rust/pull/74880/
6762[74922]: https://github.com/rust-lang/rust/pull/74922/
6763[74430]: https://github.com/rust-lang/rust/pull/74430/
6764[74194]: https://github.com/rust-lang/rust/pull/74194/
6765[73461]: https://github.com/rust-lang/rust/pull/73461/
6766[73166]: https://github.com/rust-lang/rust/pull/73166/
6767[intradoc-links]: https://doc.rust-lang.org/rustdoc/linking-to-items-by-name.html
6768[`catch_unwind`]: https://doc.rust-lang.org/std/panic/fn.catch_unwind.html
6769[`Option::is_some`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.is_some
6770[`Option::is_none`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.is_none
6771[`Option::as_ref`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.as_ref
6772[`Result::is_ok`]: https://doc.rust-lang.org/std/result/enum.Result.html#method.is_ok
6773[`Result::is_err`]: https://doc.rust-lang.org/std/result/enum.Result.html#method.is_err
6774[`Result::as_ref`]: https://doc.rust-lang.org/std/result/enum.Result.html#method.as_ref
6775[`Ordering::reverse`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.reverse
6776[`Ordering::then`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.then
6777[`slice::as_ptr_range`]: https://doc.rust-lang.org/std/primitive.slice.html#method.as_ptr_range
6778[`slice::as_mut_ptr_range`]: https://doc.rust-lang.org/std/primitive.slice.html#method.as_mut_ptr_range
6779[`VecDeque::make_contiguous`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.make_contiguous
6780[`future::pending`]: https://doc.rust-lang.org/std/future/fn.pending.html
6781[`future::ready`]: https://doc.rust-lang.org/std/future/fn.ready.html
6782
6783
6784Version 1.47.0 (2020-10-08)
6785==========================
6786
6787Language
6788--------
6789- [Closures will now warn when not used.][74869]
6790
6791Compiler
6792--------
6793- [Stabilized the `-C control-flow-guard` codegen option][73893], which enables
6794 [Control Flow Guard][1.47.0-cfg] for Windows platforms, and is ignored on other
6795 platforms.
6796- [Upgraded to LLVM 11.][73526]
6797- [Added tier 3\* support for the `thumbv4t-none-eabi` target.][74419]
6798- [Upgrade the FreeBSD toolchain to version 11.4][75204]
6799- [`RUST_BACKTRACE`'s output is now more compact.][75048]
6800
6801\* Refer to Rust's [platform support page][platform-support-doc] for more
6802information on Rust's tiered platform support.
6803
6804Libraries
6805---------
6806- [`CStr` now implements `Index<RangeFrom<usize>>`.][74021]
6807- [Traits in `std`/`core` are now implemented for arrays of any length, not just
6808 those of length less than 33.][74060]
6809- [`ops::RangeFull` and `ops::Range` now implement Default.][73197]
6810- [`panic::Location` now implements `Copy`, `Clone`, `Eq`, `Hash`, `Ord`,
6811 `PartialEq`, and `PartialOrd`.][73583]
6812
6813Stabilized APIs
6814---------------
6815- [`Ident::new_raw`]
6816- [`Range::is_empty`]
6817- [`RangeInclusive::is_empty`]
6818- [`Result::as_deref`]
6819- [`Result::as_deref_mut`]
6820- [`Vec::leak`]
6821- [`pointer::offset_from`]
6822- [`f32::TAU`]
6823- [`f64::TAU`]
6824
6825The following previously stable APIs have now been made const.
6826
6827- [The `new` method for all `NonZero` integers.][73858]
6828- [The `checked_add`,`checked_sub`,`checked_mul`,`checked_neg`, `checked_shl`,
6829 `checked_shr`, `saturating_add`, `saturating_sub`, and `saturating_mul`
6830 methods for all integers.][73858]
6831- [The `checked_abs`, `saturating_abs`, `saturating_neg`, and `signum` for all
6832 signed integers.][73858]
6833- [The `is_ascii_alphabetic`, `is_ascii_uppercase`, `is_ascii_lowercase`,
6834 `is_ascii_alphanumeric`, `is_ascii_digit`, `is_ascii_hexdigit`,
6835 `is_ascii_punctuation`, `is_ascii_graphic`, `is_ascii_whitespace`, and
6836 `is_ascii_control` methods for `char` and `u8`.][73858]
6837
6838Cargo
6839-----
6840- [`build-dependencies` are now built with opt-level 0 by default.][cargo/8500]
6841 You can override this by setting the following in your `Cargo.toml`.
6842 ```toml
6843 [profile.release.build-override]
6844 opt-level = 3
6845 ```
6846- [`cargo-help` will now display man pages for commands rather just the
6847 `--help` text.][cargo/8456]
6848- [`cargo-metadata` now emits a `test` field indicating if a target has
6849 tests enabled.][cargo/8478]
6850- [`workspace.default-members` now respects `workspace.exclude`.][cargo/8485]
6851- [`cargo-publish` will now use an alternative registry by default if it's the
6852 only registry specified in `package.publish`.][cargo/8571]
6853
6854Misc
6855----
6856- [Added a help button beside Rustdoc's searchbar that explains rustdoc's
6857 type based search.][75366]
6858- [Added the Ayu theme to rustdoc.][71237]
6859
6860Compatibility Notes
6861-------------------
6862- [Bumped the minimum supported Emscripten version to 1.39.20.][75716]
6863- [Fixed a regression parsing `{} && false` in tail expressions.][74650]
6864- [Added changes to how proc-macros are expanded in `macro_rules!` that should
6865 help to preserve more span information.][73084] These changes may cause
6866 compilation errors if your macro was unhygenic or didn't correctly handle
6867 `Delimiter::None`.
6868- [Moved support for the CloudABI target to tier 3.][75568]
6869- [`linux-gnu` targets now require minimum kernel 2.6.32 and glibc 2.11.][74163]
6870- [Added the `rustc-docs` component.][75560] This allows you to install
6871 and read the documentation for the compiler internal APIs. (Currently only
6872 available for `x86_64-unknown-linux-gnu`.)
6873
6874Internal Only
6875--------
6876
6877- [Improved default settings for bootstrapping in `x.py`.][73964] You can read details about this change in the ["Changes to `x.py` defaults"](https://blog.rust-lang.org/inside-rust/2020/08/30/changes-to-x-py-defaults.html) post on the Inside Rust blog.
6878
6879[1.47.0-cfg]: https://docs.microsoft.com/en-us/windows/win32/secbp/control-flow-guard
6880[75048]: https://github.com/rust-lang/rust/pull/75048/
6881[74163]: https://github.com/rust-lang/rust/pull/74163/
6882[71237]: https://github.com/rust-lang/rust/pull/71237/
6883[74869]: https://github.com/rust-lang/rust/pull/74869/
6884[73858]: https://github.com/rust-lang/rust/pull/73858/
6885[75716]: https://github.com/rust-lang/rust/pull/75716/
6886[75560]: https://github.com/rust-lang/rust/pull/75560/
6887[75568]: https://github.com/rust-lang/rust/pull/75568/
6888[75366]: https://github.com/rust-lang/rust/pull/75366/
6889[75204]: https://github.com/rust-lang/rust/pull/75204/
6890[74650]: https://github.com/rust-lang/rust/pull/74650/
6891[74419]: https://github.com/rust-lang/rust/pull/74419/
6892[73964]: https://github.com/rust-lang/rust/pull/73964/
6893[74021]: https://github.com/rust-lang/rust/pull/74021/
6894[74060]: https://github.com/rust-lang/rust/pull/74060/
6895[73893]: https://github.com/rust-lang/rust/pull/73893/
6896[73526]: https://github.com/rust-lang/rust/pull/73526/
6897[73583]: https://github.com/rust-lang/rust/pull/73583/
6898[73084]: https://github.com/rust-lang/rust/pull/73084/
6899[73197]: https://github.com/rust-lang/rust/pull/73197/
6900[cargo/8456]: https://github.com/rust-lang/cargo/pull/8456/
6901[cargo/8478]: https://github.com/rust-lang/cargo/pull/8478/
6902[cargo/8485]: https://github.com/rust-lang/cargo/pull/8485/
6903[cargo/8500]: https://github.com/rust-lang/cargo/pull/8500/
6904[cargo/8571]: https://github.com/rust-lang/cargo/pull/8571/
6905[`Ident::new_raw`]: https://doc.rust-lang.org/nightly/proc_macro/struct.Ident.html#method.new_raw
6906[`Range::is_empty`]: https://doc.rust-lang.org/nightly/std/ops/struct.Range.html#method.is_empty
6907[`RangeInclusive::is_empty`]: https://doc.rust-lang.org/nightly/std/ops/struct.RangeInclusive.html#method.is_empty
6908[`Result::as_deref_mut`]: https://doc.rust-lang.org/nightly/std/result/enum.Result.html#method.as_deref_mut
6909[`Result::as_deref`]: https://doc.rust-lang.org/nightly/std/result/enum.Result.html#method.as_deref
6910[`Vec::leak`]: https://doc.rust-lang.org/nightly/std/vec/struct.Vec.html#method.leak
6911[`f32::TAU`]: https://doc.rust-lang.org/nightly/std/f32/consts/constant.TAU.html
6912[`f64::TAU`]: https://doc.rust-lang.org/nightly/std/f64/consts/constant.TAU.html
6913[`pointer::offset_from`]: https://doc.rust-lang.org/nightly/std/primitive.pointer.html#method.offset_from
6914
6915
6916Version 1.46.0 (2020-08-27)
6917==========================
6918
6919Language
6920--------
6921- [`if`, `match`, and `loop` expressions can now be used in const functions.][72437]
6922- [Additionally you are now also able to coerce and cast to slices (`&[T]`) in
6923 const functions.][73862]
6924- [The `#[track_caller]` attribute can now be added to functions to use the
6925 function's caller's location information for panic messages.][72445]
6926- [Recursively indexing into tuples no longer needs parentheses.][71322] E.g.
6927 `x.0.0` over `(x.0).0`.
6928- [`mem::transmute` can now be used in statics and constants.][72920] **Note**
6929 You currently can't use `mem::transmute` in constant functions.
6930
6931Compiler
6932--------
6933- [You can now use the `cdylib` target on Apple iOS and tvOS platforms.][73516]
6934- [Enabled static "Position Independent Executables" by default
6935 for `x86_64-unknown-linux-musl`.][70740]
6936
6937Libraries
6938---------
6939- [`mem::forget` is now a `const fn`.][73887]
6940- [`String` now implements `From<char>`.][73466]
6941- [The `leading_ones`, and `trailing_ones` methods have been stabilised for all
6942 integer types.][73032]
6943- [`vec::IntoIter<T>` now implements `AsRef<[T]>`.][72583]
6944- [All non-zero integer types (`NonZeroU8`) now implement `TryFrom` for their
6945 zero-able equivalent (e.g. `TryFrom<u8>`).][72717]
6946- [`&[T]` and `&mut [T]` now implement `PartialEq<Vec<T>>`.][71660]
6947- [`(String, u16)` now implements `ToSocketAddrs`.][73007]
6948- [`vec::Drain<'_, T>` now implements `AsRef<[T]>`.][72584]
6949
6950Stabilized APIs
6951---------------
6952- [`Option::zip`]
6953- [`vec::Drain::as_slice`]
6954
6955Cargo
6956-----
6957Added a number of new environment variables that are now available when
6958compiling your crate.
6959
6960- [`CARGO_BIN_NAME` and `CARGO_CRATE_NAME`][cargo/8270] Providing the name of
6961 the specific binary being compiled and the name of the crate.
6962- [`CARGO_PKG_LICENSE`][cargo/8325] The license from the manifest of the package.
6963- [`CARGO_PKG_LICENSE_FILE`][cargo/8387] The path to the license file.
6964
6965Compatibility Notes
6966-------------------
6967- [The target configuration option `abi_blacklist` has been renamed
6968 to `unsupported_abis`.][74150] The old name will still continue to work.
6969- [Rustc will now warn if you cast a C-like enum that implements `Drop`.][72331]
6970 This was previously accepted but will become a hard error in a future release.
6971- [Rustc will fail to compile if you have a struct with
6972 `#[repr(i128)]` or `#[repr(u128)]`.][74109] This representation is currently only
6973 allowed on `enum`s.
6974- [Tokens passed to `macro_rules!` are now always captured.][73293] This helps
6975 ensure that spans have the correct information, and may cause breakage if you
6976 were relying on receiving spans with dummy information.
6977- [The InnoSetup installer for Windows is no longer available.][72569] This was
6978 a legacy installer that was replaced by a MSI installer a few years ago but
6979 was still being built.
6980- [`{f32, f64}::asinh` now returns the correct values for negative numbers.][72486]
6981- [Rustc will no longer accept overlapping trait implementations that only
6982 differ in how the lifetime was bound.][72493]
6983- [Rustc now correctly relates the lifetime of an existential associated
6984 type.][71896] This fixes some edge cases where `rustc` would erroneously allow
6985 you to pass a shorter lifetime than expected.
6986- [Rustc now dynamically links to `libz` (also called `zlib`) on Linux.][74420]
6987 The library will need to be installed for `rustc` to work, even though we
6988 expect it to be already available on most systems.
6989- [Tests annotated with `#[should_panic]` are broken on ARMv7 while running
6990 under QEMU.][74820]
6991- [Pretty printing of some tokens in procedural macros changed.][75453] The
6992 exact output returned by rustc's pretty printing is an unstable
6993 implementation detail: we recommend any macro relying on it to switch to a
6994 more robust parsing system.
6995
6996[75453]: https://github.com/rust-lang/rust/issues/75453/
6997[74820]: https://github.com/rust-lang/rust/issues/74820/
6998[74420]: https://github.com/rust-lang/rust/issues/74420/
6999[74109]: https://github.com/rust-lang/rust/pull/74109/
7000[74150]: https://github.com/rust-lang/rust/pull/74150/
7001[73862]: https://github.com/rust-lang/rust/pull/73862/
7002[73887]: https://github.com/rust-lang/rust/pull/73887/
7003[73466]: https://github.com/rust-lang/rust/pull/73466/
7004[73516]: https://github.com/rust-lang/rust/pull/73516/
7005[73293]: https://github.com/rust-lang/rust/pull/73293/
7006[73007]: https://github.com/rust-lang/rust/pull/73007/
7007[73032]: https://github.com/rust-lang/rust/pull/73032/
7008[72920]: https://github.com/rust-lang/rust/pull/72920/
7009[72569]: https://github.com/rust-lang/rust/pull/72569/
7010[72583]: https://github.com/rust-lang/rust/pull/72583/
7011[72584]: https://github.com/rust-lang/rust/pull/72584/
7012[72717]: https://github.com/rust-lang/rust/pull/72717/
7013[72437]: https://github.com/rust-lang/rust/pull/72437/
7014[72445]: https://github.com/rust-lang/rust/pull/72445/
7015[72486]: https://github.com/rust-lang/rust/pull/72486/
7016[72493]: https://github.com/rust-lang/rust/pull/72493/
7017[72331]: https://github.com/rust-lang/rust/pull/72331/
7018[71896]: https://github.com/rust-lang/rust/pull/71896/
7019[71660]: https://github.com/rust-lang/rust/pull/71660/
7020[71322]: https://github.com/rust-lang/rust/pull/71322/
7021[70740]: https://github.com/rust-lang/rust/pull/70740/
7022[cargo/8270]: https://github.com/rust-lang/cargo/pull/8270/
7023[cargo/8325]: https://github.com/rust-lang/cargo/pull/8325/
7024[cargo/8387]: https://github.com/rust-lang/cargo/pull/8387/
7025[`Option::zip`]: https://doc.rust-lang.org/stable/std/option/enum.Option.html#method.zip
7026[`vec::Drain::as_slice`]: https://doc.rust-lang.org/stable/std/vec/struct.Drain.html#method.as_slice
7027
7028
7029Version 1.45.2 (2020-08-03)
7030==========================
7031
7032* [Fix bindings in tuple struct patterns][74954]
7033* [Fix track_caller integration with trait objects][74784]
7034
7035[74954]: https://github.com/rust-lang/rust/issues/74954
7036[74784]: https://github.com/rust-lang/rust/issues/74784
7037
7038
7039Version 1.45.1 (2020-07-30)
7040==========================
7041
7042* [Fix const propagation with references.][73613]
7043* [rustfmt accepts rustfmt_skip in cfg_attr again.][73078]
7044* [Avoid spurious implicit region bound.][74509]
7045* [Install clippy on x.py install][74457]
7046
7047[73613]: https://github.com/rust-lang/rust/pull/73613
7048[73078]: https://github.com/rust-lang/rust/issues/73078
7049[74509]: https://github.com/rust-lang/rust/pull/74509
7050[74457]: https://github.com/rust-lang/rust/pull/74457
7051
7052
7053Version 1.45.0 (2020-07-16)
7054==========================
7055
7056Language
7057--------
7058- [Out of range float to int conversions using `as` has been defined as a saturating
7059 conversion.][71269] This was previously undefined behaviour, but you can use the
7060 `{f64, f32}::to_int_unchecked` methods to continue using the current behaviour, which
7061 may be desirable in rare performance sensitive situations.
7062- [`mem::Discriminant<T>` now uses `T`'s discriminant type instead of always
7063 using `u64`.][70705]
7064- [Function like procedural macros can now be used in expression, pattern, and statement
7065 positions.][68717] This means you can now use a function-like procedural macro
7066 anywhere you can use a declarative (`macro_rules!`) macro.
7067
7068Compiler
7069--------
7070- [You can now override individual target features through the `target-feature`
7071 flag.][72094] E.g. `-C target-feature=+avx2 -C target-feature=+fma` is now
7072 equivalent to `-C target-feature=+avx2,+fma`.
7073- [Added the `force-unwind-tables` flag.][69984] This option allows
7074 rustc to always generate unwind tables regardless of panic strategy.
7075- [Added the `embed-bitcode` flag.][71716] This codegen flag allows rustc
7076 to include LLVM bitcode into generated `rlib`s (this is on by default).
7077- [Added the `tiny` value to the `code-model` codegen flag.][72397]
7078- [Added tier 3 support\* for the `mipsel-sony-psp` target.][72062]
7079- [Added tier 3 support for the `thumbv7a-uwp-windows-msvc` target.][72133]
7080- [Upgraded to LLVM 10.][67759]
7081
7082\* Refer to Rust's [platform support page][platform-support-doc] for more
7083information on Rust's tiered platform support.
7084
7085
7086Libraries
7087---------
7088- [`net::{SocketAddr, SocketAddrV4, SocketAddrV6}` now implements `PartialOrd`
7089 and `Ord`.][72239]
7090- [`proc_macro::TokenStream` now implements `Default`.][72234]
7091- [You can now use `char` with
7092 `ops::{Range, RangeFrom, RangeFull, RangeInclusive, RangeTo}` to iterate over
7093 a range of codepoints.][72413] E.g.
7094 you can now write the following;
7095 ```rust
7096 for ch in 'a'..='z' {
7097 print!("{}", ch);
7098 }
7099 println!();
7100 // Prints "abcdefghijklmnopqrstuvwxyz"
7101 ```
7102- [`OsString` now implements `FromStr`.][71662]
7103- [The `saturating_neg` method has been added to all signed integer primitive
7104 types, and the `saturating_abs` method has been added for all integer
7105 primitive types.][71886]
7106- [`Arc<T>`, `Rc<T>` now implement `From<Cow<'_, T>>`, and `Box` now
7107 implements `From<Cow>` when `T` is `[T: Copy]`, `str`, `CStr`, `OsStr`,
7108 or `Path`.][71447]
7109- [`Box<[T]>` now implements `From<[T; N]>`.][71095]
7110- [`BitOr` and `BitOrAssign` are implemented for all `NonZero`
7111 integer types.][69813]
7112- [The `fetch_min`, and `fetch_max` methods have been added to all atomic
7113 integer types.][72324]
7114- [The `fetch_update` method has been added to all atomic integer types.][71843]
7115
7116Stabilized APIs
7117---------------
7118- [`Arc::as_ptr`]
7119- [`BTreeMap::remove_entry`]
7120- [`Rc::as_ptr`]
7121- [`rc::Weak::as_ptr`]
7122- [`rc::Weak::from_raw`]
7123- [`rc::Weak::into_raw`]
7124- [`str::strip_prefix`]
7125- [`str::strip_suffix`]
7126- [`sync::Weak::as_ptr`]
7127- [`sync::Weak::from_raw`]
7128- [`sync::Weak::into_raw`]
7129- [`char::UNICODE_VERSION`]
7130- [`Span::resolved_at`]
7131- [`Span::located_at`]
7132- [`Span::mixed_site`]
7133- [`unix::process::CommandExt::arg0`]
7134
7135Cargo
7136-----
7137
7138- [Cargo uses the `embed-bitcode` flag to optimize disk usage and build
7139 time.][cargo/8066]
7140
7141Misc
7142----
7143- [Rustdoc now supports strikethrough text in Markdown.][71928] E.g.
7144 `~~outdated information~~` becomes "~~outdated information~~".
7145- [Added an emoji to Rustdoc's deprecated API message.][72014]
7146
7147Compatibility Notes
7148-------------------
7149- [Trying to self initialize a static value (that is creating a value using
7150 itself) is unsound and now causes a compile error.][71140]
7151- [`{f32, f64}::powi` now returns a slightly different value on Windows.][73420]
7152 This is due to changes in LLVM's intrinsics which `{f32, f64}::powi` uses.
7153- [Rustdoc's CLI's extra error exit codes have been removed.][71900] These were
7154 previously undocumented and not intended for public use. Rustdoc still provides
7155 a non-zero exit code on errors.
7156- [Rustc's `lto` flag is incompatible with the new `embed-bitcode=no`.][71848]
7157 This may cause issues if LTO is enabled through `RUSTFLAGS` or `cargo rustc`
7158 flags while cargo is adding `embed-bitcode` itself. The recommended way to
7159 control LTO is with Cargo profiles, either in `Cargo.toml` or `.cargo/config`,
7160 or by setting `CARGO_PROFILE_<name>_LTO` in the environment.
7161
7162Internals Only
7163--------------
7164- [Make clippy a git subtree instead of a git submodule][70655]
7165- [Unify the undo log of all snapshot types][69464]
7166
7167[71848]: https://github.com/rust-lang/rust/issues/71848/
7168[73420]: https://github.com/rust-lang/rust/issues/73420/
7169[72324]: https://github.com/rust-lang/rust/pull/72324/
7170[71843]: https://github.com/rust-lang/rust/pull/71843/
7171[71886]: https://github.com/rust-lang/rust/pull/71886/
7172[72234]: https://github.com/rust-lang/rust/pull/72234/
7173[72239]: https://github.com/rust-lang/rust/pull/72239/
7174[72397]: https://github.com/rust-lang/rust/pull/72397/
7175[72413]: https://github.com/rust-lang/rust/pull/72413/
7176[72014]: https://github.com/rust-lang/rust/pull/72014/
7177[72062]: https://github.com/rust-lang/rust/pull/72062/
7178[72094]: https://github.com/rust-lang/rust/pull/72094/
7179[72133]: https://github.com/rust-lang/rust/pull/72133/
7180[67759]: https://github.com/rust-lang/rust/pull/67759/
7181[71900]: https://github.com/rust-lang/rust/pull/71900/
7182[71928]: https://github.com/rust-lang/rust/pull/71928/
7183[71662]: https://github.com/rust-lang/rust/pull/71662/
7184[71716]: https://github.com/rust-lang/rust/pull/71716/
7185[71447]: https://github.com/rust-lang/rust/pull/71447/
7186[71269]: https://github.com/rust-lang/rust/pull/71269/
7187[71095]: https://github.com/rust-lang/rust/pull/71095/
7188[71140]: https://github.com/rust-lang/rust/pull/71140/
7189[70655]: https://github.com/rust-lang/rust/pull/70655/
7190[70705]: https://github.com/rust-lang/rust/pull/70705/
7191[69984]: https://github.com/rust-lang/rust/pull/69984/
7192[69813]: https://github.com/rust-lang/rust/pull/69813/
7193[69464]: https://github.com/rust-lang/rust/pull/69464/
7194[68717]: https://github.com/rust-lang/rust/pull/68717/
7195[cargo/8066]: https://github.com/rust-lang/cargo/pull/8066
7196[`Arc::as_ptr`]: https://doc.rust-lang.org/stable/std/sync/struct.Arc.html#method.as_ptr
7197[`BTreeMap::remove_entry`]: https://doc.rust-lang.org/stable/std/collections/struct.BTreeMap.html#method.remove_entry
7198[`Rc::as_ptr`]: https://doc.rust-lang.org/stable/std/rc/struct.Rc.html#method.as_ptr
7199[`rc::Weak::as_ptr`]: https://doc.rust-lang.org/stable/std/rc/struct.Weak.html#method.as_ptr
7200[`rc::Weak::from_raw`]: https://doc.rust-lang.org/stable/std/rc/struct.Weak.html#method.from_raw
7201[`rc::Weak::into_raw`]: https://doc.rust-lang.org/stable/std/rc/struct.Weak.html#method.into_raw
7202[`sync::Weak::as_ptr`]: https://doc.rust-lang.org/stable/std/sync/struct.Weak.html#method.as_ptr
7203[`sync::Weak::from_raw`]: https://doc.rust-lang.org/stable/std/sync/struct.Weak.html#method.from_raw
7204[`sync::Weak::into_raw`]: https://doc.rust-lang.org/stable/std/sync/struct.Weak.html#method.into_raw
7205[`str::strip_prefix`]: https://doc.rust-lang.org/stable/std/primitive.str.html#method.strip_prefix
7206[`str::strip_suffix`]: https://doc.rust-lang.org/stable/std/primitive.str.html#method.strip_suffix
7207[`char::UNICODE_VERSION`]: https://doc.rust-lang.org/stable/std/char/constant.UNICODE_VERSION.html
7208[`Span::resolved_at`]: https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.resolved_at
7209[`Span::located_at`]: https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.located_at
7210[`Span::mixed_site`]: https://doc.rust-lang.org/stable/proc_macro/struct.Span.html#method.mixed_site
7211[`unix::process::CommandExt::arg0`]: https://doc.rust-lang.org/std/os/unix/process/trait.CommandExt.html#tymethod.arg0
7212
7213
7214Version 1.44.1 (2020-06-18)
7215===========================
7216
7217* [rustfmt accepts rustfmt_skip in cfg_attr again.][73078]
7218* [Don't hash executable filenames on apple platforms, fixing backtraces.][cargo/8329]
7219* [Fix crashes when finding backtrace on macOS.][71397]
7220* [Clippy applies lint levels into different files.][clippy/5356]
7221
7222[71397]: https://github.com/rust-lang/rust/issues/71397
7223[73078]: https://github.com/rust-lang/rust/issues/73078
7224[cargo/8329]: https://github.com/rust-lang/cargo/pull/8329
7225[clippy/5356]: https://github.com/rust-lang/rust-clippy/issues/5356
7226
7227
7228Version 1.44.0 (2020-06-04)
7229==========================
7230
7231Language
7232--------
7233- [You can now use `async/.await` with `#[no_std]` enabled.][69033]
7234- [Added the `unused_braces` lint.][70081]
7235
7236**Syntax-only changes**
7237
7238- [Expansion-driven outline module parsing][69838]
7239```rust
7240#[cfg(FALSE)]
7241mod foo {
7242 mod bar {
7243 mod baz; // `foo/bar/baz.rs` doesn't exist, but no error!
7244 }
7245}
7246```
7247
7248These are still rejected semantically, so you will likely receive an error but
7249these changes can be seen and parsed by macros and conditional compilation.
7250
7251Compiler
7252--------
7253- [Rustc now respects the `-C codegen-units` flag in incremental mode.][70156]
7254 Additionally when in incremental mode rustc defaults to 256 codegen units.
7255- [Refactored `catch_unwind` to have zero-cost, unless unwinding is enabled and
7256 a panic is thrown.][67502]
7257- [Added tier 3\* support for the `aarch64-unknown-none` and
7258 `aarch64-unknown-none-softfloat` targets.][68334]
7259- [Added tier 3 support for `arm64-apple-tvos` and
7260 `x86_64-apple-tvos` targets.][68191]
7261
7262
7263Libraries
7264---------
7265- [Special cased `vec![]` to map directly to `Vec::new()`.][70632] This allows
7266 `vec![]` to be able to be used in `const` contexts.
7267- [`convert::Infallible` now implements `Hash`.][70281]
7268- [`OsString` now implements `DerefMut` and `IndexMut` returning
7269 a `&mut OsStr`.][70048]
7270- [Unicode 13 is now supported.][69929]
7271- [`String` now implements `From<&mut str>`.][69661]
7272- [`IoSlice` now implements `Copy`.][69403]
7273- [`Vec<T>` now implements `From<[T; N]>`.][68692] Where `N` is at most 32.
7274- [`proc_macro::LexError` now implements `fmt::Display` and `Error`.][68899]
7275- [`from_le_bytes`, `to_le_bytes`, `from_be_bytes`, `to_be_bytes`,
7276 `from_ne_bytes`, and `to_ne_bytes` methods are now `const` for all
7277 integer types.][69373]
7278
7279Stabilized APIs
7280---------------
7281- [`PathBuf::with_capacity`]
7282- [`PathBuf::capacity`]
7283- [`PathBuf::clear`]
7284- [`PathBuf::reserve`]
7285- [`PathBuf::reserve_exact`]
7286- [`PathBuf::shrink_to_fit`]
7287- [`f32::to_int_unchecked`]
7288- [`f64::to_int_unchecked`]
7289- [`Layout::align_to`]
7290- [`Layout::pad_to_align`]
7291- [`Layout::array`]
7292- [`Layout::extend`]
7293
7294Cargo
7295-----
7296- [Added the `cargo tree` command which will print a tree graph of
7297 your dependencies.][cargo/8062] E.g.
7298 ```
7299 mdbook v0.3.2 (/Users/src/rust/mdbook)
7300 ├── ammonia v3.0.0
7301 │ ├── html5ever v0.24.0
7302 │ │ ├── log v0.4.8
7303 │ │ │ └── cfg-if v0.1.9
7304 │ │ ├── mac v0.1.1
7305 │ │ └── markup5ever v0.9.0
7306 │ │ ├── log v0.4.8 (*)
7307 │ │ ├── phf v0.7.24
7308 │ │ │ └── phf_shared v0.7.24
7309 │ │ │ ├── siphasher v0.2.3
7310 │ │ │ └── unicase v1.4.2
7311 │ │ │ [build-dependencies]
7312 │ │ │ └── version_check v0.1.5
7313 ...
7314 ```
7315 You can also display dependencies on multiple versions of the same crate with
7316 `cargo tree -d` (short for `cargo tree --duplicates`).
7317
7318Misc
7319----
7320- [Rustdoc now allows you to specify `--crate-version` to have rustdoc include
7321 the version in the sidebar.][69494]
7322
7323Compatibility Notes
7324-------------------
7325- [Rustc now correctly generates static libraries on Windows GNU targets with
7326 the `.a` extension, rather than the previous `.lib`.][70937]
7327- [Removed the `-C no_integrated_as` flag from rustc.][70345]
7328- [The `file_name` property in JSON output of macro errors now points the actual
7329 source file rather than the previous format of `<NAME macros>`.][70969]
7330 **Note:** this may not point to a file that actually exists on the user's system.
7331- [The minimum required external LLVM version has been bumped to LLVM 8.][71147]
7332- [`mem::{zeroed, uninitialised}` will now panic when used with types that do
7333 not allow zero initialization such as `NonZeroU8`.][66059] This was
7334 previously a warning.
7335- [In 1.45.0 (the next release) converting a `f64` to `u32` using the `as`
7336 operator has been defined as a saturating operation.][71269] This was previously
7337 undefined behaviour, but you can use the `{f64, f32}::to_int_unchecked` methods to
7338 continue using the current behaviour, which may be desirable in rare performance
7339 sensitive situations.
7340
7341Internal Only
7342-------------
7343These changes provide no direct user facing benefits, but represent significant
7344improvements to the internals and overall performance of rustc and
7345related tools.
7346
7347- [dep_graph Avoid allocating a set on when the number reads are small.][69778]
7348- [Replace big JS dict with JSON parsing.][71250]
7349
7350[69373]: https://github.com/rust-lang/rust/pull/69373/
7351[66059]: https://github.com/rust-lang/rust/pull/66059/
7352[68191]: https://github.com/rust-lang/rust/pull/68191/
7353[68899]: https://github.com/rust-lang/rust/pull/68899/
7354[71147]: https://github.com/rust-lang/rust/pull/71147/
7355[71250]: https://github.com/rust-lang/rust/pull/71250/
7356[70937]: https://github.com/rust-lang/rust/pull/70937/
7357[70969]: https://github.com/rust-lang/rust/pull/70969/
7358[70632]: https://github.com/rust-lang/rust/pull/70632/
7359[70281]: https://github.com/rust-lang/rust/pull/70281/
7360[70345]: https://github.com/rust-lang/rust/pull/70345/
7361[70048]: https://github.com/rust-lang/rust/pull/70048/
7362[70081]: https://github.com/rust-lang/rust/pull/70081/
7363[70156]: https://github.com/rust-lang/rust/pull/70156/
7364[71269]: https://github.com/rust-lang/rust/pull/71269/
7365[69838]: https://github.com/rust-lang/rust/pull/69838/
7366[69929]: https://github.com/rust-lang/rust/pull/69929/
7367[69661]: https://github.com/rust-lang/rust/pull/69661/
7368[69778]: https://github.com/rust-lang/rust/pull/69778/
7369[69494]: https://github.com/rust-lang/rust/pull/69494/
7370[69403]: https://github.com/rust-lang/rust/pull/69403/
7371[69033]: https://github.com/rust-lang/rust/pull/69033/
7372[68692]: https://github.com/rust-lang/rust/pull/68692/
7373[68334]: https://github.com/rust-lang/rust/pull/68334/
7374[67502]: https://github.com/rust-lang/rust/pull/67502/
7375[cargo/8062]: https://github.com/rust-lang/cargo/pull/8062/
7376[`PathBuf::with_capacity`]: https://doc.rust-lang.org/std/path/struct.PathBuf.html#method.with_capacity
7377[`PathBuf::capacity`]: https://doc.rust-lang.org/std/path/struct.PathBuf.html#method.capacity
7378[`PathBuf::clear`]: https://doc.rust-lang.org/std/path/struct.PathBuf.html#method.clear
7379[`PathBuf::reserve`]: https://doc.rust-lang.org/std/path/struct.PathBuf.html#method.reserve
7380[`PathBuf::reserve_exact`]: https://doc.rust-lang.org/std/path/struct.PathBuf.html#method.reserve_exact
7381[`PathBuf::shrink_to_fit`]: https://doc.rust-lang.org/std/path/struct.PathBuf.html#method.shrink_to_fit
7382[`f32::to_int_unchecked`]: https://doc.rust-lang.org/std/primitive.f32.html#method.to_int_unchecked
7383[`f64::to_int_unchecked`]: https://doc.rust-lang.org/std/primitive.f64.html#method.to_int_unchecked
7384[`Layout::align_to`]: https://doc.rust-lang.org/std/alloc/struct.Layout.html#method.align_to
7385[`Layout::pad_to_align`]: https://doc.rust-lang.org/std/alloc/struct.Layout.html#method.pad_to_align
7386[`Layout::array`]: https://doc.rust-lang.org/std/alloc/struct.Layout.html#method.array
7387[`Layout::extend`]: https://doc.rust-lang.org/std/alloc/struct.Layout.html#method.extend
7388
7389
7390Version 1.43.1 (2020-05-07)
7391===========================
7392
7393* [Updated openssl-src to 1.1.1g for CVE-2020-1967.][71430]
7394* [Fixed the stabilization of AVX-512 features.][71473]
7395* [Fixed `cargo package --list` not working with unpublished dependencies.][cargo/8151]
7396
7397[71430]: https://github.com/rust-lang/rust/pull/71430
7398[71473]: https://github.com/rust-lang/rust/issues/71473
7399[cargo/8151]: https://github.com/rust-lang/cargo/issues/8151
7400
7401
7402Version 1.43.0 (2020-04-23)
7403==========================
7404
7405Language
7406--------
7407- [Fixed using binary operations with `&{number}` (e.g. `&1.0`) not having
7408 the type inferred correctly.][68129]
7409- [Attributes such as `#[cfg()]` can now be used on `if` expressions.][69201]
7410
7411**Syntax only changes**
7412- [Allow `type Foo: Ord` syntactically.][69361]
7413- [Fuse associated and extern items up to defaultness.][69194]
7414- [Syntactically allow `self` in all `fn` contexts.][68764]
7415- [Merge `fn` syntax + cleanup item parsing.][68728]
7416- [`item` macro fragments can be interpolated into `trait`s, `impl`s, and `extern` blocks.][69366]
7417 For example, you may now write:
7418 ```rust
7419 macro_rules! mac_trait {
7420 ($i:item) => {
7421 trait T { $i }
7422 }
7423 }
7424 mac_trait! {
7425 fn foo() {}
7426 }
7427 ```
7428
7429These are still rejected *semantically*, so you will likely receive an error but
7430these changes can be seen and parsed by macros and
7431conditional compilation.
7432
7433
7434Compiler
7435--------
7436- [You can now pass multiple lint flags to rustc to override the previous
7437 flags.][67885] For example; `rustc -D unused -A unused-variables` denies
7438 everything in the `unused` lint group except `unused-variables` which
7439 is explicitly allowed. However, passing `rustc -A unused-variables -D unused` denies
7440 everything in the `unused` lint group **including** `unused-variables` since
7441 the allow flag is specified before the deny flag (and therefore overridden).
7442- [rustc will now prefer your system MinGW libraries over its bundled libraries
7443 if they are available on `windows-gnu`.][67429]
7444- [rustc now buffers errors/warnings printed in JSON.][69227]
7445
7446Libraries
7447---------
7448- [`Arc<[T; N]>`, `Box<[T; N]>`, and `Rc<[T; N]>`, now implement
7449 `TryFrom<Arc<[T]>>`,`TryFrom<Box<[T]>>`, and `TryFrom<Rc<[T]>>`
7450 respectively.][69538] **Note** These conversions are only available when `N`
7451 is `0..=32`.
7452- [You can now use associated constants on floats and integers directly, rather
7453 than having to import the module.][68952] e.g. You can now write `u32::MAX` or
7454 `f32::NAN` with no imports.
7455- [`u8::is_ascii` is now `const`.][68984]
7456- [`String` now implements `AsMut<str>`.][68742]
7457- [Added the `primitive` module to `std` and `core`.][67637] This module
7458 reexports Rust's primitive types. This is mainly useful in macros
7459 where you want avoid these types being shadowed.
7460- [Relaxed some of the trait bounds on `HashMap` and `HashSet`.][67642]
7461- [`string::FromUtf8Error` now implements `Clone + Eq`.][68738]
7462
7463Stabilized APIs
7464---------------
7465- [`Once::is_completed`]
7466- [`f32::LOG10_2`]
7467- [`f32::LOG2_10`]
7468- [`f64::LOG10_2`]
7469- [`f64::LOG2_10`]
7470- [`iter::once_with`]
7471
7472Cargo
7473-----
7474- [You can now set config `[profile]`s in your `.cargo/config`, or through
7475 your environment.][cargo/7823]
7476- [Cargo will now set `CARGO_BIN_EXE_<name>` pointing to a binary's
7477 executable path when running integration tests or benchmarks.][cargo/7697]
7478 `<name>` is the name of your binary as-is e.g. If you wanted the executable
7479 path for a binary named `my-program`you would use `env!("CARGO_BIN_EXE_my-program")`.
7480
7481Misc
7482----
7483- [Certain checks in the `const_err` lint were deemed unrelated to const
7484 evaluation][69185], and have been moved to the `unconditional_panic` and
7485 `arithmetic_overflow` lints.
7486
7487Compatibility Notes
7488-------------------
7489
7490- [Having trailing syntax in the `assert!` macro is now a hard error.][69548] This
7491 has been a warning since 1.36.0.
7492- [Fixed `Self` not having the correctly inferred type.][69340] This incorrectly
7493 led to some instances being accepted, and now correctly emits a hard error.
7494
7495[69340]: https://github.com/rust-lang/rust/pull/69340
7496
7497Internal Only
7498-------------
7499These changes provide no direct user facing benefits, but represent significant
7500improvements to the internals and overall performance of `rustc` and
7501related tools.
7502
7503- [All components are now built with `opt-level=3` instead of `2`.][67878]
7504- [Improved how rustc generates drop code.][67332]
7505- [Improved performance from `#[inline]`-ing certain hot functions.][69256]
7506- [traits: preallocate 2 Vecs of known initial size][69022]
7507- [Avoid exponential behaviour when relating types][68772]
7508- [Skip `Drop` terminators for enum variants without drop glue][68943]
7509- [Improve performance of coherence checks][68966]
7510- [Deduplicate types in the generator witness][68672]
7511- [Invert control in struct_lint_level.][68725]
7512
7513[67332]: https://github.com/rust-lang/rust/pull/67332/
7514[67429]: https://github.com/rust-lang/rust/pull/67429/
7515[67637]: https://github.com/rust-lang/rust/pull/67637/
7516[67642]: https://github.com/rust-lang/rust/pull/67642/
7517[67878]: https://github.com/rust-lang/rust/pull/67878/
7518[67885]: https://github.com/rust-lang/rust/pull/67885/
7519[68129]: https://github.com/rust-lang/rust/pull/68129/
7520[68672]: https://github.com/rust-lang/rust/pull/68672/
7521[68725]: https://github.com/rust-lang/rust/pull/68725/
7522[68728]: https://github.com/rust-lang/rust/pull/68728/
7523[68738]: https://github.com/rust-lang/rust/pull/68738/
7524[68742]: https://github.com/rust-lang/rust/pull/68742/
7525[68764]: https://github.com/rust-lang/rust/pull/68764/
7526[68772]: https://github.com/rust-lang/rust/pull/68772/
7527[68943]: https://github.com/rust-lang/rust/pull/68943/
7528[68952]: https://github.com/rust-lang/rust/pull/68952/
7529[68966]: https://github.com/rust-lang/rust/pull/68966/
7530[68984]: https://github.com/rust-lang/rust/pull/68984/
7531[69022]: https://github.com/rust-lang/rust/pull/69022/
7532[69185]: https://github.com/rust-lang/rust/pull/69185/
7533[69194]: https://github.com/rust-lang/rust/pull/69194/
7534[69201]: https://github.com/rust-lang/rust/pull/69201/
7535[69227]: https://github.com/rust-lang/rust/pull/69227/
7536[69548]: https://github.com/rust-lang/rust/pull/69548/
7537[69256]: https://github.com/rust-lang/rust/pull/69256/
7538[69361]: https://github.com/rust-lang/rust/pull/69361/
7539[69366]: https://github.com/rust-lang/rust/pull/69366/
7540[69538]: https://github.com/rust-lang/rust/pull/69538/
7541[cargo/7823]: https://github.com/rust-lang/cargo/pull/7823
7542[cargo/7697]: https://github.com/rust-lang/cargo/pull/7697
7543[`Once::is_completed`]: https://doc.rust-lang.org/std/sync/struct.Once.html#method.is_completed
7544[`f32::LOG10_2`]: https://doc.rust-lang.org/std/f32/consts/constant.LOG10_2.html
7545[`f32::LOG2_10`]: https://doc.rust-lang.org/std/f32/consts/constant.LOG2_10.html
7546[`f64::LOG10_2`]: https://doc.rust-lang.org/std/f64/consts/constant.LOG10_2.html
7547[`f64::LOG2_10`]: https://doc.rust-lang.org/std/f64/consts/constant.LOG2_10.html
7548[`iter::once_with`]: https://doc.rust-lang.org/std/iter/fn.once_with.html
7549
7550
7551Version 1.42.0 (2020-03-12)
7552==========================
7553
7554Language
7555--------
7556- [You can now use the slice pattern syntax with subslices.][67712] e.g.
7557 ```rust
7558 fn foo(words: &[&str]) {
7559 match words {
7560 ["Hello", "World", "!", ..] => println!("Hello World!"),
7561 ["Foo", "Bar", ..] => println!("Baz"),
7562 rest => println!("{:?}", rest),
7563 }
7564 }
7565 ```
7566- [You can now use `#[repr(transparent)]` on univariant `enum`s.][68122] Meaning
7567 that you can create an enum that has the exact layout and ABI of the type
7568 it contains.
7569- [You can now use outer attribute procedural macros on inline modules.][64273]
7570- [There are some *syntax-only* changes:][67131]
7571 - `default` is syntactically allowed before items in `trait` definitions.
7572 - Items in `impl`s (i.e. `const`s, `type`s, and `fn`s) may syntactically
7573 leave out their bodies in favor of `;`.
7574 - Bounds on associated types in `impl`s are now syntactically allowed
7575 (e.g. `type Foo: Ord;`).
7576 - `...` (the C-variadic type) may occur syntactically directly as the type of
7577 any function parameter.
7578
7579 These are still rejected *semantically*, so you will likely receive an error
7580 but these changes can be seen and parsed by procedural macros and
7581 conditional compilation.
7582
7583Compiler
7584--------
7585- [Added tier 2\* support for `armv7a-none-eabi`.][68253]
7586- [Added tier 2 support for `riscv64gc-unknown-linux-gnu`.][68339]
7587- [`Option::{expect,unwrap}` and
7588 `Result::{expect, expect_err, unwrap, unwrap_err}` now produce panic messages
7589 pointing to the location where they were called, rather than
7590 `core`'s internals. ][67887]
7591
7592\* Refer to Rust's [platform support page][platform-support-doc] for more
7593information on Rust's tiered platform support.
7594
7595Libraries
7596---------
7597- [`iter::Empty<T>` now implements `Send` and `Sync` for any `T`.][68348]
7598- [`Pin::{map_unchecked, map_unchecked_mut}` no longer require the return type
7599 to implement `Sized`.][67935]
7600- [`io::Cursor` now derives `PartialEq` and `Eq`.][67233]
7601- [`Layout::new` is now `const`.][66254]
7602- [Added Standard Library support for `riscv64gc-unknown-linux-gnu`.][66899]
7603
7604
7605Stabilized APIs
7606---------------
7607- [`CondVar::wait_while`]
7608- [`CondVar::wait_timeout_while`]
7609- [`DebugMap::key`]
7610- [`DebugMap::value`]
7611- [`ManuallyDrop::take`]
7612- [`matches!`]
7613- [`ptr::slice_from_raw_parts_mut`]
7614- [`ptr::slice_from_raw_parts`]
7615
7616Cargo
7617-----
7618- [You no longer need to include `extern crate proc_macro;` to be able to
7619 `use proc_macro;` in the `2018` edition.][cargo/7700]
7620
7621Compatibility Notes
7622-------------------
7623- [`Error::description` has been deprecated, and its use will now produce a
7624 warning.][66919] It's recommended to use `Display`/`to_string` instead.
7625
7626[68253]: https://github.com/rust-lang/rust/pull/68253/
7627[68348]: https://github.com/rust-lang/rust/pull/68348/
7628[67935]: https://github.com/rust-lang/rust/pull/67935/
7629[68339]: https://github.com/rust-lang/rust/pull/68339/
7630[68122]: https://github.com/rust-lang/rust/pull/68122/
7631[64273]: https://github.com/rust-lang/rust/pull/64273/
7632[67712]: https://github.com/rust-lang/rust/pull/67712/
7633[67887]: https://github.com/rust-lang/rust/pull/67887/
7634[67131]: https://github.com/rust-lang/rust/pull/67131/
7635[67233]: https://github.com/rust-lang/rust/pull/67233/
7636[66899]: https://github.com/rust-lang/rust/pull/66899/
7637[66919]: https://github.com/rust-lang/rust/pull/66919/
7638[66254]: https://github.com/rust-lang/rust/pull/66254/
7639[cargo/7700]: https://github.com/rust-lang/cargo/pull/7700
7640[`DebugMap::key`]: https://doc.rust-lang.org/stable/std/fmt/struct.DebugMap.html#method.key
7641[`DebugMap::value`]: https://doc.rust-lang.org/stable/std/fmt/struct.DebugMap.html#method.value
7642[`ManuallyDrop::take`]: https://doc.rust-lang.org/stable/std/mem/struct.ManuallyDrop.html#method.take
7643[`matches!`]: https://doc.rust-lang.org/stable/std/macro.matches.html
7644[`ptr::slice_from_raw_parts_mut`]: https://doc.rust-lang.org/stable/std/ptr/fn.slice_from_raw_parts_mut.html
7645[`ptr::slice_from_raw_parts`]: https://doc.rust-lang.org/stable/std/ptr/fn.slice_from_raw_parts.html
7646[`CondVar::wait_while`]: https://doc.rust-lang.org/stable/std/sync/struct.Condvar.html#method.wait_while
7647[`CondVar::wait_timeout_while`]: https://doc.rust-lang.org/stable/std/sync/struct.Condvar.html#method.wait_timeout_while
7648
7649
7650Version 1.41.1 (2020-02-27)
7651===========================
7652
7653* [Always check types of static items][69145]
7654* [Always check lifetime bounds of `Copy` impls][69145]
7655* [Fix miscompilation in callers of `Layout::repeat`][69225]
7656* [Rust 1.41.0 was announced as the last Rust release with tier 1 or tier 2 support for 32-bit Apple targets][apple-32bit-drop].
7657 That announcement did not expect a patch release. 1.41.1 also includes release binaries for these targets.
7658
7659[69225]: https://github.com/rust-lang/rust/issues/69225
7660[69145]: https://github.com/rust-lang/rust/pull/69145
7661
7662
7663Version 1.41.0 (2020-01-30)
7664===========================
7665
7666Language
7667--------
7668
7669- [You can now pass type parameters to foreign items when implementing
7670 traits.][65879] E.g. You can now write `impl<T> From<Foo> for Vec<T> {}`.
7671- [You can now arbitrarily nest receiver types in the `self` position.][64325] E.g. you can
7672 now write `fn foo(self: Box<Box<Self>>) {}`. Previously only `Self`, `&Self`,
7673 `&mut Self`, `Arc<Self>`, `Rc<Self>`, and `Box<Self>` were allowed.
7674- [You can now use any valid identifier in a `format_args` macro.][66847]
7675 Previously identifiers starting with an underscore were not allowed.
7676- [Visibility modifiers (e.g. `pub`) are now syntactically allowed on trait items and
7677 enum variants.][66183] These are still rejected semantically, but
7678 can be seen and parsed by procedural macros and conditional compilation.
7679- [You can now define a Rust `extern "C"` function with `Box<T>` and use `T*` as the corresponding
7680 type on the C side.][62514] Please see [the documentation][box-memory-layout] for more information,
7681 including the important caveat about preferring to avoid `Box<T>` in Rust signatures for functions defined in C.
7682
7683[box-memory-layout]: https://doc.rust-lang.org/std/boxed/index.html#memory-layout
7684
7685Compiler
7686--------
7687
7688- [Rustc will now warn if you have unused loop `'label`s.][66325]
7689- [Removed support for the `i686-unknown-dragonfly` target.][67255]
7690- [Added tier 3 support\* for the `riscv64gc-unknown-linux-gnu` target.][66661]
7691- [You can now pass an arguments file passing the `@path` syntax
7692 to rustc.][66172] Note that the format differs somewhat from what is
7693 found in other tooling; please see [the documentation][argfile-docs] for
7694 more information.
7695- [You can now provide `--extern` flag without a path, indicating that it is
7696 available from the search path or specified with an `-L` flag.][64882]
7697
7698\* Refer to Rust's [platform support page][platform-support-doc] for more
7699information on Rust's tiered platform support.
7700
7701[argfile-docs]: https://doc.rust-lang.org/nightly/rustc/command-line-arguments.html#path-load-command-line-flags-from-a-path
7702
7703Libraries
7704---------
7705
7706- [The `core::panic` module is now stable.][66771] It was already stable
7707 through `std`.
7708- [`NonZero*` numerics now implement `From<NonZero*>` if it's a smaller integer
7709 width.][66277] E.g. `NonZeroU16` now implements `From<NonZeroU8>`.
7710- [`MaybeUninit<T>` now implements `fmt::Debug`.][65013]
7711
7712Stabilized APIs
7713---------------
7714
7715- [`Result::map_or`]
7716- [`Result::map_or_else`]
7717- [`std::rc::Weak::weak_count`]
7718- [`std::rc::Weak::strong_count`]
7719- [`std::sync::Weak::weak_count`]
7720- [`std::sync::Weak::strong_count`]
7721
7722Cargo
7723-----
7724
7725- [Cargo will now document all the private items for binary crates
7726 by default.][cargo/7593]
7727- [`cargo-install` will now reinstall the package if it detects that it is out
7728 of date.][cargo/7560]
7729- [Cargo.lock now uses a more git friendly format that should help to reduce
7730 merge conflicts.][cargo/7579]
7731- [You can now override specific dependencies's build settings][cargo/7591] E.g.
7732 `[profile.dev.package.image] opt-level = 2` sets the `image` crate's
7733 optimisation level to `2` for debug builds. You can also use
7734 `[profile.<profile>.build-override]` to override build scripts and
7735 their dependencies.
7736
7737Misc
7738----
7739
7740- [You can now specify `edition` in documentation code blocks to compile the block
7741 for that edition.][66238] E.g. `edition2018` tells rustdoc that the code sample
7742 should be compiled the 2018 edition of Rust.
7743- [You can now provide custom themes to rustdoc with `--theme`, and check the
7744 current theme with `--check-theme`.][54733]
7745- [You can use `#[cfg(doc)]` to compile an item when building documentation.][61351]
7746
7747Compatibility Notes
7748-------------------
7749
7750- [As previously announced 1.41 will be the last tier 1 release for 32-bit
7751 Apple targets.][apple-32bit-drop] This means that the source code is still
7752 available to build, but the targets are no longer being tested and release
7753 binaries for those platforms will no longer be distributed by the Rust project.
7754 Please refer to the linked blog post for more information.
7755
7756[54733]: https://github.com/rust-lang/rust/pull/54733/
7757[61351]: https://github.com/rust-lang/rust/pull/61351/
7758[62514]: https://github.com/rust-lang/rust/pull/62514/
7759[67255]: https://github.com/rust-lang/rust/pull/67255/
7760[66661]: https://github.com/rust-lang/rust/pull/66661/
7761[66771]: https://github.com/rust-lang/rust/pull/66771/
7762[66847]: https://github.com/rust-lang/rust/pull/66847/
7763[66238]: https://github.com/rust-lang/rust/pull/66238/
7764[66277]: https://github.com/rust-lang/rust/pull/66277/
7765[66325]: https://github.com/rust-lang/rust/pull/66325/
7766[66172]: https://github.com/rust-lang/rust/pull/66172/
7767[66183]: https://github.com/rust-lang/rust/pull/66183/
7768[65879]: https://github.com/rust-lang/rust/pull/65879/
7769[65013]: https://github.com/rust-lang/rust/pull/65013/
7770[64882]: https://github.com/rust-lang/rust/pull/64882/
7771[64325]: https://github.com/rust-lang/rust/pull/64325/
7772[cargo/7560]: https://github.com/rust-lang/cargo/pull/7560/
7773[cargo/7579]: https://github.com/rust-lang/cargo/pull/7579/
7774[cargo/7591]: https://github.com/rust-lang/cargo/pull/7591/
7775[cargo/7593]: https://github.com/rust-lang/cargo/pull/7593/
7776[`Result::map_or_else`]: https://doc.rust-lang.org/std/result/enum.Result.html#method.map_or_else
7777[`Result::map_or`]: https://doc.rust-lang.org/std/result/enum.Result.html#method.map_or
7778[`std::rc::Weak::weak_count`]: https://doc.rust-lang.org/std/rc/struct.Weak.html#method.weak_count
7779[`std::rc::Weak::strong_count`]: https://doc.rust-lang.org/std/rc/struct.Weak.html#method.strong_count
7780[`std::sync::Weak::weak_count`]: https://doc.rust-lang.org/std/sync/struct.Weak.html#method.weak_count
7781[`std::sync::Weak::strong_count`]: https://doc.rust-lang.org/std/sync/struct.Weak.html#method.strong_count
7782[apple-32bit-drop]: https://blog.rust-lang.org/2020/01/03/reducing-support-for-32-bit-apple-targets.html
7783
7784Version 1.40.0 (2019-12-19)
7785===========================
7786
7787Language
7788--------
7789- [You can now use tuple `struct`s and tuple `enum` variant's constructors in
7790 `const` contexts.][65188] e.g.
7791
7792 ```rust
7793 pub struct Point(i32, i32);
7794
7795 const ORIGIN: Point = {
7796 let constructor = Point;
7797
7798 constructor(0, 0)
7799 };
7800 ```
7801
7802- [You can now mark `struct`s, `enum`s, and `enum` variants with the `#[non_exhaustive]` attribute to
7803 indicate that there may be variants or fields added in the future.][64639]
7804 For example this requires adding a wild-card branch (`_ => {}`) to any match
7805 statements on a non-exhaustive `enum`. [(RFC 2008)]
7806- [You can now use function-like procedural macros in `extern` blocks and in
7807 type positions.][63931] e.g. `type Generated = macro!();`
7808- [Function-like and attribute procedural macros can now emit
7809 `macro_rules!` items, so you can now have your macros generate macros.][64035]
7810- [The `meta` pattern matcher in `macro_rules!` now correctly matches the modern
7811 attribute syntax.][63674] For example `(#[$m:meta])` now matches `#[attr]`,
7812 `#[attr{tokens}]`, `#[attr[tokens]]`, and `#[attr(tokens)]`.
7813
7814Compiler
7815--------
7816- [Added tier 3 support\* for the
7817 `thumbv7neon-unknown-linux-musleabihf` target.][66103]
7818- [Added tier 3 support for the
7819 `aarch64-unknown-none-softfloat` target.][64589]
7820- [Added tier 3 support for the `mips64-unknown-linux-muslabi64`, and
7821 `mips64el-unknown-linux-muslabi64` targets.][65843]
7822
7823\* Refer to Rust's [platform support page][platform-support-doc] for more
7824 information on Rust's tiered platform support.
7825
7826Libraries
7827---------
7828- [The `is_power_of_two` method on unsigned numeric types is now a `const` function.][65092]
7829
7830Stabilized APIs
7831---------------
7832- [`BTreeMap::get_key_value`]
7833- [`HashMap::get_key_value`]
7834- [`Option::as_deref_mut`]
7835- [`Option::as_deref`]
7836- [`Option::flatten`]
7837- [`UdpSocket::peer_addr`]
7838- [`f32::to_be_bytes`]
7839- [`f32::to_le_bytes`]
7840- [`f32::to_ne_bytes`]
7841- [`f64::to_be_bytes`]
7842- [`f64::to_le_bytes`]
7843- [`f64::to_ne_bytes`]
7844- [`f32::from_be_bytes`]
7845- [`f32::from_le_bytes`]
7846- [`f32::from_ne_bytes`]
7847- [`f64::from_be_bytes`]
7848- [`f64::from_le_bytes`]
7849- [`f64::from_ne_bytes`]
7850- [`mem::take`]
7851- [`slice::repeat`]
7852- [`todo!`]
7853
7854Cargo
7855-----
7856- [Cargo will now always display warnings, rather than only on
7857 fresh builds.][cargo/7450]
7858- [Feature flags (except `--all-features`) passed to a virtual workspace will
7859 now produce an error.][cargo/7507] Previously these flags were ignored.
7860- [You can now publish `dev-dependencies` without including
7861 a `version`.][cargo/7333]
7862
7863Misc
7864----
7865- [You can now specify the `#[cfg(doctest)]` attribute to include an item only
7866 when running documentation tests with `rustdoc`.][63803]
7867
7868Compatibility Notes
7869-------------------
7870- [As previously announced, any previous NLL warnings in the 2015 edition are
7871 now hard errors.][64221]
7872- [The `include!` macro will now warn if it failed to include the
7873 entire file.][64284] The `include!` macro unintentionally only includes the
7874 first _expression_ in a file, and this can be unintuitive. This will become
7875 either a hard error in a future release, or the behavior may be fixed to include all expressions as expected.
7876- [Using `#[inline]` on function prototypes and consts now emits a warning under
7877 `unused_attribute` lint.][65294] Using `#[inline]` anywhere else inside traits
7878 or `extern` blocks now correctly emits a hard error.
7879
7880[65294]: https://github.com/rust-lang/rust/pull/65294/
7881[66103]: https://github.com/rust-lang/rust/pull/66103/
7882[65843]: https://github.com/rust-lang/rust/pull/65843/
7883[65188]: https://github.com/rust-lang/rust/pull/65188/
7884[65092]: https://github.com/rust-lang/rust/pull/65092/
7885[64589]: https://github.com/rust-lang/rust/pull/64589/
7886[64639]: https://github.com/rust-lang/rust/pull/64639/
7887[64221]: https://github.com/rust-lang/rust/pull/64221/
7888[64284]: https://github.com/rust-lang/rust/pull/64284/
7889[63931]: https://github.com/rust-lang/rust/pull/63931/
7890[64035]: https://github.com/rust-lang/rust/pull/64035/
7891[63674]: https://github.com/rust-lang/rust/pull/63674/
7892[63803]: https://github.com/rust-lang/rust/pull/63803/
7893[cargo/7450]: https://github.com/rust-lang/cargo/pull/7450/
7894[cargo/7507]: https://github.com/rust-lang/cargo/pull/7507/
7895[cargo/7333]: https://github.com/rust-lang/cargo/pull/7333/
7896[(rfc 2008)]: https://rust-lang.github.io/rfcs/2008-non-exhaustive.html
7897[`f32::to_be_bytes`]: https://doc.rust-lang.org/std/primitive.f32.html#method.to_be_bytes
7898[`f32::to_le_bytes`]: https://doc.rust-lang.org/std/primitive.f32.html#method.to_le_bytes
7899[`f32::to_ne_bytes`]: https://doc.rust-lang.org/std/primitive.f32.html#method.to_ne_bytes
7900[`f64::to_be_bytes`]: https://doc.rust-lang.org/std/primitive.f64.html#method.to_be_bytes
7901[`f64::to_le_bytes`]: https://doc.rust-lang.org/std/primitive.f64.html#method.to_le_bytes
7902[`f64::to_ne_bytes`]: https://doc.rust-lang.org/std/primitive.f64.html#method.to_ne_bytes
7903[`f32::from_be_bytes`]: https://doc.rust-lang.org/std/primitive.f32.html#method.from_be_bytes
7904[`f32::from_le_bytes`]: https://doc.rust-lang.org/std/primitive.f32.html#method.from_le_bytes
7905[`f32::from_ne_bytes`]: https://doc.rust-lang.org/std/primitive.f32.html#method.from_ne_bytes
7906[`f64::from_be_bytes`]: https://doc.rust-lang.org/std/primitive.f64.html#method.from_be_bytes
7907[`f64::from_le_bytes`]: https://doc.rust-lang.org/std/primitive.f64.html#method.from_le_bytes
7908[`f64::from_ne_bytes`]: https://doc.rust-lang.org/std/primitive.f64.html#method.from_ne_bytes
7909[`option::flatten`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.flatten
7910[`option::as_deref`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.as_deref
7911[`option::as_deref_mut`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.as_deref_mut
7912[`hashmap::get_key_value`]: https://doc.rust-lang.org/std/collections/struct.HashMap.html#method.get_key_value
7913[`btreemap::get_key_value`]: https://doc.rust-lang.org/std/collections/struct.BTreeMap.html#method.get_key_value
7914[`slice::repeat`]: https://doc.rust-lang.org/std/primitive.slice.html#method.repeat
7915[`mem::take`]: https://doc.rust-lang.org/std/mem/fn.take.html
7916[`udpsocket::peer_addr`]: https://doc.rust-lang.org/std/net/struct.UdpSocket.html#method.peer_addr
7917[`todo!`]: https://doc.rust-lang.org/std/macro.todo.html
7918
7919
7920Version 1.39.0 (2019-11-07)
7921===========================
7922
7923Language
7924--------
7925- [You can now create `async` functions and blocks with `async fn`, `async move {}`, and
7926 `async {}` respectively, and you can now call `.await` on async expressions.][63209]
7927- [You can now use certain attributes on function, closure, and function pointer
7928 parameters.][64010] These attributes include `cfg`, `cfg_attr`, `allow`, `warn`,
7929 `deny`, `forbid` as well as inert helper attributes used by procedural macro
7930 attributes applied to items. e.g.
7931 ```rust
7932 fn len(
7933 #[cfg(windows)] slice: &[u16],
7934 #[cfg(not(windows))] slice: &[u8],
7935 ) -> usize {
7936 slice.len()
7937 }
7938 ```
7939- [You can now take shared references to bind-by-move patterns in the `if` guards
7940 of `match` arms.][63118] e.g.
7941 ```rust
7942 fn main() {
7943 let array: Box<[u8; 4]> = Box::new([1, 2, 3, 4]);
7944
7945 match array {
7946 nums
7947 // ---- `nums` is bound by move.
7948 if nums.iter().sum::<u8>() == 10
7949 // ^------ `.iter()` implicitly takes a reference to `nums`.
7950 => {
7951 drop(nums);
7952 // ----------- Legal as `nums` was bound by move and so we have ownership.
7953 }
7954 _ => unreachable!(),
7955 }
7956 }
7957 ```
7958
7959
7960
7961Compiler
7962--------
7963- [Added tier 3\* support for the `i686-unknown-uefi` target.][64334]
7964- [Added tier 3 support for the `sparc64-unknown-openbsd` target.][63595]
7965- [rustc will now trim code snippets in diagnostics to fit in your terminal.][63402]
7966 **Note** Cargo currently doesn't use this feature. Refer to
7967 [cargo#7315][cargo/7315] to track this feature's progress.
7968- [You can now pass `--show-output` argument to test binaries to print the
7969 output of successful tests.][62600]
7970
7971
7972\* Refer to Rust's [platform support page][platform-support-doc] for more
7973information on Rust's tiered platform support.
7974
7975Libraries
7976---------
7977- [`Vec::new` and `String::new` are now `const` functions.][64028]
7978- [`LinkedList::new` is now a `const` function.][63684]
7979- [`str::len`, `[T]::len` and `str::as_bytes` are now `const` functions.][63770]
7980- [The `abs`, `wrapping_abs`, and `overflowing_abs` numeric functions are
7981 now `const`.][63786]
7982
7983Stabilized APIs
7984---------------
7985- [`Pin::into_inner`]
7986- [`Instant::checked_duration_since`]
7987- [`Instant::saturating_duration_since`]
7988
7989Cargo
7990-----
7991- [You can now publish git dependencies if supplied with a `version`.][cargo/7237]
7992- [The `--all` flag has been renamed to `--workspace`.][cargo/7241] Using
7993 `--all` is now deprecated.
7994
7995Misc
7996----
7997- [You can now pass `-Clinker` to rustdoc to control the linker used
7998 for compiling doctests.][63834]
7999
8000Compatibility Notes
8001-------------------
8002- [Code that was previously accepted by the old borrow checker, but rejected by
8003 the NLL borrow checker is now a hard error in Rust 2018.][63565] This was
8004 previously a warning, and will also become a hard error in the Rust 2015
8005 edition in the 1.40.0 release.
8006- [`rustdoc` now requires `rustc` to be installed and in the same directory to
8007 run tests.][63827] This should improve performance when running a large
8008 amount of doctests.
8009- [The `try!` macro will now issue a deprecation warning.][62672] It is
8010 recommended to use the `?` operator instead.
8011- [`asinh(-0.0)` now correctly returns `-0.0`.][63698] Previously this
8012 returned `0.0`.
8013
8014[62600]: https://github.com/rust-lang/rust/pull/62600/
8015[62672]: https://github.com/rust-lang/rust/pull/62672/
8016[63118]: https://github.com/rust-lang/rust/pull/63118/
8017[63209]: https://github.com/rust-lang/rust/pull/63209/
8018[63402]: https://github.com/rust-lang/rust/pull/63402/
8019[63565]: https://github.com/rust-lang/rust/pull/63565/
8020[63595]: https://github.com/rust-lang/rust/pull/63595/
8021[63684]: https://github.com/rust-lang/rust/pull/63684/
8022[63698]: https://github.com/rust-lang/rust/pull/63698/
8023[63770]: https://github.com/rust-lang/rust/pull/63770/
8024[63786]: https://github.com/rust-lang/rust/pull/63786/
8025[63827]: https://github.com/rust-lang/rust/pull/63827/
8026[63834]: https://github.com/rust-lang/rust/pull/63834/
8027[64010]: https://github.com/rust-lang/rust/pull/64010/
8028[64028]: https://github.com/rust-lang/rust/pull/64028/
8029[64334]: https://github.com/rust-lang/rust/pull/64334/
8030[cargo/7237]: https://github.com/rust-lang/cargo/pull/7237/
8031[cargo/7241]: https://github.com/rust-lang/cargo/pull/7241/
8032[cargo/7315]: https://github.com/rust-lang/cargo/pull/7315/
8033[`Pin::into_inner`]: https://doc.rust-lang.org/std/pin/struct.Pin.html#method.into_inner
8034[`Instant::checked_duration_since`]: https://doc.rust-lang.org/std/time/struct.Instant.html#method.checked_duration_since
8035[`Instant::saturating_duration_since`]: https://doc.rust-lang.org/std/time/struct.Instant.html#method.saturating_duration_since
8036
8037Version 1.38.0 (2019-09-26)
8038==========================
8039
8040Language
8041--------
8042- [The `#[global_allocator]` attribute can now be used in submodules.][62735]
8043- [The `#[deprecated]` attribute can now be used on macros.][62042]
8044
8045Compiler
8046--------
8047- [Added pipelined compilation support to `rustc`.][62766] This will
8048 improve compilation times in some cases. For further information please refer
8049 to the [_"Evaluating pipelined rustc compilation"_][pipeline-internals] thread.
8050- [Added tier 3\* support for the `aarch64-uwp-windows-msvc`, `i686-uwp-windows-gnu`,
8051 `i686-uwp-windows-msvc`, `x86_64-uwp-windows-gnu`, and
8052 `x86_64-uwp-windows-msvc` targets.][60260]
8053- [Added tier 3 support for the `armv7-unknown-linux-gnueabi` and
8054 `armv7-unknown-linux-musleabi` targets.][63107]
8055- [Added tier 3 support for the `hexagon-unknown-linux-musl` target.][62814]
8056- [Added tier 3 support for the `riscv32i-unknown-none-elf` target.][62784]
8057- [Upgraded to LLVM 9.][62592]
8058
8059\* Refer to Rust's [platform support page][platform-support-doc] for more
8060information on Rust's tiered platform support.
8061
8062Libraries
8063---------
8064- [`ascii::EscapeDefault` now implements `Clone` and `Display`.][63421]
8065- [Derive macros for prelude traits (e.g. `Clone`, `Debug`, `Hash`) are now
8066 available at the same path as the trait.][63056] (e.g. The `Clone` derive macro
8067 is available at `std::clone::Clone`). This also makes all built-in macros
8068 available in `std`/`core` root. e.g. `std::include_bytes!`.
8069- [`str::Chars` now implements `Debug`.][63000]
8070- [`slice::{concat, connect, join}` now accepts `&[T]` in addition to `&T`.][62528]
8071- [`*const T` and `*mut T` now implement `marker::Unpin`.][62583]
8072- [`Arc<[T]>` and `Rc<[T]>` now implement `FromIterator<T>`.][61953]
8073- [Added euclidean remainder and division operations (`div_euclid`,
8074 `rem_euclid`) to all numeric primitives.][61884] Additionally `checked`,
8075 `overflowing`, and `wrapping` versions are available for all
8076 integer primitives.
8077- [`thread::AccessError` now implements `Clone`, `Copy`, `Eq`, `Error`, and
8078 `PartialEq`.][61491]
8079- [`iter::{StepBy, Peekable, Take}` now implement `DoubleEndedIterator`.][61457]
8080
8081Stabilized APIs
8082---------------
8083- [`<*const T>::cast`]
8084- [`<*mut T>::cast`]
8085- [`Duration::as_secs_f32`]
8086- [`Duration::as_secs_f64`]
8087- [`Duration::div_f32`]
8088- [`Duration::div_f64`]
8089- [`Duration::from_secs_f32`]
8090- [`Duration::from_secs_f64`]
8091- [`Duration::mul_f32`]
8092- [`Duration::mul_f64`]
8093- [`any::type_name`]
8094
8095Cargo
8096-----
8097- [Added pipelined compilation support to `cargo`.][cargo/7143]
8098- [You can now pass the `--features` option multiple times to enable
8099 multiple features.][cargo/7084]
8100
8101Rustdoc
8102-------
8103
8104- [Documentation on `pub use` statements is prepended to the documentation of the re-exported item][63048]
8105
8106Misc
8107----
8108- [`rustc` will now warn about some incorrect uses of
8109 `mem::{uninitialized, zeroed}` that are known to cause undefined behaviour.][63346]
8110
8111Compatibility Notes
8112-------------------
8113- The [`x86_64-unknown-uefi` platform can not be built][62785] with rustc
8114 1.38.0.
8115- The [`armv7-unknown-linux-gnueabihf` platform is known to have
8116 issues][62896] with certain crates such as libc.
8117
8118[60260]: https://github.com/rust-lang/rust/pull/60260/
8119[61457]: https://github.com/rust-lang/rust/pull/61457/
8120[61491]: https://github.com/rust-lang/rust/pull/61491/
8121[61884]: https://github.com/rust-lang/rust/pull/61884/
8122[61953]: https://github.com/rust-lang/rust/pull/61953/
8123[62042]: https://github.com/rust-lang/rust/pull/62042/
8124[62528]: https://github.com/rust-lang/rust/pull/62528/
8125[62583]: https://github.com/rust-lang/rust/pull/62583/
8126[62735]: https://github.com/rust-lang/rust/pull/62735/
8127[62766]: https://github.com/rust-lang/rust/pull/62766/
8128[62784]: https://github.com/rust-lang/rust/pull/62784/
8129[62592]: https://github.com/rust-lang/rust/pull/62592/
8130[62785]: https://github.com/rust-lang/rust/issues/62785/
8131[62814]: https://github.com/rust-lang/rust/pull/62814/
8132[62896]: https://github.com/rust-lang/rust/issues/62896/
8133[63000]: https://github.com/rust-lang/rust/pull/63000/
8134[63056]: https://github.com/rust-lang/rust/pull/63056/
8135[63107]: https://github.com/rust-lang/rust/pull/63107/
8136[63346]: https://github.com/rust-lang/rust/pull/63346/
8137[63421]: https://github.com/rust-lang/rust/pull/63421/
8138[cargo/7084]: https://github.com/rust-lang/cargo/pull/7084/
8139[cargo/7143]: https://github.com/rust-lang/cargo/pull/7143/
8140[63048]: https://github.com/rust-lang/rust/pull/63048
8141[`<*const T>::cast`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.cast
8142[`<*mut T>::cast`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.cast
8143[`Duration::as_secs_f32`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.as_secs_f32
8144[`Duration::as_secs_f64`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.as_secs_f64
8145[`Duration::div_f32`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.div_f32
8146[`Duration::div_f64`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.div_f64
8147[`Duration::from_secs_f32`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.from_secs_f32
8148[`Duration::from_secs_f64`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.from_secs_f64
8149[`Duration::mul_f32`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.mul_f32
8150[`Duration::mul_f64`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.mul_f64
8151[`any::type_name`]: https://doc.rust-lang.org/std/any/fn.type_name.html
8152[platform-support-doc]: https://doc.rust-lang.org/nightly/rustc/platform-support.html
8153[pipeline-internals]: https://internals.rust-lang.org/t/evaluating-pipelined-rustc-compilation/10199
8154
8155Version 1.37.0 (2019-08-15)
8156==========================
8157
8158Language
8159--------
8160- `#[must_use]` will now warn if the type is contained in a [tuple][61100],
8161 [`Box`][62228], or an [array][62235] and unused.
8162- [You can now use the `cfg` and `cfg_attr` attributes on
8163 generic parameters.][61547]
8164- [You can now use enum variants through type alias.][61682] e.g. You can
8165 write the following:
8166 ```rust
8167 type MyOption = Option<u8>;
8168
8169 fn increment_or_zero(x: MyOption) -> u8 {
8170 match x {
8171 MyOption::Some(y) => y + 1,
8172 MyOption::None => 0,
8173 }
8174 }
8175 ```
8176- [You can now use `_` as an identifier for consts.][61347] e.g. You can write
8177 `const _: u32 = 5;`.
8178- [You can now use `#[repr(align(X)]` on enums.][61229]
8179- [The `?` Kleene macro operator is now available in the
8180 2015 edition.][60932]
8181
8182Compiler
8183--------
8184- [You can now enable Profile-Guided Optimization with the `-C profile-generate`
8185 and `-C profile-use` flags.][61268] For more information on how to use profile
8186 guided optimization, please refer to the [rustc book][rustc-book-pgo].
8187- [The `rust-lldb` wrapper script should now work again.][61827]
8188
8189Libraries
8190---------
8191- [`mem::MaybeUninit<T>` is now ABI-compatible with `T`.][61802]
8192
8193Stabilized APIs
8194---------------
8195- [`BufReader::buffer`]
8196- [`BufWriter::buffer`]
8197- [`Cell::from_mut`]
8198- [`Cell<[T]>::as_slice_of_cells`][`Cell<slice>::as_slice_of_cells`]
8199- [`DoubleEndedIterator::nth_back`]
8200- [`Option::xor`]
8201- [`Wrapping::reverse_bits`]
8202- [`i128::reverse_bits`]
8203- [`i16::reverse_bits`]
8204- [`i32::reverse_bits`]
8205- [`i64::reverse_bits`]
8206- [`i8::reverse_bits`]
8207- [`isize::reverse_bits`]
8208- [`slice::copy_within`]
8209- [`u128::reverse_bits`]
8210- [`u16::reverse_bits`]
8211- [`u32::reverse_bits`]
8212- [`u64::reverse_bits`]
8213- [`u8::reverse_bits`]
8214- [`usize::reverse_bits`]
8215
8216Cargo
8217-----
8218- [`Cargo.lock` files are now included by default when publishing executable crates
8219 with executables.][cargo/7026]
8220- [You can now specify `default-run="foo"` in `[package]` to specify the
8221 default executable to use for `cargo run`.][cargo/7056]
8222
8223Misc
8224----
8225
8226Compatibility Notes
8227-------------------
8228- [Using `...` for inclusive range patterns will now warn by default.][61342]
8229 Please transition your code to using the `..=` syntax for inclusive
8230 ranges instead.
8231- [Using a trait object without the `dyn` will now warn by default.][61203]
8232 Please transition your code to use `dyn Trait` for trait objects instead.
8233
8234[62228]: https://github.com/rust-lang/rust/pull/62228/
8235[62235]: https://github.com/rust-lang/rust/pull/62235/
8236[61802]: https://github.com/rust-lang/rust/pull/61802/
8237[61827]: https://github.com/rust-lang/rust/pull/61827/
8238[61547]: https://github.com/rust-lang/rust/pull/61547/
8239[61682]: https://github.com/rust-lang/rust/pull/61682/
8240[61268]: https://github.com/rust-lang/rust/pull/61268/
8241[61342]: https://github.com/rust-lang/rust/pull/61342/
8242[61347]: https://github.com/rust-lang/rust/pull/61347/
8243[61100]: https://github.com/rust-lang/rust/pull/61100/
8244[61203]: https://github.com/rust-lang/rust/pull/61203/
8245[61229]: https://github.com/rust-lang/rust/pull/61229/
8246[60932]: https://github.com/rust-lang/rust/pull/60932/
8247[cargo/7026]: https://github.com/rust-lang/cargo/pull/7026/
8248[cargo/7056]: https://github.com/rust-lang/cargo/pull/7056/
8249[`BufReader::buffer`]: https://doc.rust-lang.org/std/io/struct.BufReader.html#method.buffer
8250[`BufWriter::buffer`]: https://doc.rust-lang.org/std/io/struct.BufWriter.html#method.buffer
8251[`Cell::from_mut`]: https://doc.rust-lang.org/std/cell/struct.Cell.html#method.from_mut
8252[`Cell<slice>::as_slice_of_cells`]: https://doc.rust-lang.org/std/cell/struct.Cell.html#method.as_slice_of_cells
8253[`DoubleEndedIterator::nth_back`]: https://doc.rust-lang.org/std/iter/trait.DoubleEndedIterator.html#method.nth_back
8254[`Option::xor`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.xor
8255[`Wrapping::reverse_bits`]: https://doc.rust-lang.org/std/num/struct.Wrapping.html#method.reverse_bits
8256[`i128::reverse_bits`]: https://doc.rust-lang.org/std/primitive.i128.html#method.reverse_bits
8257[`i16::reverse_bits`]: https://doc.rust-lang.org/std/primitive.i16.html#method.reverse_bits
8258[`i32::reverse_bits`]: https://doc.rust-lang.org/std/primitive.i32.html#method.reverse_bits
8259[`i64::reverse_bits`]: https://doc.rust-lang.org/std/primitive.i64.html#method.reverse_bits
8260[`i8::reverse_bits`]: https://doc.rust-lang.org/std/primitive.i8.html#method.reverse_bits
8261[`isize::reverse_bits`]: https://doc.rust-lang.org/std/primitive.isize.html#method.reverse_bits
8262[`slice::copy_within`]: https://doc.rust-lang.org/std/primitive.slice.html#method.copy_within
8263[`u128::reverse_bits`]: https://doc.rust-lang.org/std/primitive.u128.html#method.reverse_bits
8264[`u16::reverse_bits`]: https://doc.rust-lang.org/std/primitive.u16.html#method.reverse_bits
8265[`u32::reverse_bits`]: https://doc.rust-lang.org/std/primitive.u32.html#method.reverse_bits
8266[`u64::reverse_bits`]: https://doc.rust-lang.org/std/primitive.u64.html#method.reverse_bits
8267[`u8::reverse_bits`]: https://doc.rust-lang.org/std/primitive.u8.html#method.reverse_bits
8268[`usize::reverse_bits`]: https://doc.rust-lang.org/std/primitive.usize.html#method.reverse_bits
8269[rustc-book-pgo]: https://doc.rust-lang.org/rustc/profile-guided-optimization.html
8270
8271
8272Version 1.36.0 (2019-07-04)
8273==========================
8274
8275Language
8276--------
8277- [Non-Lexical Lifetimes are now enabled on the 2015 edition.][59114]
8278- [The order of traits in trait objects no longer affects the semantics of that
8279 object.][59445] e.g. `dyn Send + fmt::Debug` is now equivalent to
8280 `dyn fmt::Debug + Send`, where this was previously not the case.
8281
8282Libraries
8283---------
8284- [`HashMap`'s implementation has been replaced with `hashbrown::HashMap` implementation.][58623]
8285- [`TryFromSliceError` now implements `From<Infallible>`.][60318]
8286- [`mem::needs_drop` is now available as a const fn.][60364]
8287- [`alloc::Layout::from_size_align_unchecked` is now available as a const fn.][60370]
8288- [`String` now implements `BorrowMut<str>`.][60404]
8289- [`io::Cursor` now implements `Default`.][60234]
8290- [Both `NonNull::{dangling, cast}` are now const fns.][60244]
8291- [The `alloc` crate is now stable.][59675] `alloc` allows you to use a subset
8292 of `std` (e.g. `Vec`, `Box`, `Arc`) in `#![no_std]` environments if the
8293 environment has access to heap memory allocation.
8294- [`String` now implements `From<&String>`.][59825]
8295- [You can now pass multiple arguments to the `dbg!` macro.][59826] `dbg!` will
8296 return a tuple of each argument when there is multiple arguments.
8297- [`Result::{is_err, is_ok}` are now `#[must_use]` and will produce a warning if
8298 not used.][59648]
8299
8300Stabilized APIs
8301---------------
8302- [`VecDeque::rotate_left`]
8303- [`VecDeque::rotate_right`]
8304- [`Iterator::copied`]
8305- [`io::IoSlice`]
8306- [`io::IoSliceMut`]
8307- [`Read::read_vectored`]
8308- [`Write::write_vectored`]
8309- [`str::as_mut_ptr`]
8310- [`mem::MaybeUninit`]
8311- [`pointer::align_offset`]
8312- [`future::Future`]
8313- [`task::Context`]
8314- [`task::RawWaker`]
8315- [`task::RawWakerVTable`]
8316- [`task::Waker`]
8317- [`task::Poll`]
8318
8319Cargo
8320-----
8321- [Cargo will now produce an error if you attempt to use the name of a required dependency as a feature.][cargo/6860]
8322- [You can now pass the `--offline` flag to run cargo without accessing the network.][cargo/6934]
8323
8324You can find further change's in [Cargo's 1.36.0 release notes][cargo-1-36-0].
8325
8326Clippy
8327------
8328There have been numerous additions and fixes to clippy, see [Clippy's 1.36.0 release notes][clippy-1-36-0] for more details.
8329
8330Misc
8331----
8332
8333Compatibility Notes
8334-------------------
8335- With the stabilisation of `mem::MaybeUninit`, `mem::uninitialized` use is no
8336 longer recommended, and will be deprecated in 1.39.0.
8337
8338[60318]: https://github.com/rust-lang/rust/pull/60318/
8339[60364]: https://github.com/rust-lang/rust/pull/60364/
8340[60370]: https://github.com/rust-lang/rust/pull/60370/
8341[60404]: https://github.com/rust-lang/rust/pull/60404/
8342[60234]: https://github.com/rust-lang/rust/pull/60234/
8343[60244]: https://github.com/rust-lang/rust/pull/60244/
8344[58623]: https://github.com/rust-lang/rust/pull/58623/
8345[59648]: https://github.com/rust-lang/rust/pull/59648/
8346[59675]: https://github.com/rust-lang/rust/pull/59675/
8347[59825]: https://github.com/rust-lang/rust/pull/59825/
8348[59826]: https://github.com/rust-lang/rust/pull/59826/
8349[59445]: https://github.com/rust-lang/rust/pull/59445/
8350[59114]: https://github.com/rust-lang/rust/pull/59114/
8351[cargo/6860]: https://github.com/rust-lang/cargo/pull/6860/
8352[cargo/6934]: https://github.com/rust-lang/cargo/pull/6934/
8353[`VecDeque::rotate_left`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.rotate_left
8354[`VecDeque::rotate_right`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.rotate_right
8355[`Iterator::copied`]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#tymethod.copied
8356[`io::IoSlice`]: https://doc.rust-lang.org/std/io/struct.IoSlice.html
8357[`io::IoSliceMut`]: https://doc.rust-lang.org/std/io/struct.IoSliceMut.html
8358[`Read::read_vectored`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_vectored
8359[`Write::write_vectored`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_vectored
8360[`str::as_mut_ptr`]: https://doc.rust-lang.org/std/primitive.str.html#method.as_mut_ptr
8361[`mem::MaybeUninit`]: https://doc.rust-lang.org/std/mem/union.MaybeUninit.html
8362[`pointer::align_offset`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.align_offset
8363[`future::Future`]: https://doc.rust-lang.org/std/future/trait.Future.html
8364[`task::Context`]: https://doc.rust-lang.org/beta/std/task/struct.Context.html
8365[`task::RawWaker`]: https://doc.rust-lang.org/beta/std/task/struct.RawWaker.html
8366[`task::RawWakerVTable`]: https://doc.rust-lang.org/beta/std/task/struct.RawWakerVTable.html
8367[`task::Waker`]: https://doc.rust-lang.org/beta/std/task/struct.Waker.html
8368[`task::Poll`]: https://doc.rust-lang.org/beta/std/task/enum.Poll.html
8369[clippy-1-36-0]: https://github.com/rust-lang/rust-clippy/blob/master/CHANGELOG.md#rust-136
8370[cargo-1-36-0]: https://github.com/rust-lang/cargo/blob/master/CHANGELOG.md#cargo-136-2019-07-04
8371
8372
8373Version 1.35.0 (2019-05-23)
8374==========================
8375
8376Language
8377--------
8378- [`FnOnce`, `FnMut`, and the `Fn` traits are now implemented for `Box<FnOnce>`,
8379 `Box<FnMut>`, and `Box<Fn>` respectively.][59500]
8380- [You can now coerce closures into unsafe function pointers.][59580] e.g.
8381 ```rust
8382 unsafe fn call_unsafe(func: unsafe fn()) {
8383 func()
8384 }
8385
8386 pub fn main() {
8387 unsafe { call_unsafe(|| {}); }
8388 }
8389 ```
8390
8391
8392Compiler
8393--------
8394- [Added the `armv6-unknown-freebsd-gnueabihf` and
8395 `armv7-unknown-freebsd-gnueabihf` targets.][58080]
8396- [Added the `wasm32-unknown-wasi` target.][59464]
8397
8398
8399Libraries
8400---------
8401- [`Thread` will now show its ID in `Debug` output.][59460]
8402- [`StdinLock`, `StdoutLock`, and `StderrLock` now implement `AsRawFd`.][59512]
8403- [`alloc::System` now implements `Default`.][59451]
8404- [Expanded `Debug` output (`{:#?}`) for structs now has a trailing comma on the
8405 last field.][59076]
8406- [`char::{ToLowercase, ToUppercase}` now
8407 implement `ExactSizeIterator`.][58778]
8408- [All `NonZero` numeric types now implement `FromStr`.][58717]
8409- [Removed the `Read` trait bounds
8410 on the `BufReader::{get_ref, get_mut, into_inner}` methods.][58423]
8411- [You can now call the `dbg!` macro without any parameters to print the file
8412 and line where it is called.][57847]
8413- [In place ASCII case conversions are now up to 4× faster.][59283]
8414 e.g. `str::make_ascii_lowercase`
8415- [`hash_map::{OccupiedEntry, VacantEntry}` now implement `Sync`
8416 and `Send`.][58369]
8417
8418Stabilized APIs
8419---------------
8420- [`f32::copysign`]
8421- [`f64::copysign`]
8422- [`RefCell::replace_with`]
8423- [`RefCell::map_split`]
8424- [`ptr::hash`]
8425- [`Range::contains`]
8426- [`RangeFrom::contains`]
8427- [`RangeTo::contains`]
8428- [`RangeInclusive::contains`]
8429- [`RangeToInclusive::contains`]
8430- [`Option::copied`]
8431
8432Cargo
8433-----
8434- [You can now set `cargo:rustc-cdylib-link-arg` at build time to pass custom
8435 linker arguments when building a `cdylib`.][cargo/6298] Its usage is highly
8436 platform specific.
8437
8438Misc
8439----
8440- [The Rust toolchain is now available natively for musl based distros.][58575]
8441
8442[59460]: https://github.com/rust-lang/rust/pull/59460/
8443[59464]: https://github.com/rust-lang/rust/pull/59464/
8444[59500]: https://github.com/rust-lang/rust/pull/59500/
8445[59512]: https://github.com/rust-lang/rust/pull/59512/
8446[59580]: https://github.com/rust-lang/rust/pull/59580/
8447[59283]: https://github.com/rust-lang/rust/pull/59283/
8448[59451]: https://github.com/rust-lang/rust/pull/59451/
8449[59076]: https://github.com/rust-lang/rust/pull/59076/
8450[58778]: https://github.com/rust-lang/rust/pull/58778/
8451[58717]: https://github.com/rust-lang/rust/pull/58717/
8452[58369]: https://github.com/rust-lang/rust/pull/58369/
8453[58423]: https://github.com/rust-lang/rust/pull/58423/
8454[58080]: https://github.com/rust-lang/rust/pull/58080/
8455[57847]: https://github.com/rust-lang/rust/pull/57847/
8456[58575]: https://github.com/rust-lang/rust/pull/58575
8457[cargo/6298]: https://github.com/rust-lang/cargo/pull/6298/
8458[`f32::copysign`]: https://doc.rust-lang.org/stable/std/primitive.f32.html#method.copysign
8459[`f64::copysign`]: https://doc.rust-lang.org/stable/std/primitive.f64.html#method.copysign
8460[`RefCell::replace_with`]: https://doc.rust-lang.org/stable/std/cell/struct.RefCell.html#method.replace_with
8461[`RefCell::map_split`]: https://doc.rust-lang.org/stable/std/cell/struct.RefCell.html#method.map_split
8462[`ptr::hash`]: https://doc.rust-lang.org/stable/std/ptr/fn.hash.html
8463[`Range::contains`]: https://doc.rust-lang.org/std/ops/struct.Range.html#method.contains
8464[`RangeFrom::contains`]: https://doc.rust-lang.org/std/ops/struct.RangeFrom.html#method.contains
8465[`RangeTo::contains`]: https://doc.rust-lang.org/std/ops/struct.RangeTo.html#method.contains
8466[`RangeInclusive::contains`]: https://doc.rust-lang.org/std/ops/struct.RangeInclusive.html#method.contains
8467[`RangeToInclusive::contains`]: https://doc.rust-lang.org/std/ops/struct.RangeToInclusive.html#method.contains
8468[`Option::copied`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.copied
8469
8470Version 1.34.2 (2019-05-14)
8471===========================
8472
8473* [Destabilize the `Error::type_id` function due to a security
8474 vulnerability][60785] ([CVE-2019-12083])
8475
8476[60785]: https://github.com/rust-lang/rust/pull/60785
8477[CVE-2019-12083]: https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-12083
8478
8479Version 1.34.1 (2019-04-25)
8480===========================
8481
8482* [Fix false positives for the `redundant_closure` Clippy lint][clippy/3821]
8483* [Fix false positives for the `missing_const_for_fn` Clippy lint][clippy/3844]
8484* [Fix Clippy panic when checking some macros][clippy/3805]
8485
8486[clippy/3821]: https://github.com/rust-lang/rust-clippy/pull/3821
8487[clippy/3844]: https://github.com/rust-lang/rust-clippy/pull/3844
8488[clippy/3805]: https://github.com/rust-lang/rust-clippy/pull/3805
8489
8490Version 1.34.0 (2019-04-11)
8491==========================
8492
8493Language
8494--------
8495- [You can now use `#[deprecated = "reason"]`][58166] as a shorthand for
8496 `#[deprecated(note = "reason")]`. This was previously allowed by mistake
8497 but had no effect.
8498- [You can now accept token streams in `#[attr()]`,`#[attr[]]`, and
8499 `#[attr{}]` procedural macros.][57367]
8500- [You can now write `extern crate self as foo;`][57407] to import your
8501 crate's root into the extern prelude.
8502
8503
8504Compiler
8505--------
8506- [You can now target `riscv64imac-unknown-none-elf` and
8507 `riscv64gc-unknown-none-elf`.][58406]
8508- [You can now enable linker plugin LTO optimisations with
8509 `-C linker-plugin-lto`.][58057] This allows rustc to compile your Rust code
8510 into LLVM bitcode allowing LLVM to perform LTO optimisations across C/C++ FFI
8511 boundaries.
8512- [You can now target `powerpc64-unknown-freebsd`.][57809]
8513
8514
8515Libraries
8516---------
8517- [The trait bounds have been removed on some of `HashMap<K, V, S>`'s and
8518 `HashSet<T, S>`'s basic methods.][58370] Most notably you no longer require
8519 the `Hash` trait to create an iterator.
8520- [The `Ord` trait bounds have been removed on some of `BinaryHeap<T>`'s basic
8521 methods.][58421] Most notably you no longer require the `Ord` trait to create
8522 an iterator.
8523- [The methods `overflowing_neg` and `wrapping_neg` are now `const` functions
8524 for all numeric types.][58044]
8525- [Indexing a `str` is now generic over all types that
8526 implement `SliceIndex<str>`.][57604]
8527- [`str::trim`, `str::trim_matches`, `str::trim_{start, end}`, and
8528 `str::trim_{start, end}_matches` are now `#[must_use]`][57106] and will
8529 produce a warning if their returning type is unused.
8530- [The methods `checked_pow`, `saturating_pow`, `wrapping_pow`, and
8531 `overflowing_pow` are now available for all numeric types.][57873] These are
8532 equivalent to methods such as `wrapping_add` for the `pow` operation.
8533
8534
8535Stabilized APIs
8536---------------
8537
8538#### std & core
8539* [`Any::type_id`]
8540* [`Error::type_id`]
8541* [`atomic::AtomicI16`]
8542* [`atomic::AtomicI32`]
8543* [`atomic::AtomicI64`]
8544* [`atomic::AtomicI8`]
8545* [`atomic::AtomicU16`]
8546* [`atomic::AtomicU32`]
8547* [`atomic::AtomicU64`]
8548* [`atomic::AtomicU8`]
8549* [`convert::Infallible`]
8550* [`convert::TryFrom`]
8551* [`convert::TryInto`]
8552* [`iter::from_fn`]
8553* [`iter::successors`]
8554* [`num::NonZeroI128`]
8555* [`num::NonZeroI16`]
8556* [`num::NonZeroI32`]
8557* [`num::NonZeroI64`]
8558* [`num::NonZeroI8`]
8559* [`num::NonZeroIsize`]
8560* [`slice::sort_by_cached_key`]
8561* [`str::escape_debug`]
8562* [`str::escape_default`]
8563* [`str::escape_unicode`]
8564* [`str::split_ascii_whitespace`]
8565
8566#### std
8567* [`Instant::checked_add`]
8568* [`Instant::checked_sub`]
8569* [`SystemTime::checked_add`]
8570* [`SystemTime::checked_sub`]
8571
8572Cargo
8573-----
8574- [You can now use alternative registries to crates.io.][cargo/6654]
8575
8576Misc
8577----
8578- [You can now use the `?` operator in your documentation tests without manually
8579 adding `fn main() -> Result<(), _> {}`.][56470]
8580
8581Compatibility Notes
8582-------------------
8583- [`Command::before_exec` is being replaced by the unsafe method
8584 `Command::pre_exec`][58059] and will be deprecated with Rust 1.37.0.
8585- [Use of `ATOMIC_{BOOL, ISIZE, USIZE}_INIT` is now deprecated][57425] as you
8586 can now use `const` functions in `static` variables.
8587
8588[58370]: https://github.com/rust-lang/rust/pull/58370/
8589[58406]: https://github.com/rust-lang/rust/pull/58406/
8590[58421]: https://github.com/rust-lang/rust/pull/58421/
8591[58166]: https://github.com/rust-lang/rust/pull/58166/
8592[58044]: https://github.com/rust-lang/rust/pull/58044/
8593[58057]: https://github.com/rust-lang/rust/pull/58057/
8594[58059]: https://github.com/rust-lang/rust/pull/58059/
8595[57809]: https://github.com/rust-lang/rust/pull/57809/
8596[57873]: https://github.com/rust-lang/rust/pull/57873/
8597[57604]: https://github.com/rust-lang/rust/pull/57604/
8598[57367]: https://github.com/rust-lang/rust/pull/57367/
8599[57407]: https://github.com/rust-lang/rust/pull/57407/
8600[57425]: https://github.com/rust-lang/rust/pull/57425/
8601[57106]: https://github.com/rust-lang/rust/pull/57106/
8602[56470]: https://github.com/rust-lang/rust/pull/56470/
8603[cargo/6654]: https://github.com/rust-lang/cargo/pull/6654/
8604[`Any::type_id`]: https://doc.rust-lang.org/std/any/trait.Any.html#tymethod.type_id
8605[`Error::type_id`]: https://doc.rust-lang.org/std/error/trait.Error.html#method.type_id
8606[`atomic::AtomicI16`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicI16.html
8607[`atomic::AtomicI32`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicI32.html
8608[`atomic::AtomicI64`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicI64.html
8609[`atomic::AtomicI8`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicI8.html
8610[`atomic::AtomicU16`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicU16.html
8611[`atomic::AtomicU32`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicU32.html
8612[`atomic::AtomicU64`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicU64.html
8613[`atomic::AtomicU8`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicU8.html
8614[`convert::Infallible`]: https://doc.rust-lang.org/std/convert/enum.Infallible.html
8615[`convert::TryFrom`]: https://doc.rust-lang.org/std/convert/trait.TryFrom.html
8616[`convert::TryInto`]: https://doc.rust-lang.org/std/convert/trait.TryInto.html
8617[`iter::from_fn`]: https://doc.rust-lang.org/std/iter/fn.from_fn.html
8618[`iter::successors`]: https://doc.rust-lang.org/std/iter/fn.successors.html
8619[`num::NonZeroI128`]: https://doc.rust-lang.org/std/num/struct.NonZeroI128.html
8620[`num::NonZeroI16`]: https://doc.rust-lang.org/std/num/struct.NonZeroI16.html
8621[`num::NonZeroI32`]: https://doc.rust-lang.org/std/num/struct.NonZeroI32.html
8622[`num::NonZeroI64`]: https://doc.rust-lang.org/std/num/struct.NonZeroI64.html
8623[`num::NonZeroI8`]: https://doc.rust-lang.org/std/num/struct.NonZeroI8.html
8624[`num::NonZeroIsize`]: https://doc.rust-lang.org/std/num/struct.NonZeroIsize.html
8625[`slice::sort_by_cached_key`]: https://doc.rust-lang.org/std/primitive.slice.html#method.sort_by_cached_key
8626[`str::escape_debug`]: https://doc.rust-lang.org/std/primitive.str.html#method.escape_debug
8627[`str::escape_default`]: https://doc.rust-lang.org/std/primitive.str.html#method.escape_default
8628[`str::escape_unicode`]: https://doc.rust-lang.org/std/primitive.str.html#method.escape_unicode
8629[`str::split_ascii_whitespace`]: https://doc.rust-lang.org/std/primitive.str.html#method.split_ascii_whitespace
8630[`Instant::checked_add`]: https://doc.rust-lang.org/std/time/struct.Instant.html#method.checked_add
8631[`Instant::checked_sub`]: https://doc.rust-lang.org/std/time/struct.Instant.html#method.checked_sub
8632[`SystemTime::checked_add`]: https://doc.rust-lang.org/std/time/struct.SystemTime.html#method.checked_add
8633[`SystemTime::checked_sub`]: https://doc.rust-lang.org/std/time/struct.SystemTime.html#method.checked_sub
8634
8635
8636Version 1.33.0 (2019-02-28)
8637==========================
8638
8639Language
8640--------
8641- [You can now use the `cfg(target_vendor)` attribute.][57465] E.g.
8642 `#[cfg(target_vendor="apple")] fn main() { println!("Hello Apple!"); }`
8643- [Integer patterns such as in a match expression can now be exhaustive.][56362]
8644 E.g. You can have match statement on a `u8` that covers `0..=255` and
8645 you would no longer be required to have a `_ => unreachable!()` case.
8646- [You can now have multiple patterns in `if let` and `while let`
8647 expressions.][57532] You can do this with the same syntax as a `match`
8648 expression. E.g.
8649 ```rust
8650 enum Creature {
8651 Crab(String),
8652 Lobster(String),
8653 Person(String),
8654 }
8655
8656 fn main() {
8657 let state = Creature::Crab("Ferris");
8658
8659 if let Creature::Crab(name) | Creature::Person(name) = state {
8660 println!("This creature's name is: {}", name);
8661 }
8662 }
8663 ```
8664- [You can now have irrefutable `if let` and `while let` patterns.][57535] Using
8665 this feature will by default produce a warning as this behaviour can be
8666 unintuitive. E.g. `if let _ = 5 {}`
8667- [You can now use `let` bindings, assignments, expression statements,
8668 and irrefutable pattern destructuring in const functions.][57175]
8669- [You can now call unsafe const functions.][57067] E.g.
8670 ```rust
8671 const unsafe fn foo() -> i32 { 5 }
8672 const fn bar() -> i32 {
8673 unsafe { foo() }
8674 }
8675 ```
8676- [You can now specify multiple attributes in a `cfg_attr` attribute.][57332]
8677 E.g. `#[cfg_attr(all(), must_use, optimize)]`
8678- [You can now specify a specific alignment with the `#[repr(packed)]`
8679 attribute.][57049] E.g. `#[repr(packed(2))] struct Foo(i16, i32);` is a struct
8680 with an alignment of 2 bytes and a size of 6 bytes.
8681- [You can now import an item from a module as an `_`.][56303] This allows you to
8682 import a trait's impls, and not have the name in the namespace. E.g.
8683 ```rust
8684 use std::io::Read as _;
8685
8686 // Allowed as there is only one `Read` in the module.
8687 pub trait Read {}
8688 ```
8689- [You may now use `Rc`, `Arc`, and `Pin` as method receivers][56805].
8690
8691Compiler
8692--------
8693- [You can now set a linker flavor for `rustc` with the `-Clinker-flavor`
8694 command line argument.][56351]
8695- [The minimum required LLVM version has been bumped to 6.0.][56642]
8696- [Added support for the PowerPC64 architecture on FreeBSD.][57615]
8697- [The `x86_64-fortanix-unknown-sgx` target support has been upgraded to
8698 tier 2 support.][57130] Visit the [platform support][platform-support] page for
8699 information on Rust's platform support.
8700- [Added support for the `thumbv7neon-linux-androideabi` and
8701 `thumbv7neon-unknown-linux-gnueabihf` targets.][56947]
8702- [Added support for the `x86_64-unknown-uefi` target.][56769]
8703
8704Libraries
8705---------
8706- [The methods `overflowing_{add, sub, mul, shl, shr}` are now `const`
8707 functions for all numeric types.][57566]
8708- [The methods `rotate_left`, `rotate_right`, and `wrapping_{add, sub, mul, shl, shr}`
8709 are now `const` functions for all numeric types.][57105]
8710- [The methods `is_positive` and `is_negative` are now `const` functions for
8711 all signed numeric types.][57105]
8712- [The `get` method for all `NonZero` types is now `const`.][57167]
8713- [The methods `count_ones`, `count_zeros`, `leading_zeros`, `trailing_zeros`,
8714 `swap_bytes`, `from_be`, `from_le`, `to_be`, `to_le` are now `const` for all
8715 numeric types.][57234]
8716- [`Ipv4Addr::new` is now a `const` function][57234]
8717
8718Stabilized APIs
8719---------------
8720- [`unix::FileExt::read_exact_at`]
8721- [`unix::FileExt::write_all_at`]
8722- [`Option::transpose`]
8723- [`Result::transpose`]
8724- [`convert::identity`]
8725- [`pin::Pin`]
8726- [`marker::Unpin`]
8727- [`marker::PhantomPinned`]
8728- [`Vec::resize_with`]
8729- [`VecDeque::resize_with`]
8730- [`Duration::as_millis`]
8731- [`Duration::as_micros`]
8732- [`Duration::as_nanos`]
8733
8734
8735Cargo
8736-----
8737- [You can now publish crates that require a feature flag to compile with
8738 `cargo publish --features` or `cargo publish --all-features`.][cargo/6453]
8739- [Cargo should now rebuild a crate if a file was modified during the initial
8740 build.][cargo/6484]
8741
8742Compatibility Notes
8743-------------------
8744- The methods `str::{trim_left, trim_right, trim_left_matches, trim_right_matches}`
8745 are now deprecated in the standard library, and their usage will now produce a warning.
8746 Please use the `str::{trim_start, trim_end, trim_start_matches, trim_end_matches}`
8747 methods instead.
8748- The `Error::cause` method has been deprecated in favor of `Error::source` which supports
8749 downcasting.
8750- [Libtest no longer creates a new thread for each test when
8751 `--test-threads=1`. It also runs the tests in deterministic order][56243]
8752
8753[56243]: https://github.com/rust-lang/rust/pull/56243
8754[56303]: https://github.com/rust-lang/rust/pull/56303/
8755[56351]: https://github.com/rust-lang/rust/pull/56351/
8756[56362]: https://github.com/rust-lang/rust/pull/56362
8757[56642]: https://github.com/rust-lang/rust/pull/56642/
8758[56769]: https://github.com/rust-lang/rust/pull/56769/
8759[56805]: https://github.com/rust-lang/rust/pull/56805
8760[56947]: https://github.com/rust-lang/rust/pull/56947/
8761[57049]: https://github.com/rust-lang/rust/pull/57049/
8762[57067]: https://github.com/rust-lang/rust/pull/57067/
8763[57105]: https://github.com/rust-lang/rust/pull/57105
8764[57130]: https://github.com/rust-lang/rust/pull/57130/
8765[57167]: https://github.com/rust-lang/rust/pull/57167/
8766[57175]: https://github.com/rust-lang/rust/pull/57175/
8767[57234]: https://github.com/rust-lang/rust/pull/57234/
8768[57332]: https://github.com/rust-lang/rust/pull/57332/
8769[57465]: https://github.com/rust-lang/rust/pull/57465/
8770[57532]: https://github.com/rust-lang/rust/pull/57532/
8771[57535]: https://github.com/rust-lang/rust/pull/57535/
8772[57566]: https://github.com/rust-lang/rust/pull/57566/
8773[57615]: https://github.com/rust-lang/rust/pull/57615/
8774[cargo/6453]: https://github.com/rust-lang/cargo/pull/6453/
8775[cargo/6484]: https://github.com/rust-lang/cargo/pull/6484/
8776[`unix::FileExt::read_exact_at`]: https://doc.rust-lang.org/std/os/unix/fs/trait.FileExt.html#method.read_exact_at
8777[`unix::FileExt::write_all_at`]: https://doc.rust-lang.org/std/os/unix/fs/trait.FileExt.html#method.write_all_at
8778[`Option::transpose`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.transpose
8779[`Result::transpose`]: https://doc.rust-lang.org/std/result/enum.Result.html#method.transpose
8780[`convert::identity`]: https://doc.rust-lang.org/std/convert/fn.identity.html
8781[`pin::Pin`]: https://doc.rust-lang.org/std/pin/struct.Pin.html
8782[`marker::Unpin`]: https://doc.rust-lang.org/stable/std/marker/trait.Unpin.html
8783[`marker::PhantomPinned`]: https://doc.rust-lang.org/nightly/std/marker/struct.PhantomPinned.html
8784[`Vec::resize_with`]: https://doc.rust-lang.org/std/vec/struct.Vec.html#method.resize_with
8785[`VecDeque::resize_with`]: https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.resize_with
8786[`Duration::as_millis`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.as_millis
8787[`Duration::as_micros`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.as_micros
8788[`Duration::as_nanos`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.as_nanos
8789[platform-support]: https://forge.rust-lang.org/platform-support.html
8790
8791Version 1.32.0 (2019-01-17)
8792==========================
8793
8794Language
8795--------
8796#### 2018 edition
8797- [You can now use the `?` operator in macro definitions.][56245] The `?`
8798 operator allows you to specify zero or one repetitions similar to the `*` and
8799 `+` operators.
8800- [Module paths with no leading keyword like `super`, `self`, or `crate`, will
8801 now always resolve to the item (`enum`, `struct`, etc.) available in the
8802 module if present, before resolving to a external crate or an item the prelude.][56759]
8803 E.g.
8804 ```rust
8805 enum Color { Red, Green, Blue }
8806
8807 use Color::*;
8808 ```
8809
8810#### All editions
8811- [You can now match against `PhantomData<T>` types.][55837]
8812- [You can now match against literals in macros with the `literal`
8813 specifier.][56072] This will match against a literal of any type.
8814 E.g. `1`, `'A'`, `"Hello World"`
8815- [Self can now be used as a constructor and pattern for unit and tuple structs.][56365] E.g.
8816 ```rust
8817 struct Point(i32, i32);
8818
8819 impl Point {
8820 pub fn new(x: i32, y: i32) -> Self {
8821 Self(x, y)
8822 }
8823
8824 pub fn is_origin(&self) -> bool {
8825 match self {
8826 Self(0, 0) => true,
8827 _ => false,
8828 }
8829 }
8830 }
8831 ```
8832- [Self can also now be used in type definitions.][56366] E.g.
8833 ```rust
8834 enum List<T>
8835 where
8836 Self: PartialOrd<Self> // can write `Self` instead of `List<T>`
8837 {
8838 Nil,
8839 Cons(T, Box<Self>) // likewise here
8840 }
8841 ```
8842- [You can now mark traits with `#[must_use]`.][55663] This provides a warning if
8843 a `impl Trait` or `dyn Trait` is returned and unused in the program.
8844
8845Compiler
8846--------
8847- [The default allocator has changed from jemalloc to the default allocator on
8848 your system.][55238] The compiler itself on Linux & macOS will still use
8849 jemalloc, but programs compiled with it will use the system allocator.
8850- [Added the `aarch64-pc-windows-msvc` target.][55702]
8851
8852Libraries
8853---------
8854- [`PathBuf` now implements `FromStr`.][55148]
8855- [`Box<[T]>` now implements `FromIterator<T>`.][55843]
8856- [The `dbg!` macro has been stabilized.][56395] This macro enables you to
8857 easily debug expressions in your rust program. E.g.
8858 ```rust
8859 let a = 2;
8860 let b = dbg!(a * 2) + 1;
8861 // ^-- prints: [src/main.rs:4] a * 2 = 4
8862 assert_eq!(b, 5);
8863 ```
8864
8865The following APIs are now `const` functions and can be used in a
8866`const` context.
8867
8868- [`Cell::as_ptr`]
8869- [`UnsafeCell::get`]
8870- [`char::is_ascii`]
8871- [`iter::empty`]
8872- [`ManuallyDrop::new`]
8873- [`ManuallyDrop::into_inner`]
8874- [`RangeInclusive::start`]
8875- [`RangeInclusive::end`]
8876- [`NonNull::as_ptr`]
8877- [`slice::as_ptr`]
8878- [`str::as_ptr`]
8879- [`Duration::as_secs`]
8880- [`Duration::subsec_millis`]
8881- [`Duration::subsec_micros`]
8882- [`Duration::subsec_nanos`]
8883- [`CStr::as_ptr`]
8884- [`Ipv4Addr::is_unspecified`]
8885- [`Ipv6Addr::new`]
8886- [`Ipv6Addr::octets`]
8887
8888Stabilized APIs
8889---------------
8890- [`i8::to_be_bytes`]
8891- [`i8::to_le_bytes`]
8892- [`i8::to_ne_bytes`]
8893- [`i8::from_be_bytes`]
8894- [`i8::from_le_bytes`]
8895- [`i8::from_ne_bytes`]
8896- [`i16::to_be_bytes`]
8897- [`i16::to_le_bytes`]
8898- [`i16::to_ne_bytes`]
8899- [`i16::from_be_bytes`]
8900- [`i16::from_le_bytes`]
8901- [`i16::from_ne_bytes`]
8902- [`i32::to_be_bytes`]
8903- [`i32::to_le_bytes`]
8904- [`i32::to_ne_bytes`]
8905- [`i32::from_be_bytes`]
8906- [`i32::from_le_bytes`]
8907- [`i32::from_ne_bytes`]
8908- [`i64::to_be_bytes`]
8909- [`i64::to_le_bytes`]
8910- [`i64::to_ne_bytes`]
8911- [`i64::from_be_bytes`]
8912- [`i64::from_le_bytes`]
8913- [`i64::from_ne_bytes`]
8914- [`i128::to_be_bytes`]
8915- [`i128::to_le_bytes`]
8916- [`i128::to_ne_bytes`]
8917- [`i128::from_be_bytes`]
8918- [`i128::from_le_bytes`]
8919- [`i128::from_ne_bytes`]
8920- [`isize::to_be_bytes`]
8921- [`isize::to_le_bytes`]
8922- [`isize::to_ne_bytes`]
8923- [`isize::from_be_bytes`]
8924- [`isize::from_le_bytes`]
8925- [`isize::from_ne_bytes`]
8926- [`u8::to_be_bytes`]
8927- [`u8::to_le_bytes`]
8928- [`u8::to_ne_bytes`]
8929- [`u8::from_be_bytes`]
8930- [`u8::from_le_bytes`]
8931- [`u8::from_ne_bytes`]
8932- [`u16::to_be_bytes`]
8933- [`u16::to_le_bytes`]
8934- [`u16::to_ne_bytes`]
8935- [`u16::from_be_bytes`]
8936- [`u16::from_le_bytes`]
8937- [`u16::from_ne_bytes`]
8938- [`u32::to_be_bytes`]
8939- [`u32::to_le_bytes`]
8940- [`u32::to_ne_bytes`]
8941- [`u32::from_be_bytes`]
8942- [`u32::from_le_bytes`]
8943- [`u32::from_ne_bytes`]
8944- [`u64::to_be_bytes`]
8945- [`u64::to_le_bytes`]
8946- [`u64::to_ne_bytes`]
8947- [`u64::from_be_bytes`]
8948- [`u64::from_le_bytes`]
8949- [`u64::from_ne_bytes`]
8950- [`u128::to_be_bytes`]
8951- [`u128::to_le_bytes`]
8952- [`u128::to_ne_bytes`]
8953- [`u128::from_be_bytes`]
8954- [`u128::from_le_bytes`]
8955- [`u128::from_ne_bytes`]
8956- [`usize::to_be_bytes`]
8957- [`usize::to_le_bytes`]
8958- [`usize::to_ne_bytes`]
8959- [`usize::from_be_bytes`]
8960- [`usize::from_le_bytes`]
8961- [`usize::from_ne_bytes`]
8962
8963Cargo
8964-----
8965- [You can now run `cargo c` as an alias for `cargo check`.][cargo/6218]
8966- [Usernames are now allowed in alt registry URLs.][cargo/6242]
8967
8968Misc
8969----
8970- [`libproc_macro` has been added to the `rust-src` distribution.][55280]
8971
8972Compatibility Notes
8973-------------------
8974- [The argument types for AVX's
8975 `_mm256_stream_si256`, `_mm256_stream_pd`, `_mm256_stream_ps`][55610] have
8976 been changed from `*const` to `*mut` as the previous implementation
8977 was unsound.
8978
8979
8980[55148]: https://github.com/rust-lang/rust/pull/55148/
8981[55238]: https://github.com/rust-lang/rust/pull/55238/
8982[55280]: https://github.com/rust-lang/rust/pull/55280/
8983[55610]: https://github.com/rust-lang/rust/pull/55610/
8984[55663]: https://github.com/rust-lang/rust/pull/55663/
8985[55702]: https://github.com/rust-lang/rust/pull/55702/
8986[55837]: https://github.com/rust-lang/rust/pull/55837/
8987[55843]: https://github.com/rust-lang/rust/pull/55843/
8988[56072]: https://github.com/rust-lang/rust/pull/56072/
8989[56245]: https://github.com/rust-lang/rust/pull/56245/
8990[56365]: https://github.com/rust-lang/rust/pull/56365/
8991[56366]: https://github.com/rust-lang/rust/pull/56366/
8992[56395]: https://github.com/rust-lang/rust/pull/56395/
8993[56759]: https://github.com/rust-lang/rust/pull/56759/
8994[cargo/6218]: https://github.com/rust-lang/cargo/pull/6218/
8995[cargo/6242]: https://github.com/rust-lang/cargo/pull/6242/
8996[`CStr::as_ptr`]: https://doc.rust-lang.org/std/ffi/struct.CStr.html#method.as_ptr
8997[`Cell::as_ptr`]: https://doc.rust-lang.org/std/cell/struct.Cell.html#method.as_ptr
8998[`Duration::as_secs`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.as_secs
8999[`Duration::subsec_micros`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.subsec_micros
9000[`Duration::subsec_millis`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.subsec_millis
9001[`Duration::subsec_nanos`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.subsec_nanos
9002[`Ipv4Addr::is_unspecified`]: https://doc.rust-lang.org/std/net/struct.Ipv4Addr.html#method.is_unspecified
9003[`Ipv6Addr::new`]: https://doc.rust-lang.org/std/net/struct.Ipv6Addr.html#method.new
9004[`Ipv6Addr::octets`]: https://doc.rust-lang.org/std/net/struct.Ipv6Addr.html#method.octets
9005[`ManuallyDrop::into_inner`]: https://doc.rust-lang.org/std/mem/struct.ManuallyDrop.html#method.into_inner
9006[`ManuallyDrop::new`]: https://doc.rust-lang.org/std/mem/struct.ManuallyDrop.html#method.new
9007[`NonNull::as_ptr`]: https://doc.rust-lang.org/std/ptr/struct.NonNull.html#method.as_ptr
9008[`RangeInclusive::end`]: https://doc.rust-lang.org/std/ops/struct.RangeInclusive.html#method.end
9009[`RangeInclusive::start`]: https://doc.rust-lang.org/std/ops/struct.RangeInclusive.html#method.start
9010[`UnsafeCell::get`]: https://doc.rust-lang.org/std/cell/struct.UnsafeCell.html#method.get
9011[`slice::as_ptr`]: https://doc.rust-lang.org/std/primitive.slice.html#method.as_ptr
9012[`char::is_ascii`]: https://doc.rust-lang.org/std/primitive.char.html#method.is_ascii
9013[`i128::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i128.html#method.from_be_bytes
9014[`i128::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i128.html#method.from_le_bytes
9015[`i128::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i128.html#method.from_ne_bytes
9016[`i128::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i128.html#method.to_be_bytes
9017[`i128::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i128.html#method.to_le_bytes
9018[`i128::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i128.html#method.to_ne_bytes
9019[`i16::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.from_be_bytes
9020[`i16::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.from_le_bytes
9021[`i16::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.from_ne_bytes
9022[`i16::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.to_be_bytes
9023[`i16::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.to_le_bytes
9024[`i16::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i16.html#method.to_ne_bytes
9025[`i32::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.from_be_bytes
9026[`i32::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.from_le_bytes
9027[`i32::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.from_ne_bytes
9028[`i32::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.to_be_bytes
9029[`i32::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.to_le_bytes
9030[`i32::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i32.html#method.to_ne_bytes
9031[`i64::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.from_be_bytes
9032[`i64::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.from_le_bytes
9033[`i64::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.from_ne_bytes
9034[`i64::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.to_be_bytes
9035[`i64::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.to_le_bytes
9036[`i64::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i64.html#method.to_ne_bytes
9037[`i8::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.from_be_bytes
9038[`i8::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.from_le_bytes
9039[`i8::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.from_ne_bytes
9040[`i8::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.to_be_bytes
9041[`i8::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.to_le_bytes
9042[`i8::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.i8.html#method.to_ne_bytes
9043[`isize::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.from_be_bytes
9044[`isize::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.from_le_bytes
9045[`isize::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.from_ne_bytes
9046[`isize::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.to_be_bytes
9047[`isize::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.to_le_bytes
9048[`isize::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.isize.html#method.to_ne_bytes
9049[`iter::empty`]: https://doc.rust-lang.org/std/iter/fn.empty.html
9050[`str::as_ptr`]: https://doc.rust-lang.org/std/primitive.str.html#method.as_ptr
9051[`u128::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u128.html#method.from_be_bytes
9052[`u128::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u128.html#method.from_le_bytes
9053[`u128::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u128.html#method.from_ne_bytes
9054[`u128::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u128.html#method.to_be_bytes
9055[`u128::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u128.html#method.to_le_bytes
9056[`u128::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u128.html#method.to_ne_bytes
9057[`u16::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.from_be_bytes
9058[`u16::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.from_le_bytes
9059[`u16::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.from_ne_bytes
9060[`u16::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.to_be_bytes
9061[`u16::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.to_le_bytes
9062[`u16::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u16.html#method.to_ne_bytes
9063[`u32::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.from_be_bytes
9064[`u32::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.from_le_bytes
9065[`u32::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.from_ne_bytes
9066[`u32::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.to_be_bytes
9067[`u32::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.to_le_bytes
9068[`u32::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u32.html#method.to_ne_bytes
9069[`u64::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.from_be_bytes
9070[`u64::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.from_le_bytes
9071[`u64::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.from_ne_bytes
9072[`u64::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.to_be_bytes
9073[`u64::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.to_le_bytes
9074[`u64::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u64.html#method.to_ne_bytes
9075[`u8::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.from_be_bytes
9076[`u8::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.from_le_bytes
9077[`u8::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.from_ne_bytes
9078[`u8::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.to_be_bytes
9079[`u8::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.to_le_bytes
9080[`u8::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.u8.html#method.to_ne_bytes
9081[`usize::from_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.from_be_bytes
9082[`usize::from_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.from_le_bytes
9083[`usize::from_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.from_ne_bytes
9084[`usize::to_be_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.to_be_bytes
9085[`usize::to_le_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.to_le_bytes
9086[`usize::to_ne_bytes`]: https://doc.rust-lang.org/stable/std/primitive.usize.html#method.to_ne_bytes
9087
9088
9089Version 1.31.1 (2018-12-20)
9090===========================
9091
9092- [Fix Rust failing to build on `powerpc-unknown-netbsd`][56562]
9093- [Fix broken go-to-definition in RLS][rls/1171]
9094- [Fix infinite loop on hover in RLS][rls/1170]
9095
9096[56562]: https://github.com/rust-lang/rust/pull/56562
9097[rls/1171]: https://github.com/rust-lang/rls/issues/1171
9098[rls/1170]: https://github.com/rust-lang/rls/pull/1170
9099
9100Version 1.31.0 (2018-12-06)
9101==========================
9102
9103Language
9104--------
9105- 🎉 [This version marks the release of the 2018 edition of Rust.][54057] 🎉
9106- [New lifetime elision rules now allow for eliding lifetimes in functions and
9107 impl headers.][54778] E.g. `impl<'a> Reader for BufReader<'a> {}` can now be
9108 `impl Reader for BufReader<'_> {}`. Lifetimes are still required to be defined
9109 in structs.
9110- [You can now define and use `const` functions.][54835] These are currently
9111 a strict minimal subset of the [const fn RFC][RFC-911]. Refer to the
9112 [language reference][const-reference] for what exactly is available.
9113- [You can now use tool lints, which allow you to scope lints from external
9114 tools using attributes.][54870] E.g. `#[allow(clippy::filter_map)]`.
9115- [`#[no_mangle]` and `#[export_name]` attributes can now be located anywhere in
9116 a crate, not just in exported functions.][54451]
9117- [You can now use parentheses in pattern matches.][54497]
9118
9119Compiler
9120--------
9121- [Updated musl to 1.1.20][54430]
9122
9123Libraries
9124---------
9125- [You can now convert `num::NonZero*` types to their raw equivalents using the
9126 `From` trait.][54240] E.g. `u8` now implements `From<NonZeroU8>`.
9127- [You can now convert a `&Option<T>` into `Option<&T>` and `&mut Option<T>`
9128 into `Option<&mut T>` using the `From` trait.][53218]
9129- [You can now multiply (`*`) a `time::Duration` by a `u32`.][52813]
9130
9131
9132Stabilized APIs
9133---------------
9134- [`slice::align_to`]
9135- [`slice::align_to_mut`]
9136- [`slice::chunks_exact`]
9137- [`slice::chunks_exact_mut`]
9138- [`slice::rchunks`]
9139- [`slice::rchunks_mut`]
9140- [`slice::rchunks_exact`]
9141- [`slice::rchunks_exact_mut`]
9142- [`Option::replace`]
9143
9144Cargo
9145-----
9146- [Cargo will now download crates in parallel using HTTP/2.][cargo/6005]
9147- [You can now rename packages in your Cargo.toml][cargo/6319] We have a guide
9148 on [how to use the `package` key in your dependencies.][cargo-rename-reference]
9149
9150[52813]: https://github.com/rust-lang/rust/pull/52813/
9151[53218]: https://github.com/rust-lang/rust/pull/53218/
9152[54057]: https://github.com/rust-lang/rust/pull/54057/
9153[54240]: https://github.com/rust-lang/rust/pull/54240/
9154[54430]: https://github.com/rust-lang/rust/pull/54430/
9155[54451]: https://github.com/rust-lang/rust/pull/54451/
9156[54497]: https://github.com/rust-lang/rust/pull/54497/
9157[54778]: https://github.com/rust-lang/rust/pull/54778/
9158[54835]: https://github.com/rust-lang/rust/pull/54835/
9159[54870]: https://github.com/rust-lang/rust/pull/54870/
9160[RFC-911]: https://github.com/rust-lang/rfcs/pull/911
9161[`Option::replace`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.replace
9162[`slice::align_to_mut`]: https://doc.rust-lang.org/std/primitive.slice.html#method.align_to_mut
9163[`slice::align_to`]: https://doc.rust-lang.org/std/primitive.slice.html#method.align_to
9164[`slice::chunks_exact_mut`]: https://doc.rust-lang.org/std/primitive.slice.html#method.chunks_exact_mut
9165[`slice::chunks_exact`]: https://doc.rust-lang.org/std/primitive.slice.html#method.chunks_exact
9166[`slice::rchunks_exact_mut`]: https://doc.rust-lang.org/std/primitive.slice.html#method.rchunks_mut
9167[`slice::rchunks_exact`]: https://doc.rust-lang.org/std/primitive.slice.html#method.rchunks_exact
9168[`slice::rchunks_mut`]: https://doc.rust-lang.org/std/primitive.slice.html#method.rchunks_mut
9169[`slice::rchunks`]: https://doc.rust-lang.org/std/primitive.slice.html#method.rchunks
9170[cargo/6005]: https://github.com/rust-lang/cargo/pull/6005/
9171[cargo/6319]: https://github.com/rust-lang/cargo/pull/6319/
9172[cargo-rename-reference]: https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#renaming-dependencies-in-cargotoml
9173[const-reference]: https://doc.rust-lang.org/reference/items/functions.html#const-functions
9174
9175Version 1.30.1 (2018-11-08)
9176===========================
9177
9178- [Fixed overflow ICE in rustdoc][54199]
9179- [Cap Cargo progress bar width at 60 in MSYS terminals][cargo/6122]
9180
9181[54199]: https://github.com/rust-lang/rust/pull/54199
9182[cargo/6122]: https://github.com/rust-lang/cargo/pull/6122
9183
9184Version 1.30.0 (2018-10-25)
9185==========================
9186
9187Language
9188--------
9189- [Procedural macros are now available.][52081] These kinds of macros allow for
9190 more powerful code generation. There is a [new chapter available][proc-macros]
9191 in the Rust Programming Language book that goes further in depth.
9192- [You can now use keywords as identifiers using the raw identifiers
9193 syntax (`r#`),][53236] e.g. `let r#for = true;`
9194- [Using anonymous parameters in traits is now deprecated with a warning and
9195 will be a hard error in the 2018 edition.][53272]
9196- [You can now use `crate` in paths.][54404] This allows you to refer to the
9197 crate root in the path, e.g. `use crate::foo;` refers to `foo` in `src/lib.rs`.
9198- [Using a external crate no longer requires being prefixed with `::`.][54404]
9199 Previously, using a external crate in a module without a use statement
9200 required `let json = ::serde_json::from_str(foo);` but can now be written
9201 as `let json = serde_json::from_str(foo);`.
9202- [You can now apply the `#[used]` attribute to static items to prevent the
9203 compiler from optimising them away, even if they appear to be unused,][51363]
9204 e.g. `#[used] static FOO: u32 = 1;`
9205- [You can now import and reexport macros from other crates with the `use`
9206 syntax.][50911] Macros exported with `#[macro_export]` are now placed into
9207 the root module of the crate. If your macro relies on calling other local
9208 macros, it is recommended to export with the
9209 `#[macro_export(local_inner_macros)]` attribute so users won't have to import
9210 those macros.
9211- [You can now catch visibility keywords (e.g. `pub`, `pub(crate)`) in macros
9212 using the `vis` specifier.][53370]
9213- [Non-macro attributes now allow all forms of literals, not just
9214 strings.][53044] Previously, you would write `#[attr("true")]`, and you can now
9215 write `#[attr(true)]`.
9216- [You can now specify a function to handle a panic in the Rust runtime with the
9217 `#[panic_handler]` attribute.][51366]
9218
9219Compiler
9220--------
9221- [Added the `riscv32imc-unknown-none-elf` target.][53822]
9222- [Added the `aarch64-unknown-netbsd` target][53165]
9223- [Upgraded to LLVM 8.][53611]
9224
9225Libraries
9226---------
9227- [`ManuallyDrop` now allows the inner type to be unsized.][53033]
9228
9229Stabilized APIs
9230---------------
9231- [`Ipv4Addr::BROADCAST`]
9232- [`Ipv4Addr::LOCALHOST`]
9233- [`Ipv4Addr::UNSPECIFIED`]
9234- [`Ipv6Addr::LOCALHOST`]
9235- [`Ipv6Addr::UNSPECIFIED`]
9236- [`Iterator::find_map`]
9237
9238 The following methods are replacement methods for `trim_left`, `trim_right`,
9239 `trim_left_matches`, and `trim_right_matches`, which will be deprecated
9240 in 1.33.0:
9241- [`str::trim_end_matches`]
9242- [`str::trim_end`]
9243- [`str::trim_start_matches`]
9244- [`str::trim_start`]
9245
9246Cargo
9247----
9248- [`cargo run` doesn't require specifying a package in workspaces.][cargo/5877]
9249- [`cargo doc` now supports `--message-format=json`.][cargo/5878] This is
9250 equivalent to calling `rustdoc --error-format=json`.
9251- [Cargo will now provide a progress bar for builds.][cargo/5995]
9252
9253Misc
9254----
9255- [`rustdoc` allows you to specify what edition to treat your code as with the
9256 `--edition` option.][54057]
9257- [`rustdoc` now has the `--color` (specify whether to output color) and
9258 `--error-format` (specify error format, e.g. `json`) options.][53003]
9259- [We now distribute a `rust-gdbgui` script that invokes `gdbgui` with Rust
9260 debug symbols.][53774]
9261- [Attributes from Rust tools such as `rustfmt` or `clippy` are now
9262 available,][53459] e.g. `#[rustfmt::skip]` will skip formatting the next item.
9263
9264[50911]: https://github.com/rust-lang/rust/pull/50911/
9265[51363]: https://github.com/rust-lang/rust/pull/51363/
9266[51366]: https://github.com/rust-lang/rust/pull/51366/
9267[52081]: https://github.com/rust-lang/rust/pull/52081/
9268[53003]: https://github.com/rust-lang/rust/pull/53003/
9269[53033]: https://github.com/rust-lang/rust/pull/53033/
9270[53044]: https://github.com/rust-lang/rust/pull/53044/
9271[53165]: https://github.com/rust-lang/rust/pull/53165/
9272[53611]: https://github.com/rust-lang/rust/pull/53611/
9273[53236]: https://github.com/rust-lang/rust/pull/53236/
9274[53272]: https://github.com/rust-lang/rust/pull/53272/
9275[53370]: https://github.com/rust-lang/rust/pull/53370/
9276[53459]: https://github.com/rust-lang/rust/pull/53459/
9277[53774]: https://github.com/rust-lang/rust/pull/53774/
9278[53822]: https://github.com/rust-lang/rust/pull/53822/
9279[54057]: https://github.com/rust-lang/rust/pull/54057/
9280[54404]: https://github.com/rust-lang/rust/pull/54404/
9281[cargo/5877]: https://github.com/rust-lang/cargo/pull/5877/
9282[cargo/5878]: https://github.com/rust-lang/cargo/pull/5878/
9283[cargo/5995]: https://github.com/rust-lang/cargo/pull/5995/
9284[proc-macros]: https://doc.rust-lang.org/nightly/book/2018-edition/ch19-06-macros.html
9285
9286[`Ipv4Addr::BROADCAST`]: https://doc.rust-lang.org/nightly/std/net/struct.Ipv4Addr.html#associatedconstant.BROADCAST
9287[`Ipv4Addr::LOCALHOST`]: https://doc.rust-lang.org/nightly/std/net/struct.Ipv4Addr.html#associatedconstant.LOCALHOST
9288[`Ipv4Addr::UNSPECIFIED`]: https://doc.rust-lang.org/nightly/std/net/struct.Ipv4Addr.html#associatedconstant.UNSPECIFIED
9289[`Ipv6Addr::LOCALHOST`]: https://doc.rust-lang.org/nightly/std/net/struct.Ipv6Addr.html#associatedconstant.LOCALHOST
9290[`Ipv6Addr::UNSPECIFIED`]: https://doc.rust-lang.org/nightly/std/net/struct.Ipv6Addr.html#associatedconstant.UNSPECIFIED
9291[`Iterator::find_map`]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.find_map
9292[`str::trim_end_matches`]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.trim_end_matches
9293[`str::trim_end`]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.trim_end
9294[`str::trim_start_matches`]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.trim_start_matches
9295[`str::trim_start`]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.trim_start
9296
9297
9298Version 1.29.2 (2018-10-11)
9299===========================
9300
9301- [Workaround for an aliasing-related LLVM bug, which caused miscompilation.][54639]
9302- The `rls-preview` component on the windows-gnu targets has been restored.
9303
9304[54639]: https://github.com/rust-lang/rust/pull/54639
9305
9306
9307Version 1.29.1 (2018-09-25)
9308===========================
9309
9310Security Notes
9311--------------
9312
9313- The standard library's `str::repeat` function contained an out of bounds write
9314 caused by an integer overflow. This has been fixed by deterministically
9315 panicking when an overflow happens.
9316
9317 Thank you to Scott McMurray for responsibly disclosing this vulnerability to
9318 us.
9319
9320
9321Version 1.29.0 (2018-09-13)
9322==========================
9323
9324Compiler
9325--------
9326- [Bumped minimum LLVM version to 5.0.][51899]
9327- [Added `powerpc64le-unknown-linux-musl` target.][51619]
9328- [Added `aarch64-unknown-hermit` and `x86_64-unknown-hermit` targets.][52861]
9329- [Upgraded to LLVM 7.][51966]
9330
9331Libraries
9332---------
9333- [`Once::call_once` no longer requires `Once` to be `'static`.][52239]
9334- [`BuildHasherDefault` now implements `PartialEq` and `Eq`.][52402]
9335- [`Box<CStr>`, `Box<OsStr>`, and `Box<Path>` now implement `Clone`.][51912]
9336- [Implemented `PartialEq<&str>` for `OsString` and `PartialEq<OsString>`
9337 for `&str`.][51178]
9338- [`Cell<T>` now allows `T` to be unsized.][50494]
9339- [`SocketAddr` is now stable on Redox.][52656]
9340
9341Stabilized APIs
9342---------------
9343- [`Arc::downcast`]
9344- [`Iterator::flatten`]
9345- [`Rc::downcast`]
9346
9347Cargo
9348-----
9349- [Cargo can silently fix some bad lockfiles.][cargo/5831] You can use
9350 `--locked` to disable this behavior.
9351- [`cargo-install` will now allow you to cross compile an install
9352 using `--target`.][cargo/5614]
9353- [Added the `cargo-fix` subcommand to automatically move project code from
9354 2015 edition to 2018.][cargo/5723]
9355- [`cargo doc` can now optionally document private types using the
9356 `--document-private-items` flag.][cargo/5543]
9357
9358Misc
9359----
9360- [`rustdoc` now has the `--cap-lints` option which demotes all lints above
9361 the specified level to that level.][52354] For example `--cap-lints warn`
9362 will demote `deny` and `forbid` lints to `warn`.
9363- [`rustc` and `rustdoc` will now have the exit code of `1` if compilation
9364 fails and `101` if there is a panic.][52197]
9365- [A preview of clippy has been made available through rustup.][51122]
9366 You can install the preview with `rustup component add clippy-preview`.
9367
9368Compatibility Notes
9369-------------------
9370- [`str::{slice_unchecked, slice_unchecked_mut}` are now deprecated.][51807]
9371 Use `str::get_unchecked(begin..end)` instead.
9372- [`std::env::home_dir` is now deprecated for its unintuitive behavior.][51656]
9373 Consider using the `home_dir` function from
9374 https://crates.io/crates/dirs instead.
9375- [`rustc` will no longer silently ignore invalid data in target spec.][52330]
9376- [`cfg` attributes and `--cfg` command line flags are now more
9377 strictly validated.][53893]
9378
9379[53893]: https://github.com/rust-lang/rust/pull/53893/
9380[52861]: https://github.com/rust-lang/rust/pull/52861/
9381[51966]: https://github.com/rust-lang/rust/pull/51966/
9382[52656]: https://github.com/rust-lang/rust/pull/52656/
9383[52239]: https://github.com/rust-lang/rust/pull/52239/
9384[52330]: https://github.com/rust-lang/rust/pull/52330/
9385[52354]: https://github.com/rust-lang/rust/pull/52354/
9386[52402]: https://github.com/rust-lang/rust/pull/52402/
9387[52197]: https://github.com/rust-lang/rust/pull/52197/
9388[51807]: https://github.com/rust-lang/rust/pull/51807/
9389[51899]: https://github.com/rust-lang/rust/pull/51899/
9390[51912]: https://github.com/rust-lang/rust/pull/51912/
9391[51619]: https://github.com/rust-lang/rust/pull/51619/
9392[51656]: https://github.com/rust-lang/rust/pull/51656/
9393[51178]: https://github.com/rust-lang/rust/pull/51178/
9394[51122]: https://github.com/rust-lang/rust/pull/51122
9395[50494]: https://github.com/rust-lang/rust/pull/50494/
9396[cargo/5543]: https://github.com/rust-lang/cargo/pull/5543
9397[cargo/5614]: https://github.com/rust-lang/cargo/pull/5614/
9398[cargo/5723]: https://github.com/rust-lang/cargo/pull/5723/
9399[cargo/5831]: https://github.com/rust-lang/cargo/pull/5831/
9400[`Arc::downcast`]: https://doc.rust-lang.org/std/sync/struct.Arc.html#method.downcast
9401[`Iterator::flatten`]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.flatten
9402[`Rc::downcast`]: https://doc.rust-lang.org/std/rc/struct.Rc.html#method.downcast
9403
9404
9405Version 1.28.0 (2018-08-02)
9406===========================
9407
9408Language
9409--------
9410- [The `#[repr(transparent)]` attribute is now stable.][51562] This attribute
9411 allows a Rust newtype wrapper (`struct NewType<T>(T);`) to be represented as
9412 the inner type across Foreign Function Interface (FFI) boundaries.
9413- [The keywords `pure`, `sizeof`, `alignof`, and `offsetof` have been unreserved
9414 and can now be used as identifiers.][51196]
9415- [The `GlobalAlloc` trait and `#[global_allocator]` attribute are now
9416 stable.][51241] This will allow users to specify a global allocator for
9417 their program.
9418- [Unit test functions marked with the `#[test]` attribute can now return
9419 `Result<(), E: Debug>` in addition to `()`.][51298]
9420- [The `lifetime` specifier for `macro_rules!` is now stable.][50385] This
9421 allows macros to easily target lifetimes.
9422
9423Compiler
9424--------
9425- [The `s` and `z` optimisation levels are now stable.][50265] These optimisations
9426 prioritise making smaller binary sizes. `z` is the same as `s` with the
9427 exception that it does not vectorise loops, which typically results in an even
9428 smaller binary.
9429- [The short error format is now stable.][49546] Specified with
9430 `--error-format=short` this option will provide a more compressed output of
9431 rust error messages.
9432- [Added a lint warning when you have duplicated `macro_export`s.][50143]
9433- [Reduced the number of allocations in the macro parser.][50855] This can
9434 improve compile times of macro heavy crates on average by 5%.
9435
9436Libraries
9437---------
9438- [Implemented `Default` for `&mut str`.][51306]
9439- [Implemented `From<bool>` for all integer and unsigned number types.][50554]
9440- [Implemented `Extend` for `()`.][50234]
9441- [The `Debug` implementation of `time::Duration` should now be more easily
9442 human readable.][50364] Previously a `Duration` of one second would printed as
9443 `Duration { secs: 1, nanos: 0 }` and will now be printed as `1s`.
9444- [Implemented `From<&String>` for `Cow<str>`, `From<&Vec<T>>` for `Cow<[T]>`,
9445 `From<Cow<CStr>>` for `CString`, `From<CString>, From<CStr>, From<&CString>`
9446 for `Cow<CStr>`, `From<OsString>, From<OsStr>, From<&OsString>` for
9447 `Cow<OsStr>`, `From<&PathBuf>` for `Cow<Path>`, and `From<Cow<Path>>`
9448 for `PathBuf`.][50170]
9449- [Implemented `Shl` and `Shr` for `Wrapping<u128>`
9450 and `Wrapping<i128>`.][50465]
9451- [`DirEntry::metadata` now uses `fstatat` instead of `lstat` when
9452 possible.][51050] This can provide up to a 40% speed increase.
9453- [Improved error messages when using `format!`.][50610]
9454
9455Stabilized APIs
9456---------------
9457- [`Iterator::step_by`]
9458- [`Path::ancestors`]
9459- [`SystemTime::UNIX_EPOCH`]
9460- [`alloc::GlobalAlloc`]
9461- [`alloc::Layout`]
9462- [`alloc::LayoutErr`]
9463- [`alloc::System`]
9464- [`alloc::alloc`]
9465- [`alloc::alloc_zeroed`]
9466- [`alloc::dealloc`]
9467- [`alloc::realloc`]
9468- [`alloc::handle_alloc_error`]
9469- [`btree_map::Entry::or_default`]
9470- [`fmt::Alignment`]
9471- [`hash_map::Entry::or_default`]
9472- [`iter::repeat_with`]
9473- [`num::NonZeroUsize`]
9474- [`num::NonZeroU128`]
9475- [`num::NonZeroU16`]
9476- [`num::NonZeroU32`]
9477- [`num::NonZeroU64`]
9478- [`num::NonZeroU8`]
9479- [`ops::RangeBounds`]
9480- [`slice::SliceIndex`]
9481- [`slice::from_mut`]
9482- [`slice::from_ref`]
9483- [`{Any + Send + Sync}::downcast_mut`]
9484- [`{Any + Send + Sync}::downcast_ref`]
9485- [`{Any + Send + Sync}::is`]
9486
9487Cargo
9488-----
9489- [Cargo will now no longer allow you to publish crates with build scripts that
9490 modify the `src` directory.][cargo/5584] The `src` directory in a crate should be
9491 considered to be immutable.
9492
9493Misc
9494----
9495- [The `suggestion_applicability` field in `rustc`'s json output is now
9496 stable.][50486] This will allow dev tools to check whether a code suggestion
9497 would apply to them.
9498
9499Compatibility Notes
9500-------------------
9501- [Rust will consider trait objects with duplicated constraints to be the same
9502 type as without the duplicated constraint.][51276] For example the below code will
9503 now fail to compile.
9504 ```rust
9505 trait Trait {}
9506
9507 impl Trait + Send {
9508 fn test(&self) { println!("one"); } //~ ERROR duplicate definitions with name `test`
9509 }
9510
9511 impl Trait + Send + Send {
9512 fn test(&self) { println!("two"); }
9513 }
9514 ```
9515
9516[49546]: https://github.com/rust-lang/rust/pull/49546/
9517[50143]: https://github.com/rust-lang/rust/pull/50143/
9518[50170]: https://github.com/rust-lang/rust/pull/50170/
9519[50234]: https://github.com/rust-lang/rust/pull/50234/
9520[50265]: https://github.com/rust-lang/rust/pull/50265/
9521[50364]: https://github.com/rust-lang/rust/pull/50364/
9522[50385]: https://github.com/rust-lang/rust/pull/50385/
9523[50465]: https://github.com/rust-lang/rust/pull/50465/
9524[50486]: https://github.com/rust-lang/rust/pull/50486/
9525[50554]: https://github.com/rust-lang/rust/pull/50554/
9526[50610]: https://github.com/rust-lang/rust/pull/50610/
9527[50855]: https://github.com/rust-lang/rust/pull/50855/
9528[51050]: https://github.com/rust-lang/rust/pull/51050/
9529[51196]: https://github.com/rust-lang/rust/pull/51196/
9530[51241]: https://github.com/rust-lang/rust/pull/51241/
9531[51276]: https://github.com/rust-lang/rust/pull/51276/
9532[51298]: https://github.com/rust-lang/rust/pull/51298/
9533[51306]: https://github.com/rust-lang/rust/pull/51306/
9534[51562]: https://github.com/rust-lang/rust/pull/51562/
9535[cargo/5584]: https://github.com/rust-lang/cargo/pull/5584/
9536[`Iterator::step_by`]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.step_by
9537[`Path::ancestors`]: https://doc.rust-lang.org/std/path/struct.Path.html#method.ancestors
9538[`SystemTime::UNIX_EPOCH`]: https://doc.rust-lang.org/std/time/struct.SystemTime.html#associatedconstant.UNIX_EPOCH
9539[`alloc::GlobalAlloc`]: https://doc.rust-lang.org/std/alloc/trait.GlobalAlloc.html
9540[`alloc::Layout`]: https://doc.rust-lang.org/std/alloc/struct.Layout.html
9541[`alloc::LayoutErr`]: https://doc.rust-lang.org/std/alloc/struct.LayoutErr.html
9542[`alloc::System`]: https://doc.rust-lang.org/std/alloc/struct.System.html
9543[`alloc::alloc`]: https://doc.rust-lang.org/std/alloc/fn.alloc.html
9544[`alloc::alloc_zeroed`]: https://doc.rust-lang.org/std/alloc/fn.alloc_zeroed.html
9545[`alloc::dealloc`]: https://doc.rust-lang.org/std/alloc/fn.dealloc.html
9546[`alloc::realloc`]: https://doc.rust-lang.org/std/alloc/fn.realloc.html
9547[`alloc::handle_alloc_error`]: https://doc.rust-lang.org/std/alloc/fn.handle_alloc_error.html
9548[`btree_map::Entry::or_default`]: https://doc.rust-lang.org/std/collections/btree_map/enum.Entry.html#method.or_default
9549[`fmt::Alignment`]: https://doc.rust-lang.org/std/fmt/enum.Alignment.html
9550[`hash_map::Entry::or_default`]: https://doc.rust-lang.org/std/collections/hash_map/enum.Entry.html#method.or_default
9551[`iter::repeat_with`]: https://doc.rust-lang.org/std/iter/fn.repeat_with.html
9552[`num::NonZeroUsize`]: https://doc.rust-lang.org/std/num/struct.NonZeroUsize.html
9553[`num::NonZeroU128`]: https://doc.rust-lang.org/std/num/struct.NonZeroU128.html
9554[`num::NonZeroU16`]: https://doc.rust-lang.org/std/num/struct.NonZeroU16.html
9555[`num::NonZeroU32`]: https://doc.rust-lang.org/std/num/struct.NonZeroU32.html
9556[`num::NonZeroU64`]: https://doc.rust-lang.org/std/num/struct.NonZeroU64.html
9557[`num::NonZeroU8`]: https://doc.rust-lang.org/std/num/struct.NonZeroU8.html
9558[`ops::RangeBounds`]: https://doc.rust-lang.org/std/ops/trait.RangeBounds.html
9559[`slice::SliceIndex`]: https://doc.rust-lang.org/std/slice/trait.SliceIndex.html
9560[`slice::from_mut`]: https://doc.rust-lang.org/std/slice/fn.from_mut.html
9561[`slice::from_ref`]: https://doc.rust-lang.org/std/slice/fn.from_ref.html
9562[`{Any + Send + Sync}::downcast_mut`]: https://doc.rust-lang.org/std/any/trait.Any.html#method.downcast_mut-2
9563[`{Any + Send + Sync}::downcast_ref`]: https://doc.rust-lang.org/std/any/trait.Any.html#method.downcast_ref-2
9564[`{Any + Send + Sync}::is`]: https://doc.rust-lang.org/std/any/trait.Any.html#method.is-2
9565
9566Version 1.27.2 (2018-07-20)
9567===========================
9568
9569Compatibility Notes
9570-------------------
9571
9572- The borrow checker was fixed to avoid potential unsoundness when using
9573 match ergonomics: [#52213][52213].
9574
9575[52213]: https://github.com/rust-lang/rust/issues/52213
9576
9577Version 1.27.1 (2018-07-10)
9578===========================
9579
9580Security Notes
9581--------------
9582
9583- rustdoc would execute plugins in the /tmp/rustdoc/plugins directory
9584 when running, which enabled executing code as some other user on a
9585 given machine. This release fixes that vulnerability; you can read
9586 more about this on the [blog][rustdoc-sec]. The associated CVE is [CVE-2018-1000622].
9587
9588 Thank you to Red Hat for responsibly disclosing this vulnerability to us.
9589
9590Compatibility Notes
9591-------------------
9592
9593- The borrow checker was fixed to avoid an additional potential unsoundness when using
9594 match ergonomics: [#51415][51415], [#49534][49534].
9595
9596[51415]: https://github.com/rust-lang/rust/issues/51415
9597[49534]: https://github.com/rust-lang/rust/issues/49534
9598[rustdoc-sec]: https://blog.rust-lang.org/2018/07/06/security-advisory-for-rustdoc.html
9599[CVE-2018-1000622]: https://cve.mitre.org/cgi-bin/cvename.cgi?name=%20CVE-2018-1000622
9600
9601Version 1.27.0 (2018-06-21)
9602==========================
9603
9604Language
9605--------
9606- [Removed 'proc' from the reserved keywords list.][49699] This allows `proc` to
9607 be used as an identifier.
9608- [The dyn syntax is now available.][49968] This syntax is equivalent to the
9609 bare `Trait` syntax, and should make it clearer when being used in tandem with
9610 `impl Trait` because it is equivalent to the following syntax:
9611 `&Trait == &dyn Trait`, `&mut Trait == &mut dyn Trait`, and
9612 `Box<Trait> == Box<dyn Trait>`.
9613- [Attributes on generic parameters such as types and lifetimes are
9614 now stable.][48851] e.g.
9615 `fn foo<#[lifetime_attr] 'a, #[type_attr] T: 'a>() {}`
9616- [The `#[must_use]` attribute can now also be used on functions as well as
9617 types.][48925] It provides a lint that by default warns users when the
9618 value returned by a function has not been used.
9619
9620Compiler
9621--------
9622- [Added the `armv5te-unknown-linux-musleabi` target.][50423]
9623
9624Libraries
9625---------
9626- [SIMD (Single Instruction Multiple Data) on x86/x86_64 is now stable.][49664]
9627 This includes [`arch::x86`] & [`arch::x86_64`] modules which contain
9628 SIMD intrinsics, a new macro called `is_x86_feature_detected!`, the
9629 `#[target_feature(enable="")]` attribute, and adding `target_feature = ""` to
9630 the `cfg` attribute.
9631- [A lot of methods for `[u8]`, `f32`, and `f64` previously only available in
9632 std are now available in core.][49896]
9633- [The generic `Rhs` type parameter on `ops::{Shl, ShlAssign, Shr}` now defaults
9634 to `Self`.][49630]
9635- [`std::str::replace` now has the `#[must_use]` attribute][50177] to clarify
9636 that the operation isn't done in place.
9637- [`Clone::clone`, `Iterator::collect`, and `ToOwned::to_owned` now have
9638 the `#[must_use]` attribute][49533] to warn about unused potentially
9639 expensive allocations.
9640
9641Stabilized APIs
9642---------------
9643- [`DoubleEndedIterator::rfind`]
9644- [`DoubleEndedIterator::rfold`]
9645- [`DoubleEndedIterator::try_rfold`]
9646- [`Duration::from_micros`]
9647- [`Duration::from_nanos`]
9648- [`Duration::subsec_micros`]
9649- [`Duration::subsec_millis`]
9650- [`HashMap::remove_entry`]
9651- [`Iterator::try_fold`]
9652- [`Iterator::try_for_each`]
9653- [`NonNull::cast`]
9654- [`Option::filter`]
9655- [`String::replace_range`]
9656- [`Take::set_limit`]
9657- [`hint::unreachable_unchecked`]
9658- [`os::unix::process::parent_id`]
9659- [`ptr::swap_nonoverlapping`]
9660- [`slice::rsplit_mut`]
9661- [`slice::rsplit`]
9662- [`slice::swap_with_slice`]
9663
9664Cargo
9665-----
9666- [`cargo-metadata` now includes `authors`, `categories`, `keywords`,
9667 `readme`, and `repository` fields.][cargo/5386]
9668- [`cargo-metadata` now includes a package's `metadata` table.][cargo/5360]
9669- [Added the `--target-dir` optional argument.][cargo/5393] This allows you to specify
9670 a different directory than `target` for placing compilation artifacts.
9671- [Cargo will be adding automatic target inference for binaries, benchmarks,
9672 examples, and tests in the Rust 2018 edition.][cargo/5335] If your project specifies
9673 specific targets, e.g. using `[[bin]]`, and have other binaries in locations
9674 where cargo would infer a binary, Cargo will produce a warning. You can
9675 disable this feature ahead of time by setting any of the following to false:
9676 `autobins`, `autobenches`, `autoexamples`, `autotests`.
9677- [Cargo will now cache compiler information.][cargo/5359] This can be disabled by
9678 setting `CARGO_CACHE_RUSTC_INFO=0` in your environment.
9679
9680Misc
9681----
9682- [Added “The Rustc book” into the official documentation.][49707]
9683 [“The Rustc book”] documents and teaches how to use the rustc compiler.
9684- [All books available on `doc.rust-lang.org` are now searchable.][49623]
9685
9686Compatibility Notes
9687-------------------
9688- [Calling a `CharExt` or `StrExt` method directly on core will no longer
9689 work.][49896] e.g. `::core::prelude::v1::StrExt::is_empty("")` will not
9690 compile, `"".is_empty()` will still compile.
9691- [`Debug` output on `atomic::{AtomicBool, AtomicIsize, AtomicPtr, AtomicUsize}`
9692 will only print the inner type.][48553] E.g.
9693 `print!("{:?}", AtomicBool::new(true))` will print `true`,
9694 not `AtomicBool(true)`.
9695- [The maximum number for `repr(align(N))` is now 2²⁹.][50378] Previously you
9696 could enter higher numbers but they were not supported by LLVM. Up to 512MB
9697 alignment should cover all use cases.
9698- The `.description()` method on the `std::error::Error` trait
9699 [has been soft-deprecated][50163]. It is no longer required to implement it.
9700
9701[48553]: https://github.com/rust-lang/rust/pull/48553/
9702[48851]: https://github.com/rust-lang/rust/pull/48851/
9703[48925]: https://github.com/rust-lang/rust/pull/48925/
9704[49533]: https://github.com/rust-lang/rust/pull/49533/
9705[49623]: https://github.com/rust-lang/rust/pull/49623/
9706[49630]: https://github.com/rust-lang/rust/pull/49630/
9707[49664]: https://github.com/rust-lang/rust/pull/49664/
9708[49699]: https://github.com/rust-lang/rust/pull/49699/
9709[49707]: https://github.com/rust-lang/rust/pull/49707/
9710[49896]: https://github.com/rust-lang/rust/pull/49896/
9711[49968]: https://github.com/rust-lang/rust/pull/49968/
9712[50163]: https://github.com/rust-lang/rust/pull/50163
9713[50177]: https://github.com/rust-lang/rust/pull/50177/
9714[50378]: https://github.com/rust-lang/rust/pull/50378/
9715[50423]: https://github.com/rust-lang/rust/pull/50423/
9716[cargo/5335]: https://github.com/rust-lang/cargo/pull/5335/
9717[cargo/5359]: https://github.com/rust-lang/cargo/pull/5359/
9718[cargo/5360]: https://github.com/rust-lang/cargo/pull/5360/
9719[cargo/5386]: https://github.com/rust-lang/cargo/pull/5386/
9720[cargo/5393]: https://github.com/rust-lang/cargo/pull/5393/
9721[`DoubleEndedIterator::rfind`]: https://doc.rust-lang.org/std/iter/trait.DoubleEndedIterator.html#method.rfind
9722[`DoubleEndedIterator::rfold`]: https://doc.rust-lang.org/std/iter/trait.DoubleEndedIterator.html#method.rfold
9723[`DoubleEndedIterator::try_rfold`]: https://doc.rust-lang.org/std/iter/trait.DoubleEndedIterator.html#method.try_rfold
9724[`Duration::from_micros`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.from_micros
9725[`Duration::from_nanos`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.from_nanos
9726[`Duration::subsec_micros`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.subsec_micros
9727[`Duration::subsec_millis`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.subsec_millis
9728[`HashMap::remove_entry`]: https://doc.rust-lang.org/std/collections/struct.HashMap.html#method.remove_entry
9729[`Iterator::try_fold`]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.try_fold
9730[`Iterator::try_for_each`]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.try_for_each
9731[`NonNull::cast`]: https://doc.rust-lang.org/std/ptr/struct.NonNull.html#method.cast
9732[`Option::filter`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.filter
9733[`String::replace_range`]: https://doc.rust-lang.org/std/string/struct.String.html#method.replace_range
9734[`Take::set_limit`]: https://doc.rust-lang.org/std/io/struct.Take.html#method.set_limit
9735[`hint::unreachable_unchecked`]: https://doc.rust-lang.org/std/hint/fn.unreachable_unchecked.html
9736[`os::unix::process::parent_id`]: https://doc.rust-lang.org/std/os/unix/process/fn.parent_id.html
9737[`process::id`]: https://doc.rust-lang.org/std/process/fn.id.html
9738[`ptr::swap_nonoverlapping`]: https://doc.rust-lang.org/std/ptr/fn.swap_nonoverlapping.html
9739[`slice::rsplit_mut`]: https://doc.rust-lang.org/std/primitive.slice.html#method.rsplit_mut
9740[`slice::rsplit`]: https://doc.rust-lang.org/std/primitive.slice.html#method.rsplit
9741[`slice::swap_with_slice`]: https://doc.rust-lang.org/std/primitive.slice.html#method.swap_with_slice
9742[`arch::x86_64`]: https://doc.rust-lang.org/std/arch/x86_64/index.html
9743[`arch::x86`]: https://doc.rust-lang.org/std/arch/x86/index.html
9744[“The Rustc book”]: https://doc.rust-lang.org/rustc
9745
9746
9747Version 1.26.2 (2018-06-05)
9748==========================
9749
9750Compatibility Notes
9751-------------------
9752
9753- [The borrow checker was fixed to avoid unsoundness when using match ergonomics.][51117]
9754
9755[51117]: https://github.com/rust-lang/rust/issues/51117
9756
9757
9758Version 1.26.1 (2018-05-29)
9759==========================
9760
9761Tools
9762-----
9763
9764- [RLS now works on Windows.][50646]
9765- [Rustfmt stopped badly formatting text in some cases.][rustfmt/2695]
9766
9767
9768Compatibility Notes
9769--------
9770
9771- [`fn main() -> impl Trait` no longer works for non-Termination
9772 trait.][50656]
9773 This reverts an accidental stabilization.
9774- [`NaN > NaN` no longer returns true in const-fn contexts.][50812]
9775- [Prohibit using turbofish for `impl Trait` in method arguments.][50950]
9776
9777[50646]: https://github.com/rust-lang/rust/issues/50646
9778[50656]: https://github.com/rust-lang/rust/pull/50656
9779[50812]: https://github.com/rust-lang/rust/pull/50812
9780[50950]: https://github.com/rust-lang/rust/issues/50950
9781[rustfmt/2695]: https://github.com/rust-lang-nursery/rustfmt/issues/2695
9782
9783Version 1.26.0 (2018-05-10)
9784==========================
9785
9786Language
9787--------
9788- [Closures now implement `Copy` and/or `Clone` if all captured variables
9789 implement either or both traits.][49299]
9790- [The inclusive range syntax e.g. `for x in 0..=10` is now stable.][47813]
9791- [The `'_` lifetime is now stable. The underscore lifetime can be used anywhere a
9792 lifetime can be elided.][49458]
9793- [`impl Trait` is now stable allowing you to have abstract types in returns
9794 or in function parameters.][49255] E.g. `fn foo() -> impl Iterator<Item=u8>` or
9795 `fn open(path: impl AsRef<Path>)`.
9796- [Pattern matching will now automatically apply dereferences.][49394]
9797- [128-bit integers in the form of `u128` and `i128` are now stable.][49101]
9798- [`main` can now return `Result<(), E: Debug>`][49162] in addition to `()`.
9799- [A lot of operations are now available in a const context.][46882] E.g. You
9800 can now index into constant arrays, reference and dereference into constants,
9801 and use tuple struct constructors.
9802- [Fixed entry slice patterns are now stable.][48516] E.g.
9803 ```rust
9804 let points = [1, 2, 3, 4];
9805 match points {
9806 [1, 2, 3, 4] => println!("All points were sequential."),
9807 _ => println!("Not all points were sequential."),
9808 }
9809 ```
9810
9811
9812Compiler
9813--------
9814- [LLD is now used as the default linker for `wasm32-unknown-unknown`.][48125]
9815- [Fixed exponential projection complexity on nested types.][48296]
9816 This can provide up to a ~12% reduction in compile times for certain crates.
9817- [Added the `--remap-path-prefix` option to rustc.][48359] Allowing you
9818 to remap path prefixes outputted by the compiler.
9819- [Added `powerpc-unknown-netbsd` target.][48281]
9820
9821Libraries
9822---------
9823- [Implemented `From<u16> for usize` & `From<{u8, i16}> for isize`.][49305]
9824- [Added hexadecimal formatting for integers with fmt::Debug][48978]
9825 e.g. `assert!(format!("{:02x?}", b"Foo\0") == "[46, 6f, 6f, 00]")`
9826- [Implemented `Default, Hash` for `cmp::Reverse`.][48628]
9827- [Optimized `str::repeat` being 8x faster in large cases.][48657]
9828- [`ascii::escape_default` is now available in libcore.][48735]
9829- [Trailing commas are now supported in std and core macros.][48056]
9830- [Implemented `Copy, Clone` for `cmp::Reverse`][47379]
9831- [Implemented `Clone` for `char::{ToLowercase, ToUppercase}`.][48629]
9832
9833Stabilized APIs
9834---------------
9835- [`*const T::add`]
9836- [`*const T::copy_to_nonoverlapping`]
9837- [`*const T::copy_to`]
9838- [`*const T::read_unaligned`]
9839- [`*const T::read_volatile`]
9840- [`*const T::read`]
9841- [`*const T::sub`]
9842- [`*const T::wrapping_add`]
9843- [`*const T::wrapping_sub`]
9844- [`*mut T::add`]
9845- [`*mut T::copy_to_nonoverlapping`]
9846- [`*mut T::copy_to`]
9847- [`*mut T::read_unaligned`]
9848- [`*mut T::read_volatile`]
9849- [`*mut T::read`]
9850- [`*mut T::replace`]
9851- [`*mut T::sub`]
9852- [`*mut T::swap`]
9853- [`*mut T::wrapping_add`]
9854- [`*mut T::wrapping_sub`]
9855- [`*mut T::write_bytes`]
9856- [`*mut T::write_unaligned`]
9857- [`*mut T::write_volatile`]
9858- [`*mut T::write`]
9859- [`Box::leak`]
9860- [`FromUtf8Error::as_bytes`]
9861- [`LocalKey::try_with`]
9862- [`Option::cloned`]
9863- [`btree_map::Entry::and_modify`]
9864- [`fs::read_to_string`]
9865- [`fs::read`]
9866- [`fs::write`]
9867- [`hash_map::Entry::and_modify`]
9868- [`iter::FusedIterator`]
9869- [`ops::RangeInclusive`]
9870- [`ops::RangeToInclusive`]
9871- [`process::id`]
9872- [`slice::rotate_left`]
9873- [`slice::rotate_right`]
9874- [`String::retain`]
9875
9876
9877Cargo
9878-----
9879- [Cargo will now output path to custom commands when `-v` is
9880 passed with `--list`][cargo/5041]
9881- [The Cargo binary version is now the same as the Rust version][cargo/5083]
9882
9883Misc
9884----
9885- [The second edition of "The Rust Programming Language" book is now recommended
9886 over the first.][48404]
9887
9888Compatibility Notes
9889-------------------
9890
9891- [aliasing a `Fn` trait as `dyn` no longer works.][48481] E.g. the following
9892 syntax is now invalid.
9893 ```
9894 use std::ops::Fn as dyn;
9895 fn g(_: Box<dyn(std::fmt::Debug)>) {}
9896 ```
9897- [The result of dereferences are no longer promoted to `'static`.][47408]
9898 e.g.
9899 ```rust
9900 fn main() {
9901 const PAIR: &(i32, i32) = &(0, 1);
9902 let _reversed_pair: &'static _ = &(PAIR.1, PAIR.0); // Doesn't work
9903 }
9904 ```
9905- [Deprecate `AsciiExt` trait in favor of inherent methods.][49109]
9906- [`".e0"` will now no longer parse as `0.0` and will instead cause
9907 an error.][48235]
9908- [Removed hoedown from rustdoc.][48274]
9909- [Bounds on higher-kinded lifetimes a hard error.][48326]
9910
9911[46882]: https://github.com/rust-lang/rust/pull/46882
9912[47379]: https://github.com/rust-lang/rust/pull/47379
9913[47408]: https://github.com/rust-lang/rust/pull/47408
9914[47813]: https://github.com/rust-lang/rust/pull/47813
9915[48056]: https://github.com/rust-lang/rust/pull/48056
9916[48125]: https://github.com/rust-lang/rust/pull/48125
9917[48235]: https://github.com/rust-lang/rust/pull/48235
9918[48274]: https://github.com/rust-lang/rust/pull/48274
9919[48281]: https://github.com/rust-lang/rust/pull/48281
9920[48296]: https://github.com/rust-lang/rust/pull/48296
9921[48326]: https://github.com/rust-lang/rust/pull/48326
9922[48359]: https://github.com/rust-lang/rust/pull/48359
9923[48404]: https://github.com/rust-lang/rust/pull/48404
9924[48481]: https://github.com/rust-lang/rust/pull/48481
9925[48516]: https://github.com/rust-lang/rust/pull/48516
9926[48628]: https://github.com/rust-lang/rust/pull/48628
9927[48629]: https://github.com/rust-lang/rust/pull/48629
9928[48657]: https://github.com/rust-lang/rust/pull/48657
9929[48735]: https://github.com/rust-lang/rust/pull/48735
9930[48978]: https://github.com/rust-lang/rust/pull/48978
9931[49101]: https://github.com/rust-lang/rust/pull/49101
9932[49109]: https://github.com/rust-lang/rust/pull/49109
9933[49162]: https://github.com/rust-lang/rust/pull/49162
9934[49255]: https://github.com/rust-lang/rust/pull/49255
9935[49299]: https://github.com/rust-lang/rust/pull/49299
9936[49305]: https://github.com/rust-lang/rust/pull/49305
9937[49394]: https://github.com/rust-lang/rust/pull/49394
9938[49458]: https://github.com/rust-lang/rust/pull/49458
9939[`*const T::add`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.add
9940[`*const T::copy_to_nonoverlapping`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.copy_to_nonoverlapping
9941[`*const T::copy_to`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.copy_to
9942[`*const T::read_unaligned`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.read_unaligned
9943[`*const T::read_volatile`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.read_volatile
9944[`*const T::read`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.read
9945[`*const T::sub`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.sub
9946[`*const T::wrapping_add`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.wrapping_add
9947[`*const T::wrapping_sub`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.wrapping_sub
9948[`*mut T::add`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.add-1
9949[`*mut T::copy_to_nonoverlapping`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.copy_to_nonoverlapping-1
9950[`*mut T::copy_to`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.copy_to-1
9951[`*mut T::read_unaligned`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.read_unaligned-1
9952[`*mut T::read_volatile`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.read_volatile-1
9953[`*mut T::read`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.read-1
9954[`*mut T::replace`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.replace
9955[`*mut T::sub`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.sub-1
9956[`*mut T::swap`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.swap
9957[`*mut T::wrapping_add`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.wrapping_add-1
9958[`*mut T::wrapping_sub`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.wrapping_sub-1
9959[`*mut T::write_bytes`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.write_bytes
9960[`*mut T::write_unaligned`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.write_unaligned
9961[`*mut T::write_volatile`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.write_volatile
9962[`*mut T::write`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.write
9963[`Box::leak`]: https://doc.rust-lang.org/std/boxed/struct.Box.html#method.leak
9964[`FromUtf8Error::as_bytes`]: https://doc.rust-lang.org/std/string/struct.FromUtf8Error.html#method.as_bytes
9965[`LocalKey::try_with`]: https://doc.rust-lang.org/std/thread/struct.LocalKey.html#method.try_with
9966[`Option::cloned`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.cloned
9967[`btree_map::Entry::and_modify`]: https://doc.rust-lang.org/std/collections/btree_map/enum.Entry.html#method.and_modify
9968[`fs::read_to_string`]: https://doc.rust-lang.org/std/fs/fn.read_to_string.html
9969[`fs::read`]: https://doc.rust-lang.org/std/fs/fn.read.html
9970[`fs::write`]: https://doc.rust-lang.org/std/fs/fn.write.html
9971[`hash_map::Entry::and_modify`]: https://doc.rust-lang.org/std/collections/hash_map/enum.Entry.html#method.and_modify
9972[`iter::FusedIterator`]: https://doc.rust-lang.org/std/iter/trait.FusedIterator.html
9973[`ops::RangeInclusive`]: https://doc.rust-lang.org/std/ops/struct.RangeInclusive.html
9974[`ops::RangeToInclusive`]: https://doc.rust-lang.org/std/ops/struct.RangeToInclusive.html
9975[`process::id`]: https://doc.rust-lang.org/std/process/fn.id.html
9976[`slice::rotate_left`]: https://doc.rust-lang.org/std/primitive.slice.html#method.rotate_left
9977[`slice::rotate_right`]: https://doc.rust-lang.org/std/primitive.slice.html#method.rotate_right
9978[`String::retain`]: https://doc.rust-lang.org/std/string/struct.String.html#method.retain
9979[cargo/5041]: https://github.com/rust-lang/cargo/pull/5041
9980[cargo/5083]: https://github.com/rust-lang/cargo/pull/5083
9981
9982
9983Version 1.25.0 (2018-03-29)
9984==========================
9985
9986Language
9987--------
9988- [The `#[repr(align(x))]` attribute is now stable.][47006] [RFC 1358]
9989- [You can now use nested groups of imports.][47948]
9990 e.g. `use std::{fs::File, io::Read, path::{Path, PathBuf}};`
9991- [You can now have `|` at the start of a match arm.][47947] e.g.
9992```rust
9993enum Foo { A, B, C }
9994
9995fn main() {
9996 let x = Foo::A;
9997 match x {
9998 | Foo::A
9999 | Foo::B => println!("AB"),
10000 | Foo::C => println!("C"),
10001 }
10002}
10003```
10004
10005Compiler
10006--------
10007- [Upgraded to LLVM 6.][47828]
10008- [Added `-C lto=val` option.][47521]
10009- [Added `i586-unknown-linux-musl` target][47282]
10010
10011Libraries
10012---------
10013- [Impl Send for `process::Command` on Unix.][47760]
10014- [Impl PartialEq and Eq for `ParseCharError`.][47790]
10015- [`UnsafeCell::into_inner` is now safe.][47204]
10016- [Implement libstd for CloudABI.][47268]
10017- [`Float::{from_bits, to_bits}` is now available in libcore.][46931]
10018- [Implement `AsRef<Path>` for Component][46985]
10019- [Implemented `Write` for `Cursor<&mut Vec<u8>>`][46830]
10020- [Moved `Duration` to libcore.][46666]
10021
10022Stabilized APIs
10023---------------
10024- [`Location::column`]
10025- [`ptr::NonNull`]
10026
10027The following functions can now be used in a constant expression.
10028eg. `static MINUTE: Duration = Duration::from_secs(60);`
10029- [`Duration::new`][47300]
10030- [`Duration::from_secs`][47300]
10031- [`Duration::from_millis`][47300]
10032
10033Cargo
10034-----
10035- [`cargo new` no longer removes `rust` or `rs` prefixes/suffixes.][cargo/5013]
10036- [`cargo new` now defaults to creating a binary crate, instead of a
10037 library crate.][cargo/5029]
10038
10039Misc
10040----
10041- [Rust by example is now shipped with new releases][46196]
10042
10043Compatibility Notes
10044-------------------
10045- [Deprecated `net::lookup_host`.][47510]
10046- [`rustdoc` has switched to pulldown as the default markdown renderer.][47398]
10047- The borrow checker was sometimes incorrectly permitting overlapping borrows
10048 around indexing operations (see [#47349][47349]). This has been fixed (which also
10049 enabled some correct code that used to cause errors (e.g. [#33903][33903] and [#46095][46095]).
10050- [Removed deprecated unstable attribute `#[simd]`.][47251]
10051
10052[33903]: https://github.com/rust-lang/rust/pull/33903
10053[47947]: https://github.com/rust-lang/rust/pull/47947
10054[47948]: https://github.com/rust-lang/rust/pull/47948
10055[47760]: https://github.com/rust-lang/rust/pull/47760
10056[47790]: https://github.com/rust-lang/rust/pull/47790
10057[47828]: https://github.com/rust-lang/rust/pull/47828
10058[47398]: https://github.com/rust-lang/rust/pull/47398
10059[47510]: https://github.com/rust-lang/rust/pull/47510
10060[47521]: https://github.com/rust-lang/rust/pull/47521
10061[47204]: https://github.com/rust-lang/rust/pull/47204
10062[47251]: https://github.com/rust-lang/rust/pull/47251
10063[47268]: https://github.com/rust-lang/rust/pull/47268
10064[47282]: https://github.com/rust-lang/rust/pull/47282
10065[47300]: https://github.com/rust-lang/rust/pull/47300
10066[47349]: https://github.com/rust-lang/rust/pull/47349
10067[46931]: https://github.com/rust-lang/rust/pull/46931
10068[46985]: https://github.com/rust-lang/rust/pull/46985
10069[47006]: https://github.com/rust-lang/rust/pull/47006
10070[46830]: https://github.com/rust-lang/rust/pull/46830
10071[46095]: https://github.com/rust-lang/rust/pull/46095
10072[46666]: https://github.com/rust-lang/rust/pull/46666
10073[46196]: https://github.com/rust-lang/rust/pull/46196
10074[cargo/5013]: https://github.com/rust-lang/cargo/pull/5013
10075[cargo/5029]: https://github.com/rust-lang/cargo/pull/5029
10076[RFC 1358]: https://github.com/rust-lang/rfcs/pull/1358
10077[`Location::column`]: https://doc.rust-lang.org/std/panic/struct.Location.html#method.column
10078[`ptr::NonNull`]: https://doc.rust-lang.org/std/ptr/struct.NonNull.html
10079
10080
10081Version 1.24.1 (2018-03-01)
10082==========================
10083
10084 - [Do not abort when unwinding through FFI][48251]
10085 - [Emit UTF-16 files for linker arguments on Windows][48318]
10086 - [Make the error index generator work again][48308]
10087 - [Cargo will warn on Windows 7 if an update is needed][cargo/5069].
10088
10089[48251]: https://github.com/rust-lang/rust/issues/48251
10090[48308]: https://github.com/rust-lang/rust/issues/48308
10091[48318]: https://github.com/rust-lang/rust/issues/48318
10092[cargo/5069]: https://github.com/rust-lang/cargo/pull/5069
10093
10094
10095Version 1.24.0 (2018-02-15)
10096==========================
10097
10098Language
10099--------
10100- [External `sysv64` ffi is now available.][46528]
10101 eg. `extern "sysv64" fn foo () {}`
10102
10103Compiler
10104--------
10105- [rustc now uses 16 codegen units by default for release builds.][46910]
10106 For the fastest builds, utilize `codegen-units=1`.
10107- [Added `armv4t-unknown-linux-gnueabi` target.][47018]
10108- [Add `aarch64-unknown-openbsd` support][46760]
10109
10110Libraries
10111---------
10112- [`str::find::<char>` now uses memchr.][46735] This should lead to a 10x
10113 improvement in performance in the majority of cases.
10114- [`OsStr`'s `Debug` implementation is now lossless and consistent
10115 with Windows.][46798]
10116- [`time::{SystemTime, Instant}` now implement `Hash`.][46828]
10117- [impl `From<bool>` for `AtomicBool`][46293]
10118- [impl `From<{CString, &CStr}>` for `{Arc<CStr>, Rc<CStr>}`][45990]
10119- [impl `From<{OsString, &OsStr}>` for `{Arc<OsStr>, Rc<OsStr>}`][45990]
10120- [impl `From<{PathBuf, &Path}>` for `{Arc<Path>, Rc<Path>}`][45990]
10121- [float::from_bits now just uses transmute.][46012] This provides
10122 some optimisations from LLVM.
10123- [Copied `AsciiExt` methods onto `char`][46077]
10124- [Remove `T: Sized` requirement on `ptr::is_null()`][46094]
10125- [impl `From<RecvError>` for `{TryRecvError, RecvTimeoutError}`][45506]
10126- [Optimised `f32::{min, max}` to generate more efficient x86 assembly][47080]
10127- [`[u8]::contains` now uses memchr which provides a 3x speed improvement][46713]
10128
10129Stabilized APIs
10130---------------
10131- [`RefCell::replace`]
10132- [`RefCell::swap`]
10133- [`atomic::spin_loop_hint`]
10134
10135The following functions can now be used in a constant expression.
10136eg. `let buffer: [u8; size_of::<usize>()];`, `static COUNTER: AtomicUsize = AtomicUsize::new(1);`
10137
10138- [`AtomicBool::new`][46287]
10139- [`AtomicUsize::new`][46287]
10140- [`AtomicIsize::new`][46287]
10141- [`AtomicPtr::new`][46287]
10142- [`Cell::new`][46287]
10143- [`{integer}::min_value`][46287]
10144- [`{integer}::max_value`][46287]
10145- [`mem::size_of`][46287]
10146- [`mem::align_of`][46287]
10147- [`ptr::null`][46287]
10148- [`ptr::null_mut`][46287]
10149- [`RefCell::new`][46287]
10150- [`UnsafeCell::new`][46287]
10151
10152Cargo
10153-----
10154- [Added a `workspace.default-members` config that
10155 overrides implied `--all` in virtual workspaces.][cargo/4743]
10156- [Enable incremental by default on development builds.][cargo/4817] Also added
10157 configuration keys to `Cargo.toml` and `.cargo/config` to disable on a
10158 per-project or global basis respectively.
10159
10160Misc
10161----
10162
10163Compatibility Notes
10164-------------------
10165- [Floating point types `Debug` impl now always prints a decimal point.][46831]
10166- [`Ipv6Addr` now rejects superfluous `::`'s in IPv6 addresses][46671] This is
10167 in accordance with IETF RFC 4291 §2.2.
10168- [Unwinding will no longer go past FFI boundaries, and will instead abort.][46833]
10169- [`Formatter::flags` method is now deprecated.][46284] The `sign_plus`,
10170 `sign_minus`, `alternate`, and `sign_aware_zero_pad` should be used instead.
10171- [Leading zeros in tuple struct members is now an error][47084]
10172- [`column!()` macro is one-based instead of zero-based][46977]
10173- [`fmt::Arguments` can no longer be shared across threads][45198]
10174- [Access to `#[repr(packed)]` struct fields is now unsafe][44884]
10175- [Cargo sets a different working directory for the compiler][cargo/4788]
10176
10177[44884]: https://github.com/rust-lang/rust/pull/44884
10178[45198]: https://github.com/rust-lang/rust/pull/45198
10179[45506]: https://github.com/rust-lang/rust/pull/45506
10180[45990]: https://github.com/rust-lang/rust/pull/45990
10181[46012]: https://github.com/rust-lang/rust/pull/46012
10182[46077]: https://github.com/rust-lang/rust/pull/46077
10183[46094]: https://github.com/rust-lang/rust/pull/46094
10184[46284]: https://github.com/rust-lang/rust/pull/46284
10185[46287]: https://github.com/rust-lang/rust/pull/46287
10186[46293]: https://github.com/rust-lang/rust/pull/46293
10187[46528]: https://github.com/rust-lang/rust/pull/46528
10188[46671]: https://github.com/rust-lang/rust/pull/46671
10189[46713]: https://github.com/rust-lang/rust/pull/46713
10190[46735]: https://github.com/rust-lang/rust/pull/46735
10191[46760]: https://github.com/rust-lang/rust/pull/46760
10192[46798]: https://github.com/rust-lang/rust/pull/46798
10193[46828]: https://github.com/rust-lang/rust/pull/46828
10194[46831]: https://github.com/rust-lang/rust/pull/46831
10195[46833]: https://github.com/rust-lang/rust/pull/46833
10196[46910]: https://github.com/rust-lang/rust/pull/46910
10197[46977]: https://github.com/rust-lang/rust/pull/46977
10198[47018]: https://github.com/rust-lang/rust/pull/47018
10199[47080]: https://github.com/rust-lang/rust/pull/47080
10200[47084]: https://github.com/rust-lang/rust/pull/47084
10201[cargo/4743]: https://github.com/rust-lang/cargo/pull/4743
10202[cargo/4788]: https://github.com/rust-lang/cargo/pull/4788
10203[cargo/4817]: https://github.com/rust-lang/cargo/pull/4817
10204[`RefCell::replace`]: https://doc.rust-lang.org/std/cell/struct.RefCell.html#method.replace
10205[`RefCell::swap`]: https://doc.rust-lang.org/std/cell/struct.RefCell.html#method.swap
10206[`atomic::spin_loop_hint`]: https://doc.rust-lang.org/std/sync/atomic/fn.spin_loop_hint.html
10207
10208
10209Version 1.23.0 (2018-01-04)
10210==========================
10211
10212Language
10213--------
10214- [Arbitrary `auto` traits are now permitted in trait objects.][45772]
10215- [rustc now uses subtyping on the left hand side of binary operations.][45435]
10216 Which should fix some confusing errors in some operations.
10217
10218Compiler
10219--------
10220- [Enabled `TrapUnreachable` in LLVM which should mitigate the impact of
10221 undefined behavior.][45920]
10222- [rustc now suggests renaming import if names clash.][45660]
10223- [Display errors/warnings correctly when there are zero-width or
10224 wide characters.][45711]
10225- [rustc now avoids unnecessary copies of arguments that are
10226 simple bindings][45380] This should improve memory usage on average by 5-10%.
10227- [Updated musl used to build musl rustc to 1.1.17][45393]
10228
10229Libraries
10230---------
10231- [Allow a trailing comma in `assert_eq/ne` macro][45887]
10232- [Implement Hash for raw pointers to unsized types][45483]
10233- [impl `From<*mut T>` for `AtomicPtr<T>`][45610]
10234- [impl `From<usize/isize>` for `AtomicUsize/AtomicIsize`.][45610]
10235- [Removed the `T: Sync` requirement for `RwLock<T>: Send`][45267]
10236- [Removed `T: Sized` requirement for `{<*const T>, <*mut T>}::as_ref`
10237 and `<*mut T>::as_mut`][44932]
10238- [Optimized `Thread::{park, unpark}` implementation][45524]
10239- [Improved `SliceExt::binary_search` performance.][45333]
10240- [impl `FromIterator<()>` for `()`][45379]
10241- [Copied `AsciiExt` trait methods to primitive types.][44042] Use of `AsciiExt`
10242 is now deprecated.
10243
10244Stabilized APIs
10245---------------
10246
10247Cargo
10248-----
10249- [Cargo now supports uninstallation of multiple packages][cargo/4561]
10250 eg. `cargo uninstall foo bar` uninstalls `foo` and `bar`.
10251- [Added unit test checking to `cargo check`][cargo/4592]
10252- [Cargo now lets you install a specific version
10253 using `cargo install --version`][cargo/4637]
10254
10255Misc
10256----
10257- [Releases now ship with the Cargo book documentation.][45692]
10258- [rustdoc now prints rendering warnings on every run.][45324]
10259
10260Compatibility Notes
10261-------------------
10262- [Changes have been made to type equality to make it more correct,
10263 in rare cases this could break some code.][45853] [Tracking issue for
10264 further information][45852]
10265- [`char::escape_debug` now uses Unicode 10 over 9.][45571]
10266- [Upgraded Android SDK to 27, and NDK to r15c.][45580] This drops support for
10267 Android 9, the minimum supported version is Android 14.
10268- [Bumped the minimum LLVM to 3.9][45326]
10269
10270[44042]: https://github.com/rust-lang/rust/pull/44042
10271[44932]: https://github.com/rust-lang/rust/pull/44932
10272[45267]: https://github.com/rust-lang/rust/pull/45267
10273[45324]: https://github.com/rust-lang/rust/pull/45324
10274[45326]: https://github.com/rust-lang/rust/pull/45326
10275[45333]: https://github.com/rust-lang/rust/pull/45333
10276[45379]: https://github.com/rust-lang/rust/pull/45379
10277[45380]: https://github.com/rust-lang/rust/pull/45380
10278[45393]: https://github.com/rust-lang/rust/pull/45393
10279[45435]: https://github.com/rust-lang/rust/pull/45435
10280[45483]: https://github.com/rust-lang/rust/pull/45483
10281[45524]: https://github.com/rust-lang/rust/pull/45524
10282[45571]: https://github.com/rust-lang/rust/pull/45571
10283[45580]: https://github.com/rust-lang/rust/pull/45580
10284[45610]: https://github.com/rust-lang/rust/pull/45610
10285[45660]: https://github.com/rust-lang/rust/pull/45660
10286[45692]: https://github.com/rust-lang/rust/pull/45692
10287[45711]: https://github.com/rust-lang/rust/pull/45711
10288[45772]: https://github.com/rust-lang/rust/pull/45772
10289[45852]: https://github.com/rust-lang/rust/issues/45852
10290[45853]: https://github.com/rust-lang/rust/pull/45853
10291[45887]: https://github.com/rust-lang/rust/pull/45887
10292[45920]: https://github.com/rust-lang/rust/pull/45920
10293[cargo/4561]: https://github.com/rust-lang/cargo/pull/4561
10294[cargo/4592]: https://github.com/rust-lang/cargo/pull/4592
10295[cargo/4637]: https://github.com/rust-lang/cargo/pull/4637
10296
10297
10298Version 1.22.1 (2017-11-22)
10299==========================
10300
10301- [Update Cargo to fix an issue with macOS 10.13 "High Sierra"][46183]
10302
10303[46183]: https://github.com/rust-lang/rust/pull/46183
10304
10305Version 1.22.0 (2017-11-22)
10306==========================
10307
10308Language
10309--------
10310- [`non_snake_case` lint now allows extern no-mangle functions][44966]
10311- [Now accepts underscores in unicode escapes][43716]
10312- [`T op= &T` now works for numeric types.][44287] eg. `let mut x = 2; x += &8;`
10313- [types that impl `Drop` are now allowed in `const` and `static` types][44456]
10314
10315Compiler
10316--------
10317- [rustc now defaults to having 16 codegen units at debug on supported platforms.][45064]
10318- [rustc will no longer inline in codegen units when compiling for debug][45075]
10319 This should decrease compile times for debug builds.
10320- [strict memory alignment now enabled on ARMv6][45094]
10321- [Remove support for the PNaCl target `le32-unknown-nacl`][45041]
10322
10323Libraries
10324---------
10325- [Allow atomic operations up to 32 bits
10326 on `armv5te_unknown_linux_gnueabi`][44978]
10327- [`Box<Error>` now impls `From<Cow<str>>`][44466]
10328- [`std::mem::Discriminant` is now guaranteed to be `Send + Sync`][45095]
10329- [`fs::copy` now returns the length of the main stream on NTFS.][44895]
10330- [Properly detect overflow in `Instant += Duration`.][44220]
10331- [impl `Hasher` for `{&mut Hasher, Box<Hasher>}`][44015]
10332- [impl `fmt::Debug` for `SplitWhitespace`.][44303]
10333- [`Option<T>` now impls `Try`][42526] This allows for using `?` with `Option` types.
10334
10335Stabilized APIs
10336---------------
10337
10338Cargo
10339-----
10340- [Cargo will now build multi file examples in subdirectories of the `examples`
10341 folder that have a `main.rs` file.][cargo/4496]
10342- [Changed `[root]` to `[package]` in `Cargo.lock`][cargo/4571] Packages with
10343 the old format will continue to work and can be updated with `cargo update`.
10344- [Now supports vendoring git repositories][cargo/3992]
10345
10346Misc
10347----
10348- [`libbacktrace` is now available on Apple platforms.][44251]
10349- [Stabilised the `compile_fail` attribute for code fences in doc-comments.][43949]
10350 This now lets you specify that a given code example will fail to compile.
10351
10352Compatibility Notes
10353-------------------
10354- [The minimum Android version that rustc can build for has been bumped
10355 to `4.0` from `2.3`][45656]
10356- [Allowing `T op= &T` for numeric types has broken some type
10357 inference cases][45480]
10358
10359
10360[42526]: https://github.com/rust-lang/rust/pull/42526
10361[43716]: https://github.com/rust-lang/rust/pull/43716
10362[43949]: https://github.com/rust-lang/rust/pull/43949
10363[44015]: https://github.com/rust-lang/rust/pull/44015
10364[44220]: https://github.com/rust-lang/rust/pull/44220
10365[44251]: https://github.com/rust-lang/rust/pull/44251
10366[44287]: https://github.com/rust-lang/rust/pull/44287
10367[44303]: https://github.com/rust-lang/rust/pull/44303
10368[44456]: https://github.com/rust-lang/rust/pull/44456
10369[44466]: https://github.com/rust-lang/rust/pull/44466
10370[44895]: https://github.com/rust-lang/rust/pull/44895
10371[44966]: https://github.com/rust-lang/rust/pull/44966
10372[44978]: https://github.com/rust-lang/rust/pull/44978
10373[45041]: https://github.com/rust-lang/rust/pull/45041
10374[45064]: https://github.com/rust-lang/rust/pull/45064
10375[45075]: https://github.com/rust-lang/rust/pull/45075
10376[45094]: https://github.com/rust-lang/rust/pull/45094
10377[45095]: https://github.com/rust-lang/rust/pull/45095
10378[45480]: https://github.com/rust-lang/rust/issues/45480
10379[45656]: https://github.com/rust-lang/rust/pull/45656
10380[cargo/3992]: https://github.com/rust-lang/cargo/pull/3992
10381[cargo/4496]: https://github.com/rust-lang/cargo/pull/4496
10382[cargo/4571]: https://github.com/rust-lang/cargo/pull/4571
10383
10384
10385
10386
10387
10388
10389Version 1.21.0 (2017-10-12)
10390==========================
10391
10392Language
10393--------
10394- [You can now use static references for literals.][43838]
10395 Example:
10396 ```rust
10397 fn main() {
10398 let x: &'static u32 = &0;
10399 }
10400 ```
10401- [Relaxed path syntax. Optional `::` before `<` is now allowed in all contexts.][43540]
10402 Example:
10403 ```rust
10404 my_macro!(Vec<i32>::new); // Always worked
10405 my_macro!(Vec::<i32>::new); // Now works
10406 ```
10407
10408Compiler
10409--------
10410- [Upgraded jemalloc to 4.5.0][43911]
10411- [Enabled unwinding panics on Redox][43917]
10412- [Now runs LLVM in parallel during translation phase.][43506]
10413 This should reduce peak memory usage.
10414
10415Libraries
10416---------
10417- [Generate builtin impls for `Clone` for all arrays and tuples that
10418 are `T: Clone`][43690]
10419- [`Stdin`, `Stdout`, and `Stderr` now implement `AsRawFd`.][43459]
10420- [`Rc` and `Arc` now implement `From<&[T]> where T: Clone`, `From<str>`,
10421 `From<String>`, `From<Box<T>> where T: ?Sized`, and `From<Vec<T>>`.][42565]
10422
10423Stabilized APIs
10424---------------
10425
10426[`std::mem::discriminant`]
10427
10428Cargo
10429-----
10430- [You can now call `cargo install` with multiple package names][cargo/4216]
10431- [Cargo commands inside a virtual workspace will now implicitly
10432 pass `--all`][cargo/4335]
10433- [Added a `[patch]` section to `Cargo.toml` to handle
10434 prepublication dependencies][cargo/4123] [RFC 1969]
10435- [`include` & `exclude` fields in `Cargo.toml` now accept gitignore
10436 like patterns][cargo/4270]
10437- [Added the `--all-targets` option][cargo/4400]
10438- [Using required dependencies as a feature is now deprecated and emits
10439 a warning][cargo/4364]
10440
10441
10442Misc
10443----
10444- [Cargo docs are moving][43916]
10445 to [doc.rust-lang.org/cargo](https://doc.rust-lang.org/cargo)
10446- [The rustdoc book is now available][43863]
10447 at [doc.rust-lang.org/rustdoc](https://doc.rust-lang.org/rustdoc)
10448- [Added a preview of RLS has been made available through rustup][44204]
10449 Install with `rustup component add rls-preview`
10450- [`std::os` documentation for Unix, Linux, and Windows now appears on doc.rust-lang.org][43348]
10451 Previously only showed `std::os::unix`.
10452
10453Compatibility Notes
10454-------------------
10455- [Changes in method matching against higher-ranked types][43880] This may cause
10456 breakage in subtyping corner cases. [A more in-depth explanation is available.][info/43880]
10457- [rustc's JSON error output's byte position start at top of file.][42973]
10458 Was previously relative to the rustc's internal `CodeMap` struct which
10459 required the unstable library `libsyntax` to correctly use.
10460- [`unused_results` lint no longer ignores booleans][43728]
10461
10462[42565]: https://github.com/rust-lang/rust/pull/42565
10463[42973]: https://github.com/rust-lang/rust/pull/42973
10464[43348]: https://github.com/rust-lang/rust/pull/43348
10465[43459]: https://github.com/rust-lang/rust/pull/43459
10466[43506]: https://github.com/rust-lang/rust/pull/43506
10467[43540]: https://github.com/rust-lang/rust/pull/43540
10468[43690]: https://github.com/rust-lang/rust/pull/43690
10469[43728]: https://github.com/rust-lang/rust/pull/43728
10470[43838]: https://github.com/rust-lang/rust/pull/43838
10471[43863]: https://github.com/rust-lang/rust/pull/43863
10472[43880]: https://github.com/rust-lang/rust/pull/43880
10473[43911]: https://github.com/rust-lang/rust/pull/43911
10474[43916]: https://github.com/rust-lang/rust/pull/43916
10475[43917]: https://github.com/rust-lang/rust/pull/43917
10476[44204]: https://github.com/rust-lang/rust/pull/44204
10477[cargo/4123]: https://github.com/rust-lang/cargo/pull/4123
10478[cargo/4216]: https://github.com/rust-lang/cargo/pull/4216
10479[cargo/4270]: https://github.com/rust-lang/cargo/pull/4270
10480[cargo/4335]: https://github.com/rust-lang/cargo/pull/4335
10481[cargo/4364]: https://github.com/rust-lang/cargo/pull/4364
10482[cargo/4400]: https://github.com/rust-lang/cargo/pull/4400
10483[RFC 1969]: https://github.com/rust-lang/rfcs/pull/1969
10484[info/43880]: https://github.com/rust-lang/rust/issues/44224#issuecomment-330058902
10485[`std::mem::discriminant`]: https://doc.rust-lang.org/std/mem/fn.discriminant.html
10486
10487Version 1.20.0 (2017-08-31)
10488===========================
10489
10490Language
10491--------
10492- [Associated constants are now stabilised.][42809]
10493- [A lot of macro bugs are now fixed.][42913]
10494
10495Compiler
10496--------
10497
10498- [Struct fields are now properly coerced to the expected field type.][42807]
10499- [Enabled wasm LLVM backend][42571] WASM can now be built with the
10500 `wasm32-experimental-emscripten` target.
10501- [Changed some of the error messages to be more helpful.][42033]
10502- [Add support for RELRO(RELocation Read-Only) for platforms that support
10503 it.][43170]
10504- [rustc now reports the total number of errors on compilation failure][43015]
10505 previously this was only the number of errors in the pass that failed.
10506- [Expansion in rustc has been sped up 29x.][42533]
10507- [added `msp430-none-elf` target.][43099]
10508- [rustc will now suggest one-argument enum variant to fix type mismatch when
10509 applicable][43178]
10510- [Fixes backtraces on Redox][43228]
10511- [rustc now identifies different versions of same crate when absolute paths of
10512 different types match in an error message.][42826]
10513
10514Libraries
10515---------
10516
10517
10518- [Relaxed Debug constraints on `{HashMap,BTreeMap}::{Keys,Values}`.][42854]
10519- [Impl `PartialEq`, `Eq`, `PartialOrd`, `Ord`, `Debug`, `Hash` for unsized
10520 tuples.][43011]
10521- [Impl `fmt::{Display, Debug}` for `Ref`, `RefMut`, `MutexGuard`,
10522 `RwLockReadGuard`, `RwLockWriteGuard`][42822]
10523- [Impl `Clone` for `DefaultHasher`.][42799]
10524- [Impl `Sync` for `SyncSender`.][42397]
10525- [Impl `FromStr` for `char`][42271]
10526- [Fixed how `{f32, f64}::{is_sign_negative, is_sign_positive}` handles
10527 NaN.][42431]
10528- [allow messages in the `unimplemented!()` macro.][42155]
10529 ie. `unimplemented!("Waiting for 1.21 to be stable")`
10530- [`pub(restricted)` is now supported in the `thread_local!` macro.][43185]
10531- [Upgrade to Unicode 10.0.0][42999]
10532- [Reimplemented `{f32, f64}::{min, max}` in Rust instead of using CMath.][42430]
10533- [Skip the main thread's manual stack guard on Linux][43072]
10534- [Iterator::nth for `ops::{Range, RangeFrom}` is now done in *O*(1) time][43077]
10535- [`#[repr(align(N))]` attribute max number is now 2^31 - 1.][43097] This was
10536 previously 2^15.
10537- [`{OsStr, Path}::Display` now avoids allocations where possible][42613]
10538
10539Stabilized APIs
10540---------------
10541
10542- [`CStr::into_c_string`]
10543- [`CString::as_c_str`]
10544- [`CString::into_boxed_c_str`]
10545- [`Chain::get_mut`]
10546- [`Chain::get_ref`]
10547- [`Chain::into_inner`]
10548- [`Option::get_or_insert_with`]
10549- [`Option::get_or_insert`]
10550- [`OsStr::into_os_string`]
10551- [`OsString::into_boxed_os_str`]
10552- [`Take::get_mut`]
10553- [`Take::get_ref`]
10554- [`Utf8Error::error_len`]
10555- [`char::EscapeDebug`]
10556- [`char::escape_debug`]
10557- [`compile_error!`]
10558- [`f32::from_bits`]
10559- [`f32::to_bits`]
10560- [`f64::from_bits`]
10561- [`f64::to_bits`]
10562- [`mem::ManuallyDrop`]
10563- [`slice::sort_unstable_by_key`]
10564- [`slice::sort_unstable_by`]
10565- [`slice::sort_unstable`]
10566- [`str::from_boxed_utf8_unchecked`]
10567- [`str::as_bytes_mut`]
10568- [`str::as_bytes_mut`]
10569- [`str::from_utf8_mut`]
10570- [`str::from_utf8_unchecked_mut`]
10571- [`str::get_mut`]
10572- [`str::get_unchecked_mut`]
10573- [`str::get_unchecked`]
10574- [`str::get`]
10575- [`str::into_boxed_bytes`]
10576
10577
10578Cargo
10579-----
10580- [Cargo API token location moved from `~/.cargo/config` to
10581 `~/.cargo/credentials`.][cargo/3978]
10582- [Cargo will now build `main.rs` binaries that are in sub-directories of
10583 `src/bin`.][cargo/4214] ie. Having `src/bin/server/main.rs` and
10584 `src/bin/client/main.rs` generates `target/debug/server` and `target/debug/client`
10585- [You can now specify version of a binary when installed through
10586 `cargo install` using `--vers`.][cargo/4229]
10587- [Added `--no-fail-fast` flag to cargo to run all benchmarks regardless of
10588 failure.][cargo/4248]
10589- [Changed the convention around which file is the crate root.][cargo/4259]
10590
10591Compatibility Notes
10592-------------------
10593
10594- [Functions with `'static` in their return types will now not be as usable as
10595 if they were using lifetime parameters instead.][42417]
10596- [The reimplementation of `{f32, f64}::is_sign_{negative, positive}` now
10597 takes the sign of NaN into account where previously didn't.][42430]
10598
10599[42033]: https://github.com/rust-lang/rust/pull/42033
10600[42155]: https://github.com/rust-lang/rust/pull/42155
10601[42271]: https://github.com/rust-lang/rust/pull/42271
10602[42397]: https://github.com/rust-lang/rust/pull/42397
10603[42417]: https://github.com/rust-lang/rust/pull/42417
10604[42430]: https://github.com/rust-lang/rust/pull/42430
10605[42431]: https://github.com/rust-lang/rust/pull/42431
10606[42533]: https://github.com/rust-lang/rust/pull/42533
10607[42571]: https://github.com/rust-lang/rust/pull/42571
10608[42613]: https://github.com/rust-lang/rust/pull/42613
10609[42799]: https://github.com/rust-lang/rust/pull/42799
10610[42807]: https://github.com/rust-lang/rust/pull/42807
10611[42809]: https://github.com/rust-lang/rust/pull/42809
10612[42822]: https://github.com/rust-lang/rust/pull/42822
10613[42826]: https://github.com/rust-lang/rust/pull/42826
10614[42854]: https://github.com/rust-lang/rust/pull/42854
10615[42913]: https://github.com/rust-lang/rust/pull/42913
10616[42999]: https://github.com/rust-lang/rust/pull/42999
10617[43011]: https://github.com/rust-lang/rust/pull/43011
10618[43015]: https://github.com/rust-lang/rust/pull/43015
10619[43072]: https://github.com/rust-lang/rust/pull/43072
10620[43077]: https://github.com/rust-lang/rust/pull/43077
10621[43097]: https://github.com/rust-lang/rust/pull/43097
10622[43099]: https://github.com/rust-lang/rust/pull/43099
10623[43170]: https://github.com/rust-lang/rust/pull/43170
10624[43178]: https://github.com/rust-lang/rust/pull/43178
10625[43185]: https://github.com/rust-lang/rust/pull/43185
10626[43228]: https://github.com/rust-lang/rust/pull/43228
10627[cargo/3978]: https://github.com/rust-lang/cargo/pull/3978
10628[cargo/4214]: https://github.com/rust-lang/cargo/pull/4214
10629[cargo/4229]: https://github.com/rust-lang/cargo/pull/4229
10630[cargo/4248]: https://github.com/rust-lang/cargo/pull/4248
10631[cargo/4259]: https://github.com/rust-lang/cargo/pull/4259
10632[`CStr::into_c_string`]: https://doc.rust-lang.org/std/ffi/struct.CStr.html#method.into_c_string
10633[`CString::as_c_str`]: https://doc.rust-lang.org/std/ffi/struct.CString.html#method.as_c_str
10634[`CString::into_boxed_c_str`]: https://doc.rust-lang.org/std/ffi/struct.CString.html#method.into_boxed_c_str
10635[`Chain::get_mut`]: https://doc.rust-lang.org/std/io/struct.Chain.html#method.get_mut
10636[`Chain::get_ref`]: https://doc.rust-lang.org/std/io/struct.Chain.html#method.get_ref
10637[`Chain::into_inner`]: https://doc.rust-lang.org/std/io/struct.Chain.html#method.into_inner
10638[`Option::get_or_insert_with`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.get_or_insert_with
10639[`Option::get_or_insert`]: https://doc.rust-lang.org/std/option/enum.Option.html#method.get_or_insert
10640[`OsStr::into_os_string`]: https://doc.rust-lang.org/std/ffi/struct.OsStr.html#method.into_os_string
10641[`OsString::into_boxed_os_str`]: https://doc.rust-lang.org/std/ffi/struct.OsString.html#method.into_boxed_os_str
10642[`Take::get_mut`]: https://doc.rust-lang.org/std/io/struct.Take.html#method.get_mut
10643[`Take::get_ref`]: https://doc.rust-lang.org/std/io/struct.Take.html#method.get_ref
10644[`Utf8Error::error_len`]: https://doc.rust-lang.org/std/str/struct.Utf8Error.html#method.error_len
10645[`char::EscapeDebug`]: https://doc.rust-lang.org/std/char/struct.EscapeDebug.html
10646[`char::escape_debug`]: https://doc.rust-lang.org/std/primitive.char.html#method.escape_debug
10647[`compile_error!`]: https://doc.rust-lang.org/std/macro.compile_error.html
10648[`f32::from_bits`]: https://doc.rust-lang.org/std/primitive.f32.html#method.from_bits
10649[`f32::to_bits`]: https://doc.rust-lang.org/std/primitive.f32.html#method.to_bits
10650[`f64::from_bits`]: https://doc.rust-lang.org/std/primitive.f64.html#method.from_bits
10651[`f64::to_bits`]: https://doc.rust-lang.org/std/primitive.f64.html#method.to_bits
10652[`mem::ManuallyDrop`]: https://doc.rust-lang.org/std/mem/union.ManuallyDrop.html
10653[`slice::sort_unstable_by_key`]: https://doc.rust-lang.org/std/primitive.slice.html#method.sort_unstable_by_key
10654[`slice::sort_unstable_by`]: https://doc.rust-lang.org/std/primitive.slice.html#method.sort_unstable_by
10655[`slice::sort_unstable`]: https://doc.rust-lang.org/std/primitive.slice.html#method.sort_unstable
10656[`str::from_boxed_utf8_unchecked`]: https://doc.rust-lang.org/std/str/fn.from_boxed_utf8_unchecked.html
10657[`str::as_bytes_mut`]: https://doc.rust-lang.org/std/primitive.str.html#method.as_bytes_mut
10658[`str::from_utf8_mut`]: https://doc.rust-lang.org/std/str/fn.from_utf8_mut.html
10659[`str::from_utf8_unchecked_mut`]: https://doc.rust-lang.org/std/str/fn.from_utf8_unchecked_mut.html
10660[`str::get_mut`]: https://doc.rust-lang.org/std/primitive.str.html#method.get_mut
10661[`str::get_unchecked_mut`]: https://doc.rust-lang.org/std/primitive.str.html#method.get_unchecked_mut
10662[`str::get_unchecked`]: https://doc.rust-lang.org/std/primitive.str.html#method.get_unchecked
10663[`str::get`]: https://doc.rust-lang.org/std/primitive.str.html#method.get
10664[`str::into_boxed_bytes`]: https://doc.rust-lang.org/std/primitive.str.html#method.into_boxed_bytes
10665
10666
10667Version 1.19.0 (2017-07-20)
10668===========================
10669
10670Language
10671--------
10672
10673- [Numeric fields can now be used for creating tuple structs.][41145] [RFC 1506]
10674 For example `struct Point(u32, u32); let x = Point { 0: 7, 1: 0 };`.
10675- [Macro recursion limit increased to 1024 from 64.][41676]
10676- [Added lint for detecting unused macros.][41907]
10677- [`loop` can now return a value with `break`.][42016] [RFC 1624]
10678 For example: `let x = loop { break 7; };`
10679- [C compatible `union`s are now available.][42068] [RFC 1444] They can only
10680 contain `Copy` types and cannot have a `Drop` implementation.
10681 Example: `union Foo { bar: u8, baz: usize }`
10682- [Non capturing closures can now be coerced into `fn`s,][42162] [RFC 1558]
10683 Example: `let foo: fn(u8) -> u8 = |v: u8| { v };`
10684
10685Compiler
10686--------
10687
10688- [Add support for bootstrapping the Rust compiler toolchain on Android.][41370]
10689- [Change `arm-linux-androideabi` to correspond to the `armeabi`
10690 official ABI.][41656] If you wish to continue targeting the `armeabi-v7a` ABI
10691 you should use `--target armv7-linux-androideabi`.
10692- [Fixed ICE when removing a source file between compilation sessions.][41873]
10693- [Minor optimisation of string operations.][42037]
10694- [Compiler error message is now `aborting due to previous error(s)` instead of
10695 `aborting due to N previous errors`][42150] This was previously inaccurate and
10696 would only count certain kinds of errors.
10697- [The compiler now supports Visual Studio 2017][42225]
10698- [The compiler is now built against LLVM 4.0.1 by default][42948]
10699- [Added a lot][42264] of [new error codes][42302]
10700- [Added `target-feature=+crt-static` option][37406] [RFC 1721] Which allows
10701 libraries with C Run-time Libraries(CRT) to be statically linked.
10702- [Fixed various ARM codegen bugs][42740]
10703
10704Libraries
10705---------
10706
10707- [`String` now implements `FromIterator<Cow<'a, str>>` and
10708 `Extend<Cow<'a, str>>`][41449]
10709- [`Vec` now implements `From<&mut [T]>`][41530]
10710- [`Box<[u8]>` now implements `From<Box<str>>`][41258]
10711- [`SplitWhitespace` now implements `Clone`][41659]
10712- [`[u8]::reverse` is now 5x faster and `[u16]::reverse` is now
10713 1.5x faster][41764]
10714- [`eprint!` and `eprintln!` macros added to prelude.][41192] Same as the `print!`
10715 macros, but for printing to stderr.
10716
10717Stabilized APIs
10718---------------
10719
10720- [`OsString::shrink_to_fit`]
10721- [`cmp::Reverse`]
10722- [`Command::envs`]
10723- [`thread::ThreadId`]
10724
10725Cargo
10726-----
10727
10728- [Build scripts can now add environment variables to the environment
10729 the crate is being compiled in.
10730 Example: `println!("cargo:rustc-env=FOO=bar");`][cargo/3929]
10731- [Subcommands now replace the current process rather than spawning a new
10732 child process][cargo/3970]
10733- [Workspace members can now accept glob file patterns][cargo/3979]
10734- [Added `--all` flag to the `cargo bench` subcommand to run benchmarks of all
10735 the members in a given workspace.][cargo/3988]
10736- [Updated `libssh2-sys` to 0.2.6][cargo/4008]
10737- [Target directory path is now in the cargo metadata][cargo/4022]
10738- [Cargo no longer checks out a local working directory for the
10739 crates.io index][cargo/4026] This should provide smaller file size for the
10740 registry, and improve cloning times, especially on Windows machines.
10741- [Added an `--exclude` option for excluding certain packages when using the
10742 `--all` option][cargo/4031]
10743- [Cargo will now automatically retry when receiving a 5xx error
10744 from crates.io][cargo/4032]
10745- [The `--features` option now accepts multiple comma or space
10746 delimited values.][cargo/4084]
10747- [Added support for custom target specific runners][cargo/3954]
10748
10749Misc
10750----
10751
10752- [Added `rust-windbg.cmd`][39983] for loading rust `.natvis` files in the
10753 Windows Debugger.
10754- [Rust will now release XZ compressed packages][rust-installer/57]
10755- [rustup will now prefer to download rust packages with
10756 XZ compression][rustup/1100] over GZip packages.
10757- [Added the ability to escape `#` in rust documentation][41785] By adding
10758 additional `#`'s ie. `##` is now `#`
10759
10760Compatibility Notes
10761-------------------
10762
10763- [`MutexGuard<T>` may only be `Sync` if `T` is `Sync`.][41624]
10764- [`-Z` flags are now no longer allowed to be used on the stable
10765 compiler.][41751] This has been a warning for a year previous to this.
10766- [As a result of the `-Z` flag change, the `cargo-check` plugin no
10767 longer works][42844]. Users should migrate to the built-in `check`
10768 command, which has been available since 1.16.
10769- [Ending a float literal with `._` is now a hard error.
10770 Example: `42._` .][41946]
10771- [Any use of a private `extern crate` outside of its module is now a
10772 hard error.][36886] This was previously a warning.
10773- [`use ::self::foo;` is now a hard error.][36888] `self` paths are always
10774 relative while the `::` prefix makes a path absolute, but was ignored and the
10775 path was relative regardless.
10776- [Floating point constants in match patterns is now a hard error][36890]
10777 This was previously a warning.
10778- [Struct or enum constants that don't derive `PartialEq` & `Eq` used
10779 match patterns is now a hard error][36891] This was previously a warning.
10780- [Lifetimes named `'_` are no longer allowed.][36892] This was previously
10781 a warning.
10782- [From the pound escape, lines consisting of multiple `#`s are
10783 now visible][41785]
10784- [It is an error to re-export private enum variants][42460]. This is
10785 known to break a number of crates that depend on an older version of
10786 mustache.
10787- [On Windows, if `VCINSTALLDIR` is set incorrectly, `rustc` will try
10788 to use it to find the linker, and the build will fail where it did
10789 not previously][42607]
10790
10791[36886]: https://github.com/rust-lang/rust/issues/36886
10792[36888]: https://github.com/rust-lang/rust/issues/36888
10793[36890]: https://github.com/rust-lang/rust/issues/36890
10794[36891]: https://github.com/rust-lang/rust/issues/36891
10795[36892]: https://github.com/rust-lang/rust/issues/36892
10796[37406]: https://github.com/rust-lang/rust/issues/37406
10797[39983]: https://github.com/rust-lang/rust/pull/39983
10798[41145]: https://github.com/rust-lang/rust/pull/41145
10799[41192]: https://github.com/rust-lang/rust/pull/41192
10800[41258]: https://github.com/rust-lang/rust/pull/41258
10801[41370]: https://github.com/rust-lang/rust/pull/41370
10802[41449]: https://github.com/rust-lang/rust/pull/41449
10803[41530]: https://github.com/rust-lang/rust/pull/41530
10804[41624]: https://github.com/rust-lang/rust/pull/41624
10805[41656]: https://github.com/rust-lang/rust/pull/41656
10806[41659]: https://github.com/rust-lang/rust/pull/41659
10807[41676]: https://github.com/rust-lang/rust/pull/41676
10808[41751]: https://github.com/rust-lang/rust/pull/41751
10809[41764]: https://github.com/rust-lang/rust/pull/41764
10810[41785]: https://github.com/rust-lang/rust/pull/41785
10811[41873]: https://github.com/rust-lang/rust/pull/41873
10812[41907]: https://github.com/rust-lang/rust/pull/41907
10813[41946]: https://github.com/rust-lang/rust/pull/41946
10814[42016]: https://github.com/rust-lang/rust/pull/42016
10815[42037]: https://github.com/rust-lang/rust/pull/42037
10816[42068]: https://github.com/rust-lang/rust/pull/42068
10817[42150]: https://github.com/rust-lang/rust/pull/42150
10818[42162]: https://github.com/rust-lang/rust/pull/42162
10819[42225]: https://github.com/rust-lang/rust/pull/42225
10820[42264]: https://github.com/rust-lang/rust/pull/42264
10821[42302]: https://github.com/rust-lang/rust/pull/42302
10822[42460]: https://github.com/rust-lang/rust/issues/42460
10823[42607]: https://github.com/rust-lang/rust/issues/42607
10824[42740]: https://github.com/rust-lang/rust/pull/42740
10825[42844]: https://github.com/rust-lang/rust/issues/42844
10826[42948]: https://github.com/rust-lang/rust/pull/42948
10827[RFC 1444]: https://github.com/rust-lang/rfcs/pull/1444
10828[RFC 1506]: https://github.com/rust-lang/rfcs/pull/1506
10829[RFC 1558]: https://github.com/rust-lang/rfcs/pull/1558
10830[RFC 1624]: https://github.com/rust-lang/rfcs/pull/1624
10831[RFC 1721]: https://github.com/rust-lang/rfcs/pull/1721
10832[`Command::envs`]: https://doc.rust-lang.org/std/process/struct.Command.html#method.envs
10833[`OsString::shrink_to_fit`]: https://doc.rust-lang.org/std/ffi/struct.OsString.html#method.shrink_to_fit
10834[`cmp::Reverse`]: https://doc.rust-lang.org/std/cmp/struct.Reverse.html
10835[`thread::ThreadId`]: https://doc.rust-lang.org/std/thread/struct.ThreadId.html
10836[cargo/3929]: https://github.com/rust-lang/cargo/pull/3929
10837[cargo/3954]: https://github.com/rust-lang/cargo/pull/3954
10838[cargo/3970]: https://github.com/rust-lang/cargo/pull/3970
10839[cargo/3979]: https://github.com/rust-lang/cargo/pull/3979
10840[cargo/3988]: https://github.com/rust-lang/cargo/pull/3988
10841[cargo/4008]: https://github.com/rust-lang/cargo/pull/4008
10842[cargo/4022]: https://github.com/rust-lang/cargo/pull/4022
10843[cargo/4026]: https://github.com/rust-lang/cargo/pull/4026
10844[cargo/4031]: https://github.com/rust-lang/cargo/pull/4031
10845[cargo/4032]: https://github.com/rust-lang/cargo/pull/4032
10846[cargo/4084]: https://github.com/rust-lang/cargo/pull/4084
10847[rust-installer/57]: https://github.com/rust-lang/rust-installer/pull/57
10848[rustup/1100]: https://github.com/rust-lang-nursery/rustup.rs/pull/1100
10849
10850
10851Version 1.18.0 (2017-06-08)
10852===========================
10853
10854Language
10855--------
10856
10857- [Stabilize pub(restricted)][40556] `pub` can now accept a module path to
10858 make the item visible to just that module tree. Also accepts the keyword
10859 `crate` to make something public to the whole crate but not users of the
10860 library. Example: `pub(crate) mod utils;`. [RFC 1422].
10861- [Stabilize `#![windows_subsystem]` attribute][40870] conservative exposure of the
10862 `/SUBSYSTEM` linker flag on Windows platforms. [RFC 1665].
10863- [Refactor of trait object type parsing][40043] Now `ty` in macros can accept
10864 types like `Write + Send`, trailing `+` are now supported in trait objects,
10865 and better error reporting for trait objects starting with `?Sized`.
10866- [0e+10 is now a valid floating point literal][40589]
10867- [Now warns if you bind a lifetime parameter to 'static][40734]
10868- [Tuples, Enum variant fields, and structs with no `repr` attribute or with
10869 `#[repr(Rust)]` are reordered to minimize padding and produce a smaller
10870 representation in some cases.][40377]
10871
10872Compiler
10873--------
10874
10875- [rustc can now emit mir with `--emit mir`][39891]
10876- [Improved LLVM IR for trivial functions][40367]
10877- [Added explanation for E0090(Wrong number of lifetimes are supplied)][40723]
10878- [rustc compilation is now 15%-20% faster][41469] Thanks to optimisation
10879 opportunities found through profiling
10880- [Improved backtrace formatting when panicking][38165]
10881
10882Libraries
10883---------
10884
10885- [Specialized `Vec::from_iter` being passed `vec::IntoIter`][40731] if the
10886 iterator hasn't been advanced the original `Vec` is reassembled with no actual
10887 iteration or reallocation.
10888- [Simplified HashMap Bucket interface][40561] provides performance
10889 improvements for iterating and cloning.
10890- [Specialize Vec::from_elem to use calloc][40409]
10891- [Fixed Race condition in fs::create_dir_all][39799]
10892- [No longer caching stdio on Windows][40516]
10893- [Optimized insertion sort in slice][40807] insertion sort in some cases
10894 2.50%~ faster and in one case now 12.50% faster.
10895- [Optimized `AtomicBool::fetch_nand`][41143]
10896
10897Stabilized APIs
10898---------------
10899
10900- [`Child::try_wait`]
10901- [`HashMap::retain`]
10902- [`HashSet::retain`]
10903- [`PeekMut::pop`]
10904- [`TcpStream::peek`]
10905- [`UdpSocket::peek`]
10906- [`UdpSocket::peek_from`]
10907
10908Cargo
10909-----
10910
10911- [Added partial Pijul support][cargo/3842] Pijul is a version control system in Rust.
10912 You can now create new cargo projects with Pijul using `cargo new --vcs pijul`
10913- [Now always emits build script warnings for crates that fail to build][cargo/3847]
10914- [Added Android build support][cargo/3885]
10915- [Added `--bins` and `--tests` flags][cargo/3901] now you can build all programs
10916 of a certain type, for example `cargo build --bins` will build all
10917 binaries.
10918- [Added support for haiku][cargo/3952]
10919
10920Misc
10921----
10922
10923- [rustdoc can now use pulldown-cmark with the `--enable-commonmark` flag][40338]
10924- [Rust now uses the official cross compiler for NetBSD][40612]
10925- [rustdoc now accepts `#` at the start of files][40828]
10926- [Fixed jemalloc support for musl][41168]
10927
10928Compatibility Notes
10929-------------------
10930
10931- [Changes to how the `0` flag works in format!][40241] Padding zeroes are now
10932 always placed after the sign if it exists and before the digits. With the `#`
10933 flag the zeroes are placed after the prefix and before the digits.
10934- [Due to the struct field optimisation][40377], using `transmute` on structs
10935 that have no `repr` attribute or `#[repr(Rust)]` will no longer work. This has
10936 always been undefined behavior, but is now more likely to break in practice.
10937- [The refactor of trait object type parsing][40043] fixed a bug where `+` was
10938 receiving the wrong priority parsing things like `&for<'a> Tr<'a> + Send` as
10939 `&(for<'a> Tr<'a> + Send)` instead of `(&for<'a> Tr<'a>) + Send`
10940- [Overlapping inherent `impl`s are now a hard error][40728]
10941- [`PartialOrd` and `Ord` must agree on the ordering.][41270]
10942- [`rustc main.rs -o out --emit=asm,llvm-ir`][41085] Now will output
10943 `out.asm` and `out.ll` instead of only one of the filetypes.
10944- [ calling a function that returns `Self` will no longer work][41805] when
10945 the size of `Self` cannot be statically determined.
10946- [rustc now builds with a "pthreads" flavour of MinGW for Windows GNU][40805]
10947 this has caused a few regressions namely:
10948
10949 - Changed the link order of local static/dynamic libraries (respecting the
10950 order on given rather than having the compiler reorder).
10951 - Changed how MinGW is linked, native code linked to dynamic libraries
10952 may require manually linking to the gcc support library (for the native
10953 code itself)
10954
10955[38165]: https://github.com/rust-lang/rust/pull/38165
10956[39799]: https://github.com/rust-lang/rust/pull/39799
10957[39891]: https://github.com/rust-lang/rust/pull/39891
10958[40043]: https://github.com/rust-lang/rust/pull/40043
10959[40241]: https://github.com/rust-lang/rust/pull/40241
10960[40338]: https://github.com/rust-lang/rust/pull/40338
10961[40367]: https://github.com/rust-lang/rust/pull/40367
10962[40377]: https://github.com/rust-lang/rust/pull/40377
10963[40409]: https://github.com/rust-lang/rust/pull/40409
10964[40516]: https://github.com/rust-lang/rust/pull/40516
10965[40556]: https://github.com/rust-lang/rust/pull/40556
10966[40561]: https://github.com/rust-lang/rust/pull/40561
10967[40589]: https://github.com/rust-lang/rust/pull/40589
10968[40612]: https://github.com/rust-lang/rust/pull/40612
10969[40723]: https://github.com/rust-lang/rust/pull/40723
10970[40728]: https://github.com/rust-lang/rust/pull/40728
10971[40731]: https://github.com/rust-lang/rust/pull/40731
10972[40734]: https://github.com/rust-lang/rust/pull/40734
10973[40805]: https://github.com/rust-lang/rust/pull/40805
10974[40807]: https://github.com/rust-lang/rust/pull/40807
10975[40828]: https://github.com/rust-lang/rust/pull/40828
10976[40870]: https://github.com/rust-lang/rust/pull/40870
10977[41085]: https://github.com/rust-lang/rust/pull/41085
10978[41143]: https://github.com/rust-lang/rust/pull/41143
10979[41168]: https://github.com/rust-lang/rust/pull/41168
10980[41270]: https://github.com/rust-lang/rust/issues/41270
10981[41469]: https://github.com/rust-lang/rust/pull/41469
10982[41805]: https://github.com/rust-lang/rust/issues/41805
10983[RFC 1422]: https://github.com/rust-lang/rfcs/blob/master/text/1422-pub-restricted.md
10984[RFC 1665]: https://github.com/rust-lang/rfcs/blob/master/text/1665-windows-subsystem.md
10985[`Child::try_wait`]: https://doc.rust-lang.org/std/process/struct.Child.html#method.try_wait
10986[`HashMap::retain`]: https://doc.rust-lang.org/std/collections/struct.HashMap.html#method.retain
10987[`HashSet::retain`]: https://doc.rust-lang.org/std/collections/struct.HashSet.html#method.retain
10988[`PeekMut::pop`]: https://doc.rust-lang.org/std/collections/binary_heap/struct.PeekMut.html#method.pop
10989[`TcpStream::peek`]: https://doc.rust-lang.org/std/net/struct.TcpStream.html#method.peek
10990[`UdpSocket::peek_from`]: https://doc.rust-lang.org/std/net/struct.UdpSocket.html#method.peek_from
10991[`UdpSocket::peek`]: https://doc.rust-lang.org/std/net/struct.UdpSocket.html#method.peek
10992[cargo/3842]: https://github.com/rust-lang/cargo/pull/3842
10993[cargo/3847]: https://github.com/rust-lang/cargo/pull/3847
10994[cargo/3885]: https://github.com/rust-lang/cargo/pull/3885
10995[cargo/3901]: https://github.com/rust-lang/cargo/pull/3901
10996[cargo/3952]: https://github.com/rust-lang/cargo/pull/3952
10997
10998
10999Version 1.17.0 (2017-04-27)
11000===========================
11001
11002Language
11003--------
11004
11005* [The lifetime of statics and consts defaults to `'static`][39265]. [RFC 1623]
11006* [Fields of structs may be initialized without duplicating the field/variable
11007 names][39761]. [RFC 1682]
11008* [`Self` may be included in the `where` clause of `impls`][38864]. [RFC 1647]
11009* [When coercing to an unsized type lifetimes must be equal][40319]. That is,
11010 there is no subtyping between `T` and `U` when `T: Unsize<U>`. For example,
11011 coercing `&mut [&'a X; N]` to `&mut [&'b X]` requires `'a` be equal to
11012 `'b`. Soundness fix.
11013* [Values passed to the indexing operator, `[]`, automatically coerce][40166]
11014* [Static variables may contain references to other statics][40027]
11015
11016Compiler
11017--------
11018
11019* [Exit quickly on only `--emit dep-info`][40336]
11020* [Make `-C relocation-model` more correctly determine whether the linker
11021 creates a position-independent executable][40245]
11022* [Add `-C overflow-checks` to directly control whether integer overflow
11023 panics][40037]
11024* [The rustc type checker now checks items on demand instead of in a single
11025 in-order pass][40008]. This is mostly an internal refactoring in support of
11026 future work, including incremental type checking, but also resolves [RFC
11027 1647], allowing `Self` to appear in `impl` `where` clauses.
11028* [Optimize vtable loads][39995]
11029* [Turn off vectorization for Emscripten targets][39990]
11030* [Provide suggestions for unknown macros imported with `use`][39953]
11031* [Fix ICEs in path resolution][39939]
11032* [Strip exception handling code on Emscripten when `panic=abort`][39193]
11033* [Add clearer error message using `&str + &str`][39116]
11034
11035Stabilized APIs
11036---------------
11037
11038* [`Arc::into_raw`]
11039* [`Arc::from_raw`]
11040* [`Arc::ptr_eq`]
11041* [`Rc::into_raw`]
11042* [`Rc::from_raw`]
11043* [`Rc::ptr_eq`]
11044* [`Ordering::then`]
11045* [`Ordering::then_with`]
11046* [`BTreeMap::range`]
11047* [`BTreeMap::range_mut`]
11048* [`collections::Bound`]
11049* [`process::abort`]
11050* [`ptr::read_unaligned`]
11051* [`ptr::write_unaligned`]
11052* [`Result::expect_err`]
11053* [`Cell::swap`]
11054* [`Cell::replace`]
11055* [`Cell::into_inner`]
11056* [`Cell::take`]
11057
11058Libraries
11059---------
11060
11061* [`BTreeMap` and `BTreeSet` can iterate over ranges][27787]
11062* [`Cell` can store non-`Copy` types][39793]. [RFC 1651]
11063* [`String` implements `FromIterator<&char>`][40028]
11064* `Box` [implements][40009] a number of new conversions:
11065 `From<Box<str>> for String`,
11066 `From<Box<[T]>> for Vec<T>`,
11067 `From<Box<CStr>> for CString`,
11068 `From<Box<OsStr>> for OsString`,
11069 `From<Box<Path>> for PathBuf`,
11070 `Into<Box<str>> for String`,
11071 `Into<Box<[T]>> for Vec<T>`,
11072 `Into<Box<CStr>> for CString`,
11073 `Into<Box<OsStr>> for OsString`,
11074 `Into<Box<Path>> for PathBuf`,
11075 `Default for Box<str>`,
11076 `Default for Box<CStr>`,
11077 `Default for Box<OsStr>`,
11078 `From<&CStr> for Box<CStr>`,
11079 `From<&OsStr> for Box<OsStr>`,
11080 `From<&Path> for Box<Path>`
11081* [`ffi::FromBytesWithNulError` implements `Error` and `Display`][39960]
11082* [Specialize `PartialOrd<A> for [A] where A: Ord`][39642]
11083* [Slightly optimize `slice::sort`][39538]
11084* [Add `ToString` trait specialization for `Cow<'a, str>` and `String`][39440]
11085* [`Box<[T]>` implements `From<&[T]> where T: Copy`,
11086 `Box<str>` implements `From<&str>`][39438]
11087* [`IpAddr` implements `From` for various arrays. `SocketAddr` implements
11088 `From<(I, u16)> where I: Into<IpAddr>`][39372]
11089* [`format!` estimates the needed capacity before writing a string][39356]
11090* [Support unprivileged symlink creation in Windows][38921]
11091* [`PathBuf` implements `Default`][38764]
11092* [Implement `PartialEq<[A]>` for `VecDeque<A>`][38661]
11093* [`HashMap` resizes adaptively][38368] to guard against DOS attacks
11094 and poor hash functions.
11095
11096Cargo
11097-----
11098
11099* [Add `cargo check --all`][cargo/3731]
11100* [Add an option to ignore SSL revocation checking][cargo/3699]
11101* [Add `cargo run --package`][cargo/3691]
11102* [Add `required_features`][cargo/3667]
11103* [Assume `build.rs` is a build script][cargo/3664]
11104* [Find workspace via `workspace_root` link in containing member][cargo/3562]
11105
11106Misc
11107----
11108
11109* [Documentation is rendered with mdbook instead of the obsolete, in-tree
11110 `rustbook`][39633]
11111* [The "Unstable Book" documents nightly-only features][ubook]
11112* [Improve the style of the sidebar in rustdoc output][40265]
11113* [Configure build correctly on 64-bit CPU's with the armhf ABI][40261]
11114* [Fix MSP430 breakage due to `i128`][40257]
11115* [Preliminary Solaris/SPARCv9 support][39903]
11116* [`rustc` is linked statically on Windows MSVC targets][39837], allowing it to
11117 run without installing the MSVC runtime.
11118* [`rustdoc --test` includes file names in test names][39788]
11119* This release includes builds of `std` for `sparc64-unknown-linux-gnu`,
11120 `aarch64-unknown-linux-fuchsia`, and `x86_64-unknown-linux-fuchsia`.
11121* [Initial support for `aarch64-unknown-freebsd`][39491]
11122* [Initial support for `i686-unknown-netbsd`][39426]
11123* [This release no longer includes the old makefile build system][39431]. Rust
11124 is built with a custom build system, written in Rust, and with Cargo.
11125* [Add Debug implementations for libcollection structs][39002]
11126* [`TypeId` implements `PartialOrd` and `Ord`][38981]
11127* [`--test-threads=0` produces an error][38945]
11128* [`rustup` installs documentation by default][40526]
11129* [The Rust source includes NatVis visualizations][39843]. These can be used by
11130 WinDbg and Visual Studio to improve the debugging experience.
11131
11132Compatibility Notes
11133-------------------
11134
11135* [Rust 1.17 does not correctly detect the MSVC 2017 linker][38584]. As a
11136 workaround, either use MSVC 2015 or run vcvars.bat.
11137* [When coercing to an unsized type lifetimes must be equal][40319]. That is,
11138 disallow subtyping between `T` and `U` when `T: Unsize<U>`, e.g. coercing
11139 `&mut [&'a X; N]` to `&mut [&'b X]` requires `'a` be equal to `'b`. Soundness
11140 fix.
11141* [`format!` and `Display::to_string` panic if an underlying formatting
11142 implementation returns an error][40117]. Previously the error was silently
11143 ignored. It is incorrect for `write_fmt` to return an error when writing
11144 to a string.
11145* [In-tree crates are verified to be unstable][39851]. Previously, some minor
11146 crates were marked stable and could be accessed from the stable toolchain.
11147* [Rust git source no longer includes vendored crates][39728]. Those that need
11148 to build with vendored crates should build from release tarballs.
11149* [Fix inert attributes from `proc_macro_derives`][39572]
11150* [During crate resolution, rustc prefers a crate in the sysroot if two crates
11151 are otherwise identical][39518]. Unlikely to be encountered outside the Rust
11152 build system.
11153* [Fixed bugs around how type inference interacts with dead-code][39485]. The
11154 existing code generally ignores the type of dead-code unless a type-hint is
11155 provided; this can cause surprising inference interactions particularly around
11156 defaulting. The new code uniformly ignores the result type of dead-code.
11157* [Tuple-struct constructors with private fields are no longer visible][38932]
11158* [Lifetime parameters that do not appear in the arguments are now considered
11159 early-bound][38897], resolving a soundness bug (#[32330]). The
11160 `hr_lifetime_in_assoc_type` future-compatibility lint has been in effect since
11161 April of 2016.
11162* [rustdoc: fix doctests with non-feature crate attributes][38161]
11163* [Make transmuting from fn item types to pointer-sized types a hard
11164 error][34198]
11165
11166[27787]: https://github.com/rust-lang/rust/issues/27787
11167[32330]: https://github.com/rust-lang/rust/issues/32330
11168[34198]: https://github.com/rust-lang/rust/pull/34198
11169[38161]: https://github.com/rust-lang/rust/pull/38161
11170[38368]: https://github.com/rust-lang/rust/pull/38368
11171[38584]: https://github.com/rust-lang/rust/issues/38584
11172[38661]: https://github.com/rust-lang/rust/pull/38661
11173[38764]: https://github.com/rust-lang/rust/pull/38764
11174[38864]: https://github.com/rust-lang/rust/issues/38864
11175[38897]: https://github.com/rust-lang/rust/pull/38897
11176[38921]: https://github.com/rust-lang/rust/pull/38921
11177[38932]: https://github.com/rust-lang/rust/pull/38932
11178[38945]: https://github.com/rust-lang/rust/pull/38945
11179[38981]: https://github.com/rust-lang/rust/pull/38981
11180[39002]: https://github.com/rust-lang/rust/pull/39002
11181[39116]: https://github.com/rust-lang/rust/pull/39116
11182[39193]: https://github.com/rust-lang/rust/pull/39193
11183[39265]: https://github.com/rust-lang/rust/pull/39265
11184[39356]: https://github.com/rust-lang/rust/pull/39356
11185[39372]: https://github.com/rust-lang/rust/pull/39372
11186[39426]: https://github.com/rust-lang/rust/pull/39426
11187[39431]: https://github.com/rust-lang/rust/pull/39431
11188[39438]: https://github.com/rust-lang/rust/pull/39438
11189[39440]: https://github.com/rust-lang/rust/pull/39440
11190[39485]: https://github.com/rust-lang/rust/pull/39485
11191[39491]: https://github.com/rust-lang/rust/pull/39491
11192[39518]: https://github.com/rust-lang/rust/pull/39518
11193[39538]: https://github.com/rust-lang/rust/pull/39538
11194[39572]: https://github.com/rust-lang/rust/pull/39572
11195[39633]: https://github.com/rust-lang/rust/pull/39633
11196[39642]: https://github.com/rust-lang/rust/pull/39642
11197[39728]: https://github.com/rust-lang/rust/pull/39728
11198[39761]: https://github.com/rust-lang/rust/pull/39761
11199[39788]: https://github.com/rust-lang/rust/pull/39788
11200[39793]: https://github.com/rust-lang/rust/pull/39793
11201[39837]: https://github.com/rust-lang/rust/pull/39837
11202[39843]: https://github.com/rust-lang/rust/pull/39843
11203[39851]: https://github.com/rust-lang/rust/pull/39851
11204[39903]: https://github.com/rust-lang/rust/pull/39903
11205[39939]: https://github.com/rust-lang/rust/pull/39939
11206[39953]: https://github.com/rust-lang/rust/pull/39953
11207[39960]: https://github.com/rust-lang/rust/pull/39960
11208[39990]: https://github.com/rust-lang/rust/pull/39990
11209[39995]: https://github.com/rust-lang/rust/pull/39995
11210[40008]: https://github.com/rust-lang/rust/pull/40008
11211[40009]: https://github.com/rust-lang/rust/pull/40009
11212[40027]: https://github.com/rust-lang/rust/pull/40027
11213[40028]: https://github.com/rust-lang/rust/pull/40028
11214[40037]: https://github.com/rust-lang/rust/pull/40037
11215[40117]: https://github.com/rust-lang/rust/pull/40117
11216[40166]: https://github.com/rust-lang/rust/pull/40166
11217[40245]: https://github.com/rust-lang/rust/pull/40245
11218[40257]: https://github.com/rust-lang/rust/pull/40257
11219[40261]: https://github.com/rust-lang/rust/pull/40261
11220[40265]: https://github.com/rust-lang/rust/pull/40265
11221[40319]: https://github.com/rust-lang/rust/pull/40319
11222[40336]: https://github.com/rust-lang/rust/pull/40336
11223[40526]: https://github.com/rust-lang/rust/pull/40526
11224[RFC 1623]: https://github.com/rust-lang/rfcs/blob/master/text/1623-static.md
11225[RFC 1647]: https://github.com/rust-lang/rfcs/blob/master/text/1647-allow-self-in-where-clauses.md
11226[RFC 1651]: https://github.com/rust-lang/rfcs/blob/master/text/1651-movecell.md
11227[RFC 1682]: https://github.com/rust-lang/rfcs/blob/master/text/1682-field-init-shorthand.md
11228[`Arc::from_raw`]: https://doc.rust-lang.org/std/sync/struct.Arc.html#method.from_raw
11229[`Arc::into_raw`]: https://doc.rust-lang.org/std/sync/struct.Arc.html#method.into_raw
11230[`Arc::ptr_eq`]: https://doc.rust-lang.org/std/sync/struct.Arc.html#method.ptr_eq
11231[`BTreeMap::range_mut`]: https://doc.rust-lang.org/std/collections/btree_map/struct.BTreeMap.html#method.range_mut
11232[`BTreeMap::range`]: https://doc.rust-lang.org/std/collections/btree_map/struct.BTreeMap.html#method.range
11233[`Cell::into_inner`]: https://doc.rust-lang.org/std/cell/struct.Cell.html#method.into_inner
11234[`Cell::replace`]: https://doc.rust-lang.org/std/cell/struct.Cell.html#method.replace
11235[`Cell::swap`]: https://doc.rust-lang.org/std/cell/struct.Cell.html#method.swap
11236[`Cell::take`]: https://doc.rust-lang.org/std/cell/struct.Cell.html#method.take
11237[`Ordering::then_with`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.then_with
11238[`Ordering::then`]: https://doc.rust-lang.org/std/cmp/enum.Ordering.html#method.then
11239[`Rc::from_raw`]: https://doc.rust-lang.org/std/rc/struct.Rc.html#method.from_raw
11240[`Rc::into_raw`]: https://doc.rust-lang.org/std/rc/struct.Rc.html#method.into_raw
11241[`Rc::ptr_eq`]: https://doc.rust-lang.org/std/rc/struct.Rc.html#method.ptr_eq
11242[`Result::expect_err`]: https://doc.rust-lang.org/std/result/enum.Result.html#method.expect_err
11243[`collections::Bound`]: https://doc.rust-lang.org/std/collections/enum.Bound.html
11244[`process::abort`]: https://doc.rust-lang.org/std/process/fn.abort.html
11245[`ptr::read_unaligned`]: https://doc.rust-lang.org/std/ptr/fn.read_unaligned.html
11246[`ptr::write_unaligned`]: https://doc.rust-lang.org/std/ptr/fn.write_unaligned.html
11247[cargo/3562]: https://github.com/rust-lang/cargo/pull/3562
11248[cargo/3664]: https://github.com/rust-lang/cargo/pull/3664
11249[cargo/3667]: https://github.com/rust-lang/cargo/pull/3667
11250[cargo/3691]: https://github.com/rust-lang/cargo/pull/3691
11251[cargo/3699]: https://github.com/rust-lang/cargo/pull/3699
11252[cargo/3731]: https://github.com/rust-lang/cargo/pull/3731
11253[ubook]: https://doc.rust-lang.org/unstable-book/
11254
11255
11256Version 1.16.0 (2017-03-16)
11257===========================
11258
11259Language
11260--------
11261
11262* [The compiler's `dead_code` lint now accounts for type aliases][38051].
11263* [Uninhabitable enums (those without any variants) no longer permit wildcard
11264 match patterns][38069]
11265* [Clean up semantics of `self` in an import list][38313]
11266* [`Self` may appear in `impl` headers][38920]
11267* [`Self` may appear in struct expressions][39282]
11268
11269Compiler
11270--------
11271
11272* [`rustc` now supports `--emit=metadata`, which causes rustc to emit
11273 a `.rmeta` file containing only crate metadata][38571]. This can be
11274 used by tools like the Rust Language Service to perform
11275 metadata-only builds.
11276* [Levenshtein based typo suggestions now work in most places, while
11277 previously they worked only for fields and sometimes for local
11278 variables][38927]. Together with the overhaul of "no
11279 resolution"/"unexpected resolution" errors (#[38154]) they result in
11280 large and systematic improvement in resolution diagnostics.
11281* [Fix `transmute::<T, U>` where `T` requires a bigger alignment than
11282 `U`][38670]
11283* [rustc: use -Xlinker when specifying an rpath with ',' in it][38798]
11284* [`rustc` no longer attempts to provide "consider using an explicit
11285 lifetime" suggestions][37057]. They were inaccurate.
11286
11287Stabilized APIs
11288---------------
11289
11290* [`VecDeque::truncate`]
11291* [`VecDeque::resize`]
11292* [`String::insert_str`]
11293* [`Duration::checked_add`]
11294* [`Duration::checked_sub`]
11295* [`Duration::checked_div`]
11296* [`Duration::checked_mul`]
11297* [`str::replacen`]
11298* [`str::repeat`]
11299* [`SocketAddr::is_ipv4`]
11300* [`SocketAddr::is_ipv6`]
11301* [`IpAddr::is_ipv4`]
11302* [`IpAddr::is_ipv6`]
11303* [`Vec::dedup_by`]
11304* [`Vec::dedup_by_key`]
11305* [`Result::unwrap_or_default`]
11306* [`<*const T>::wrapping_offset`]
11307* [`<*mut T>::wrapping_offset`]
11308* `CommandExt::creation_flags`
11309* [`File::set_permissions`]
11310* [`String::split_off`]
11311
11312Libraries
11313---------
11314
11315* [`[T]::binary_search` and `[T]::binary_search_by_key` now take
11316 their argument by `Borrow` parameter][37761]
11317* [All public types in std implement `Debug`][38006]
11318* [`IpAddr` implements `From<Ipv4Addr>` and `From<Ipv6Addr>`][38327]
11319* [`Ipv6Addr` implements `From<[u16; 8]>`][38131]
11320* [Ctrl-Z returns from `Stdin.read()` when reading from the console on
11321 Windows][38274]
11322* [std: Fix partial writes in `LineWriter`][38062]
11323* [std: Clamp max read/write sizes on Unix][38622]
11324* [Use more specific panic message for `&str` slicing errors][38066]
11325* [`TcpListener::set_only_v6` is deprecated][38304]. This
11326 functionality cannot be achieved in std currently.
11327* [`writeln!`, like `println!`, now accepts a form with no string
11328 or formatting arguments, to just print a newline][38469]
11329* [Implement `iter::Sum` and `iter::Product` for `Result`][38580]
11330* [Reduce the size of static data in `std_unicode::tables`][38781]
11331* [`char::EscapeDebug`, `EscapeDefault`, `EscapeUnicode`,
11332 `CaseMappingIter`, `ToLowercase`, `ToUppercase`, implement
11333 `Display`][38909]
11334* [`Duration` implements `Sum`][38712]
11335* [`String` implements `ToSocketAddrs`][39048]
11336
11337Cargo
11338-----
11339
11340* [The `cargo check` command does a type check of a project without
11341 building it][cargo/3296]
11342* [crates.io will display CI badges from Travis and AppVeyor, if
11343 specified in Cargo.toml][cargo/3546]
11344* [crates.io will display categories listed in Cargo.toml][cargo/3301]
11345* [Compilation profiles accept integer values for `debug`, in addition
11346 to `true` and `false`. These are passed to `rustc` as the value to
11347 `-C debuginfo`][cargo/3534]
11348* [Implement `cargo --version --verbose`][cargo/3604]
11349* [All builds now output 'dep-info' build dependencies compatible with
11350 make and ninja][cargo/3557]
11351* [Build all workspace members with `build --all`][cargo/3511]
11352* [Document all workspace members with `doc --all`][cargo/3515]
11353* [Path deps outside workspace are not members][cargo/3443]
11354
11355Misc
11356----
11357
11358* [`rustdoc` has a `--sysroot` argument that, like `rustc`, specifies
11359 the path to the Rust implementation][38589]
11360* [The `armv7-linux-androideabi` target no longer enables NEON
11361 extensions, per Google's ABI guide][38413]
11362* [The stock standard library can be compiled for Redox OS][38401]
11363* [Rust has initial SPARC support][38726]. Tier 3. No builds
11364 available.
11365* [Rust has experimental support for Nvidia PTX][38559]. Tier 3. No
11366 builds available.
11367* [Fix backtraces on i686-pc-windows-gnu by disabling FPO][39379]
11368
11369Compatibility Notes
11370-------------------
11371
11372* [Uninhabitable enums (those without any variants) no longer permit wildcard
11373 match patterns][38069]
11374* In this release, references to uninhabited types can not be
11375 pattern-matched. This was accidentally allowed in 1.15.
11376* [The compiler's `dead_code` lint now accounts for type aliases][38051].
11377* [Ctrl-Z returns from `Stdin.read()` when reading from the console on
11378 Windows][38274]
11379* [Clean up semantics of `self` in an import list][38313]
11380* Reimplemented lifetime elision. This change was almost entirely compatible
11381 with existing code, but it did close a number of small bugs and loopholes,
11382 as well as being more accepting in some other [cases][41105].
11383
11384[37057]: https://github.com/rust-lang/rust/pull/37057
11385[37761]: https://github.com/rust-lang/rust/pull/37761
11386[38006]: https://github.com/rust-lang/rust/pull/38006
11387[38051]: https://github.com/rust-lang/rust/pull/38051
11388[38062]: https://github.com/rust-lang/rust/pull/38062
11389[38622]: https://github.com/rust-lang/rust/pull/38622
11390[38066]: https://github.com/rust-lang/rust/pull/38066
11391[38069]: https://github.com/rust-lang/rust/pull/38069
11392[38131]: https://github.com/rust-lang/rust/pull/38131
11393[38154]: https://github.com/rust-lang/rust/pull/38154
11394[38274]: https://github.com/rust-lang/rust/pull/38274
11395[38304]: https://github.com/rust-lang/rust/pull/38304
11396[38313]: https://github.com/rust-lang/rust/pull/38313
11397[38327]: https://github.com/rust-lang/rust/pull/38327
11398[38401]: https://github.com/rust-lang/rust/pull/38401
11399[38413]: https://github.com/rust-lang/rust/pull/38413
11400[38469]: https://github.com/rust-lang/rust/pull/38469
11401[38559]: https://github.com/rust-lang/rust/pull/38559
11402[38571]: https://github.com/rust-lang/rust/pull/38571
11403[38580]: https://github.com/rust-lang/rust/pull/38580
11404[38589]: https://github.com/rust-lang/rust/pull/38589
11405[38670]: https://github.com/rust-lang/rust/pull/38670
11406[38712]: https://github.com/rust-lang/rust/pull/38712
11407[38726]: https://github.com/rust-lang/rust/pull/38726
11408[38781]: https://github.com/rust-lang/rust/pull/38781
11409[38798]: https://github.com/rust-lang/rust/pull/38798
11410[38909]: https://github.com/rust-lang/rust/pull/38909
11411[38920]: https://github.com/rust-lang/rust/pull/38920
11412[38927]: https://github.com/rust-lang/rust/pull/38927
11413[39048]: https://github.com/rust-lang/rust/pull/39048
11414[39282]: https://github.com/rust-lang/rust/pull/39282
11415[39379]: https://github.com/rust-lang/rust/pull/39379
11416[41105]: https://github.com/rust-lang/rust/issues/41105
11417[`<*const T>::wrapping_offset`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.wrapping_offset
11418[`<*mut T>::wrapping_offset`]: https://doc.rust-lang.org/std/primitive.pointer.html#method.wrapping_offset-1
11419[`Duration::checked_add`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.checked_add
11420[`Duration::checked_div`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.checked_div
11421[`Duration::checked_mul`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.checked_mul
11422[`Duration::checked_sub`]: https://doc.rust-lang.org/std/time/struct.Duration.html#method.checked_sub
11423[`File::set_permissions`]: https://doc.rust-lang.org/std/fs/struct.File.html#method.set_permissions
11424[`IpAddr::is_ipv4`]: https://doc.rust-lang.org/std/net/enum.IpAddr.html#method.is_ipv4
11425[`IpAddr::is_ipv6`]: https://doc.rust-lang.org/std/net/enum.IpAddr.html#method.is_ipv6
11426[`Result::unwrap_or_default`]: https://doc.rust-lang.org/std/result/enum.Result.html#method.unwrap_or_default
11427[`SocketAddr::is_ipv4`]: https://doc.rust-lang.org/std/net/enum.SocketAddr.html#method.is_ipv4
11428[`SocketAddr::is_ipv6`]: https://doc.rust-lang.org/std/net/enum.SocketAddr.html#method.is_ipv6
11429[`String::insert_str`]: https://doc.rust-lang.org/std/string/struct.String.html#method.insert_str
11430[`String::split_off`]: https://doc.rust-lang.org/std/string/struct.String.html#method.split_off
11431[`Vec::dedup_by_key`]: https://doc.rust-lang.org/std/vec/struct.Vec.html#method.dedup_by_key
11432[`Vec::dedup_by`]: https://doc.rust-lang.org/std/vec/struct.Vec.html#method.dedup_by
11433[`VecDeque::resize`]: https://doc.rust-lang.org/std/collections/vec_deque/struct.VecDeque.html#method.resize
11434[`VecDeque::truncate`]: https://doc.rust-lang.org/std/collections/vec_deque/struct.VecDeque.html#method.truncate
11435[`str::repeat`]: https://doc.rust-lang.org/std/primitive.str.html#method.repeat
11436[`str::replacen`]: https://doc.rust-lang.org/std/primitive.str.html#method.replacen
11437[cargo/3296]: https://github.com/rust-lang/cargo/pull/3296
11438[cargo/3301]: https://github.com/rust-lang/cargo/pull/3301
11439[cargo/3443]: https://github.com/rust-lang/cargo/pull/3443
11440[cargo/3511]: https://github.com/rust-lang/cargo/pull/3511
11441[cargo/3515]: https://github.com/rust-lang/cargo/pull/3515
11442[cargo/3534]: https://github.com/rust-lang/cargo/pull/3534
11443[cargo/3546]: https://github.com/rust-lang/cargo/pull/3546
11444[cargo/3557]: https://github.com/rust-lang/cargo/pull/3557
11445[cargo/3604]: https://github.com/rust-lang/cargo/pull/3604
11446
11447
11448Version 1.15.1 (2017-02-09)
11449===========================
11450
11451* [Fix IntoIter::as_mut_slice's signature][39466]
11452* [Compile compiler builtins with `-fPIC` on 32-bit platforms][39523]
11453
11454[39466]: https://github.com/rust-lang/rust/pull/39466
11455[39523]: https://github.com/rust-lang/rust/pull/39523
11456
11457
11458Version 1.15.0 (2017-02-02)
11459===========================
11460
11461Language
11462--------
11463
11464* Basic procedural macros allowing custom `#[derive]`, aka "macros 1.1", are
11465 stable. This allows popular code-generating crates like Serde and Diesel to
11466 work ergonomically. [RFC 1681].
11467* [Tuple structs may be empty. Unary and empty tuple structs may be instantiated
11468 with curly braces][36868]. Part of [RFC 1506].
11469* [A number of minor changes to name resolution have been activated][37127].
11470 They add up to more consistent semantics, allowing for future evolution of
11471 Rust macros. Specified in [RFC 1560], see its section on ["changes"] for
11472 details of what is different. The breaking changes here have been transitioned
11473 through the [`legacy_imports`] lint since 1.14, with no known regressions.
11474* [In `macro_rules`, `path` fragments can now be parsed as type parameter
11475 bounds][38279]
11476* [`?Sized` can be used in `where` clauses][37791]
11477* [There is now a limit on the size of monomorphized types and it can be
11478 modified with the `#![type_size_limit]` crate attribute, similarly to
11479 the `#![recursion_limit]` attribute][37789]
11480
11481Compiler
11482--------
11483
11484* [On Windows, the compiler will apply dllimport attributes when linking to
11485 extern functions][37973]. Additional attributes and flags can control which
11486 library kind is linked and its name. [RFC 1717].
11487* [Rust-ABI symbols are no longer exported from cdylibs][38117]
11488* [The `--test` flag works with procedural macro crates][38107]
11489* [Fix `extern "aapcs" fn` ABI][37814]
11490* [The `-C no-stack-check` flag is deprecated][37636]. It does nothing.
11491* [The `format!` expander recognizes incorrect `printf` and shell-style
11492 formatting directives and suggests the correct format][37613].
11493* [Only report one error for all unused imports in an import list][37456]
11494
11495Compiler Performance
11496--------------------
11497
11498* [Avoid unnecessary `mk_ty` calls in `Ty::super_fold_with`][37705]
11499* [Avoid more unnecessary `mk_ty` calls in `Ty::super_fold_with`][37979]
11500* [Don't clone in `UnificationTable::probe`][37848]
11501* [Remove `scope_auxiliary` to cut RSS by 10%][37764]
11502* [Use small vectors in type walker][37760]
11503* [Macro expansion performance was improved][37701]
11504* [Change `HirVec<P<T>>` to `HirVec<T>` in `hir::Expr`][37642]
11505* [Replace FNV with a faster hash function][37229]
11506
11507Stabilized APIs
11508---------------
11509
11510* [`std::iter::Iterator::min_by`]
11511* [`std::iter::Iterator::max_by`]
11512* [`std::os::*::fs::FileExt`]
11513* [`std::sync::atomic::Atomic*::get_mut`]
11514* [`std::sync::atomic::Atomic*::into_inner`]
11515* [`std::vec::IntoIter::as_slice`]
11516* [`std::vec::IntoIter::as_mut_slice`]
11517* [`std::sync::mpsc::Receiver::try_iter`]
11518* [`std::os::unix::process::CommandExt::before_exec`]
11519* [`std::rc::Rc::strong_count`]
11520* [`std::rc::Rc::weak_count`]
11521* [`std::sync::Arc::strong_count`]
11522* [`std::sync::Arc::weak_count`]
11523* [`std::char::encode_utf8`]
11524* [`std::char::encode_utf16`]
11525* [`std::cell::Ref::clone`]
11526* [`std::io::Take::into_inner`]
11527
11528Libraries
11529---------
11530
11531* [The standard sorting algorithm has been rewritten for dramatic performance
11532 improvements][38192]. It is a hybrid merge sort, drawing influences from
11533 Timsort. Previously it was a naive merge sort.
11534* [`Iterator::nth` no longer has a `Sized` bound][38134]
11535* [`Extend<&T>` is specialized for `Vec` where `T: Copy`][38182] to improve
11536 performance.
11537* [`chars().count()` is much faster][37888] and so are [`chars().last()`
11538 and `char_indices().last()`][37882]
11539* [Fix ARM Objective-C ABI in `std::env::args`][38146]
11540* [Chinese characters display correctly in `fmt::Debug`][37855]
11541* [Derive `Default` for `Duration`][37699]
11542* [Support creation of anonymous pipes on WinXP/2k][37677]
11543* [`mpsc::RecvTimeoutError` implements `Error`][37527]
11544* [Don't pass overlapped handles to processes][38835]
11545
11546Cargo
11547-----
11548
11549* [In this release, Cargo build scripts no longer have access to the `OUT_DIR`
11550 environment variable at build time via `env!("OUT_DIR")`][cargo/3368]. They
11551 should instead check the variable at runtime with `std::env`. That the value
11552 was set at build time was a bug, and incorrect when cross-compiling. This
11553 change is known to cause breakage.
11554* [Add `--all` flag to `cargo test`][cargo/3221]
11555* [Compile statically against the MSVC CRT][cargo/3363]
11556* [Mix feature flags into fingerprint/metadata shorthash][cargo/3102]
11557* [Link OpenSSL statically on OSX][cargo/3311]
11558* [Apply new fingerprinting to build dir outputs][cargo/3310]
11559* [Test for bad path overrides with summaries][cargo/3336]
11560* [Require `cargo install --vers` to take a semver version][cargo/3338]
11561* [Fix retrying crate downloads for network errors][cargo/3348]
11562* [Implement string lookup for `build.rustflags` config key][cargo/3356]
11563* [Emit more info on --message-format=json][cargo/3319]
11564* [Assume `build.rs` in the same directory as `Cargo.toml` is a build script][cargo/3361]
11565* [Don't ignore errors in workspace manifest][cargo/3409]
11566* [Fix `--message-format JSON` when rustc emits non-JSON warnings][cargo/3410]
11567
11568Tooling
11569-------
11570
11571* [Test runners (binaries built with `--test`) now support a `--list` argument
11572 that lists the tests it contains][38185]
11573* [Test runners now support a `--exact` argument that makes the test filter
11574 match exactly, instead of matching only a substring of the test name][38181]
11575* [rustdoc supports a `--playground-url` flag][37763]
11576* [rustdoc provides more details about `#[should_panic]` errors][37749]
11577
11578Misc
11579----
11580
11581* [The Rust build system is now written in Rust][37817]. The Makefiles may
11582 continue to be used in this release by passing `--disable-rustbuild` to the
11583 configure script, but they will be deleted soon. Note that the new build
11584 system uses a different on-disk layout that will likely affect any scripts
11585 building Rust.
11586* [Rust supports i686-unknown-openbsd][38086]. Tier 3 support. No testing or
11587 releases.
11588* [Rust supports the MSP430][37627]. Tier 3 support. No testing or releases.
11589* [Rust supports the ARMv5TE architecture][37615]. Tier 3 support. No testing or
11590 releases.
11591
11592Compatibility Notes
11593-------------------
11594
11595* [A number of minor changes to name resolution have been activated][37127].
11596 They add up to more consistent semantics, allowing for future evolution of
11597 Rust macros. Specified in [RFC 1560], see its section on ["changes"] for
11598 details of what is different. The breaking changes here have been transitioned
11599 through the [`legacy_imports`] lint since 1.14, with no known regressions.
11600* [In this release, Cargo build scripts no longer have access to the `OUT_DIR`
11601 environment variable at build time via `env!("OUT_DIR")`][cargo/3368]. They
11602 should instead check the variable at runtime with `std::env`. That the value
11603 was set at build time was a bug, and incorrect when cross-compiling. This
11604 change is known to cause breakage.
11605* [Higher-ranked lifetimes are no longer allowed to appear _only_ in associated
11606 types][33685]. The [`hr_lifetime_in_assoc_type` lint] has been a warning since
11607 1.10 and is now an error by default. It will become a hard error in the near
11608 future.
11609* [The semantics relating modules to file system directories are changing in
11610 minor ways][37602]. This is captured in the new `legacy_directory_ownership`
11611 lint, which is a warning in this release, and will become a hard error in the
11612 future.
11613* [Rust-ABI symbols are no longer exported from cdylibs][38117]
11614* [Once `Peekable` peeks a `None` it will return that `None` without re-querying
11615 the underlying iterator][37834]
11616
11617["changes"]: https://github.com/rust-lang/rfcs/blob/master/text/1560-name-resolution.md#changes-to-name-resolution-rules
11618[33685]: https://github.com/rust-lang/rust/issues/33685
11619[36868]: https://github.com/rust-lang/rust/pull/36868
11620[37127]: https://github.com/rust-lang/rust/pull/37127
11621[37229]: https://github.com/rust-lang/rust/pull/37229
11622[37456]: https://github.com/rust-lang/rust/pull/37456
11623[37527]: https://github.com/rust-lang/rust/pull/37527
11624[37602]: https://github.com/rust-lang/rust/pull/37602
11625[37613]: https://github.com/rust-lang/rust/pull/37613
11626[37615]: https://github.com/rust-lang/rust/pull/37615
11627[37636]: https://github.com/rust-lang/rust/pull/37636
11628[37627]: https://github.com/rust-lang/rust/pull/37627
11629[37642]: https://github.com/rust-lang/rust/pull/37642
11630[37677]: https://github.com/rust-lang/rust/pull/37677
11631[37699]: https://github.com/rust-lang/rust/pull/37699
11632[37701]: https://github.com/rust-lang/rust/pull/37701
11633[37705]: https://github.com/rust-lang/rust/pull/37705
11634[37749]: https://github.com/rust-lang/rust/pull/37749
11635[37760]: https://github.com/rust-lang/rust/pull/37760
11636[37763]: https://github.com/rust-lang/rust/pull/37763
11637[37764]: https://github.com/rust-lang/rust/pull/37764
11638[37789]: https://github.com/rust-lang/rust/pull/37789
11639[37791]: https://github.com/rust-lang/rust/pull/37791
11640[37814]: https://github.com/rust-lang/rust/pull/37814
11641[37817]: https://github.com/rust-lang/rust/pull/37817
11642[37834]: https://github.com/rust-lang/rust/pull/37834
11643[37848]: https://github.com/rust-lang/rust/pull/37848
11644[37855]: https://github.com/rust-lang/rust/pull/37855
11645[37882]: https://github.com/rust-lang/rust/pull/37882
11646[37888]: https://github.com/rust-lang/rust/pull/37888
11647[37973]: https://github.com/rust-lang/rust/pull/37973
11648[37979]: https://github.com/rust-lang/rust/pull/37979
11649[38086]: https://github.com/rust-lang/rust/pull/38086
11650[38107]: https://github.com/rust-lang/rust/pull/38107
11651[38117]: https://github.com/rust-lang/rust/pull/38117
11652[38134]: https://github.com/rust-lang/rust/pull/38134
11653[38146]: https://github.com/rust-lang/rust/pull/38146
11654[38181]: https://github.com/rust-lang/rust/pull/38181
11655[38182]: https://github.com/rust-lang/rust/pull/38182
11656[38185]: https://github.com/rust-lang/rust/pull/38185
11657[38192]: https://github.com/rust-lang/rust/pull/38192
11658[38279]: https://github.com/rust-lang/rust/pull/38279
11659[38835]: https://github.com/rust-lang/rust/pull/38835
11660[RFC 1506]: https://github.com/rust-lang/rfcs/blob/master/text/1506-adt-kinds.md
11661[RFC 1560]: https://github.com/rust-lang/rfcs/blob/master/text/1560-name-resolution.md
11662[RFC 1681]: https://github.com/rust-lang/rfcs/blob/master/text/1681-macros-1.1.md
11663[RFC 1717]: https://github.com/rust-lang/rfcs/blob/master/text/1717-dllimport.md
11664[`hr_lifetime_in_assoc_type` lint]: https://github.com/rust-lang/rust/issues/33685
11665[`legacy_imports`]: https://github.com/rust-lang/rust/pull/38271
11666[cargo/3102]: https://github.com/rust-lang/cargo/pull/3102
11667[cargo/3221]: https://github.com/rust-lang/cargo/pull/3221
11668[cargo/3310]: https://github.com/rust-lang/cargo/pull/3310
11669[cargo/3311]: https://github.com/rust-lang/cargo/pull/3311
11670[cargo/3319]: https://github.com/rust-lang/cargo/pull/3319
11671[cargo/3336]: https://github.com/rust-lang/cargo/pull/3336
11672[cargo/3338]: https://github.com/rust-lang/cargo/pull/3338
11673[cargo/3348]: https://github.com/rust-lang/cargo/pull/3348
11674[cargo/3356]: https://github.com/rust-lang/cargo/pull/3356
11675[cargo/3361]: https://github.com/rust-lang/cargo/pull/3361
11676[cargo/3363]: https://github.com/rust-lang/cargo/pull/3363
11677[cargo/3368]: https://github.com/rust-lang/cargo/issues/3368
11678[cargo/3409]: https://github.com/rust-lang/cargo/pull/3409
11679[cargo/3410]: https://github.com/rust-lang/cargo/pull/3410
11680[`std::iter::Iterator::min_by`]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.min_by
11681[`std::iter::Iterator::max_by`]: https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.max_by
11682[`std::os::*::fs::FileExt`]: https://doc.rust-lang.org/std/os/unix/fs/trait.FileExt.html
11683[`std::sync::atomic::Atomic*::get_mut`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicU8.html#method.get_mut
11684[`std::sync::atomic::Atomic*::into_inner`]: https://doc.rust-lang.org/std/sync/atomic/struct.AtomicU8.html#method.into_inner
11685[`std::vec::IntoIter::as_slice`]: https://doc.rust-lang.org/std/vec/struct.IntoIter.html#method.as_slice
11686[`std::vec::IntoIter::as_mut_slice`]: https://doc.rust-lang.org/std/vec/struct.IntoIter.html#method.as_mut_slice
11687[`std::sync::mpsc::Receiver::try_iter`]: https://doc.rust-lang.org/std/sync/mpsc/struct.Receiver.html#method.try_iter
11688[`std::os::unix::process::CommandExt::before_exec`]: https://doc.rust-lang.org/std/os/unix/process/trait.CommandExt.html#tymethod.before_exec
11689[`std::rc::Rc::strong_count`]: https://doc.rust-lang.org/std/rc/struct.Rc.html#method.strong_count
11690[`std::rc::Rc::weak_count`]: https://doc.rust-lang.org/std/rc/struct.Rc.html#method.weak_count
11691[`std::sync::Arc::strong_count`]: https://doc.rust-lang.org/std/sync/struct.Arc.html#method.strong_count
11692[`std::sync::Arc::weak_count`]: https://doc.rust-lang.org/std/sync/struct.Arc.html#method.weak_count
11693[`std::char::encode_utf8`]: https://doc.rust-lang.org/std/primitive.char.html#method.encode_utf8
11694[`std::char::encode_utf16`]: https://doc.rust-lang.org/std/primitive.char.html#method.encode_utf16
11695[`std::cell::Ref::clone`]: https://doc.rust-lang.org/std/cell/struct.Ref.html#method.clone
11696[`std::io::Take::into_inner`]: https://doc.rust-lang.org/std/io/struct.Take.html#method.into_inner
11697
11698
11699Version 1.14.0 (2016-12-22)
11700===========================
11701
11702Language
11703--------
11704
11705* [`..` matches multiple tuple fields in enum variants, structs
11706 and tuples][36843]. [RFC 1492].
11707* [Safe `fn` items can be coerced to `unsafe fn` pointers][37389]
11708* [`use *` and `use ::*` both glob-import from the crate root][37367]
11709* [It's now possible to call a `Vec<Box<Fn()>>` without explicit
11710 dereferencing][36822]
11711
11712Compiler
11713--------
11714
11715* [Mark enums with non-zero discriminant as non-zero][37224]
11716* [Lower-case `static mut` names are linted like other
11717 statics and consts][37162]
11718* [Fix ICE on some macros in const integer positions
11719 (e.g. `[u8; m!()]`)][36819]
11720* [Improve error message and snippet for "did you mean `x`"][36798]
11721* [Add a panic-strategy field to the target specification][36794]
11722* [Include LLVM version in `--version --verbose`][37200]
11723
11724Compile-time Optimizations
11725--------------------------
11726
11727* [Improve macro expansion performance][37569]
11728* [Shrink `Expr_::ExprInlineAsm`][37445]
11729* [Replace all uses of SHA-256 with BLAKE2b][37439]
11730* [Reduce the number of bytes hashed by `IchHasher`][37427]
11731* [Avoid more allocations when compiling html5ever][37373]
11732* [Use `SmallVector` in `CombineFields::instantiate`][37322]
11733* [Avoid some allocations in the macro parser][37318]
11734* [Use a faster deflate setting][37298]
11735* [Add `ArrayVec` and `AccumulateVec` to reduce heap allocations
11736 during interning of slices][37270]
11737* [Optimize `write_metadata`][37267]
11738* [Don't process obligation forest cycles when stalled][37231]
11739* [Avoid many `CrateConfig` clones][37161]
11740* [Optimize `Substs::super_fold_with`][37108]
11741* [Optimize `ObligationForest`'s `NodeState` handling][36993]
11742* [Speed up `plug_leaks`][36917]
11743
11744Libraries
11745---------
11746
11747* [`println!()`, with no arguments, prints newline][36825].
11748 Previously, an empty string was required to achieve the same.
11749* [`Wrapping` impls standard binary and unary operators, as well as
11750 the `Sum` and `Product` iterators][37356]
11751* [Implement `From<Cow<str>> for String` and `From<Cow<[T]>> for
11752 Vec<T>`][37326]
11753* [Improve `fold` performance for `chain`, `cloned`, `map`, and
11754 `VecDeque` iterators][37315]
11755* [Improve `SipHasher` performance on small values][37312]
11756* [Add Iterator trait TrustedLen to enable better FromIterator /
11757 Extend][37306]
11758* [Expand `.zip()` specialization to `.map()` and `.cloned()`][37230]
11759* [`ReadDir` implements `Debug`][37221]
11760* [Implement `RefUnwindSafe` for atomic types][37178]
11761* [Specialize `Vec::extend` to `Vec::extend_from_slice`][37094]
11762* [Avoid allocations in `Decoder::read_str`][37064]
11763* [`io::Error` implements `From<io::ErrorKind>`][37037]
11764* [Impl `Debug` for raw pointers to unsized data][36880]
11765* [Don't reuse `HashMap` random seeds][37470]
11766* [The internal memory layout of `HashMap` is more cache-friendly, for
11767 significant improvements in some operations][36692]
11768* [`HashMap` uses less memory on 32-bit architectures][36595]
11769* [Impl `Add<{str, Cow<str>}>` for `Cow<str>`][36430]
11770
11771Cargo
11772-----
11773
11774* [Expose rustc cfg values to build scripts][cargo/3243]
11775* [Allow cargo to work with read-only `CARGO_HOME`][cargo/3259]
11776* [Fix passing --features when testing multiple packages][cargo/3280]
11777* [Use a single profile set per workspace][cargo/3249]
11778* [Load `replace` sections from lock files][cargo/3220]
11779* [Ignore `panic` configuration for test/bench profiles][cargo/3175]
11780
11781Tooling
11782-------
11783
11784* [rustup is the recommended Rust installation method][1.14rustup]
11785* This release includes host (rustc) builds for Linux on MIPS, PowerPC, and
11786 S390x. These are [tier 2] platforms and may have major defects. Follow the
11787 instructions on the website to install, or add the targets to an existing
11788 installation with `rustup target add`. The new target triples are:
11789 - `mips-unknown-linux-gnu`
11790 - `mipsel-unknown-linux-gnu`
11791 - `mips64-unknown-linux-gnuabi64`
11792 - `mips64el-unknown-linux-gnuabi64 `
11793 - `powerpc-unknown-linux-gnu`
11794 - `powerpc64-unknown-linux-gnu`
11795 - `powerpc64le-unknown-linux-gnu`
11796 - `s390x-unknown-linux-gnu `
11797* This release includes target (std) builds for ARM Linux running MUSL
11798 libc. These are [tier 2] platforms and may have major defects. Add the
11799 following triples to an existing rustup installation with `rustup target add`:
11800 - `arm-unknown-linux-musleabi`
11801 - `arm-unknown-linux-musleabihf`
11802 - `armv7-unknown-linux-musleabihf`
11803* This release includes [experimental support for WebAssembly][1.14wasm], via
11804 the `wasm32-unknown-emscripten` target. This target is known to have major
11805 defects. Please test, report, and fix.
11806* rustup no longer installs documentation by default. Run `rustup
11807 component add rust-docs` to install.
11808* [Fix line stepping in debugger][37310]
11809* [Enable line number debuginfo in releases][37280]
11810
11811Misc
11812----
11813
11814* [Disable jemalloc on aarch64/powerpc/mips][37392]
11815* [Add support for Fuchsia OS][37313]
11816* [Detect local-rebuild by only MAJOR.MINOR version][37273]
11817
11818Compatibility Notes
11819-------------------
11820
11821* [A number of forward-compatibility lints used by the compiler
11822 to gradually introduce language changes have been converted
11823 to deny by default][36894]:
11824 - ["use of inaccessible extern crate erroneously allowed"][36886]
11825 - ["type parameter default erroneously allowed in invalid location"][36887]
11826 - ["detects super or self keywords at the beginning of global path"][36888]
11827 - ["two overlapping inherent impls define an item with the same name
11828 were erroneously allowed"][36889]
11829 - ["floating-point constants cannot be used in patterns"][36890]
11830 - ["constants of struct or enum type can only be used in a pattern if
11831 the struct or enum has `#[derive(PartialEq, Eq)]`"][36891]
11832 - ["lifetimes or labels named `'_` were erroneously allowed"][36892]
11833* [Prohibit patterns in trait methods without bodies][37378]
11834* [The atomic `Ordering` enum may not be matched exhaustively][37351]
11835* [Future-proofing `#[no_link]` breaks some obscure cases][37247]
11836* [The `$crate` macro variable is accepted in fewer locations][37213]
11837* [Impls specifying extra region requirements beyond the trait
11838 they implement are rejected][37167]
11839* [Enums may not be unsized][37111]. Unsized enums are intended to
11840 work but never have. For now they are forbidden.
11841* [Enforce the shadowing restrictions from RFC 1560 for today's macros][36767]
11842
11843[tier 2]: https://forge.rust-lang.org/platform-support.html
11844[1.14rustup]: https://internals.rust-lang.org/t/beta-testing-rustup-rs/3316/204
11845[1.14wasm]: https://users.rust-lang.org/t/compiling-to-the-web-with-rust-and-emscripten/7627
11846[36430]: https://github.com/rust-lang/rust/pull/36430
11847[36595]: https://github.com/rust-lang/rust/pull/36595
11848[36692]: https://github.com/rust-lang/rust/pull/36692
11849[36767]: https://github.com/rust-lang/rust/pull/36767
11850[36794]: https://github.com/rust-lang/rust/pull/36794
11851[36798]: https://github.com/rust-lang/rust/pull/36798
11852[36819]: https://github.com/rust-lang/rust/pull/36819
11853[36822]: https://github.com/rust-lang/rust/pull/36822
11854[36825]: https://github.com/rust-lang/rust/pull/36825
11855[36843]: https://github.com/rust-lang/rust/pull/36843
11856[36880]: https://github.com/rust-lang/rust/pull/36880
11857[36886]: https://github.com/rust-lang/rust/issues/36886
11858[36887]: https://github.com/rust-lang/rust/issues/36887
11859[36888]: https://github.com/rust-lang/rust/issues/36888
11860[36889]: https://github.com/rust-lang/rust/issues/36889
11861[36890]: https://github.com/rust-lang/rust/issues/36890
11862[36891]: https://github.com/rust-lang/rust/issues/36891
11863[36892]: https://github.com/rust-lang/rust/issues/36892
11864[36894]: https://github.com/rust-lang/rust/pull/36894
11865[36917]: https://github.com/rust-lang/rust/pull/36917
11866[36993]: https://github.com/rust-lang/rust/pull/36993
11867[37037]: https://github.com/rust-lang/rust/pull/37037
11868[37064]: https://github.com/rust-lang/rust/pull/37064
11869[37094]: https://github.com/rust-lang/rust/pull/37094
11870[37108]: https://github.com/rust-lang/rust/pull/37108
11871[37111]: https://github.com/rust-lang/rust/pull/37111
11872[37161]: https://github.com/rust-lang/rust/pull/37161
11873[37162]: https://github.com/rust-lang/rust/pull/37162
11874[37167]: https://github.com/rust-lang/rust/pull/37167
11875[37178]: https://github.com/rust-lang/rust/pull/37178
11876[37200]: https://github.com/rust-lang/rust/pull/37200
11877[37213]: https://github.com/rust-lang/rust/pull/37213
11878[37221]: https://github.com/rust-lang/rust/pull/37221
11879[37224]: https://github.com/rust-lang/rust/pull/37224
11880[37230]: https://github.com/rust-lang/rust/pull/37230
11881[37231]: https://github.com/rust-lang/rust/pull/37231
11882[37247]: https://github.com/rust-lang/rust/pull/37247
11883[37267]: https://github.com/rust-lang/rust/pull/37267
11884[37270]: https://github.com/rust-lang/rust/pull/37270
11885[37273]: https://github.com/rust-lang/rust/pull/37273
11886[37280]: https://github.com/rust-lang/rust/pull/37280
11887[37298]: https://github.com/rust-lang/rust/pull/37298
11888[37306]: https://github.com/rust-lang/rust/pull/37306
11889[37310]: https://github.com/rust-lang/rust/pull/37310
11890[37312]: https://github.com/rust-lang/rust/pull/37312
11891[37313]: https://github.com/rust-lang/rust/pull/37313
11892[37315]: https://github.com/rust-lang/rust/pull/37315
11893[37318]: https://github.com/rust-lang/rust/pull/37318
11894[37322]: https://github.com/rust-lang/rust/pull/37322
11895[37326]: https://github.com/rust-lang/rust/pull/37326
11896[37351]: https://github.com/rust-lang/rust/pull/37351
11897[37356]: https://github.com/rust-lang/rust/pull/37356
11898[37367]: https://github.com/rust-lang/rust/pull/37367
11899[37373]: https://github.com/rust-lang/rust/pull/37373
11900[37378]: https://github.com/rust-lang/rust/pull/37378
11901[37389]: https://github.com/rust-lang/rust/pull/37389
11902[37392]: https://github.com/rust-lang/rust/pull/37392
11903[37427]: https://github.com/rust-lang/rust/pull/37427
11904[37439]: https://github.com/rust-lang/rust/pull/37439
11905[37445]: https://github.com/rust-lang/rust/pull/37445
11906[37470]: https://github.com/rust-lang/rust/pull/37470
11907[37569]: https://github.com/rust-lang/rust/pull/37569
11908[RFC 1492]: https://github.com/rust-lang/rfcs/blob/master/text/1492-dotdot-in-patterns.md
11909[cargo/3175]: https://github.com/rust-lang/cargo/pull/3175
11910[cargo/3220]: https://github.com/rust-lang/cargo/pull/3220
11911[cargo/3243]: https://github.com/rust-lang/cargo/pull/3243
11912[cargo/3249]: https://github.com/rust-lang/cargo/pull/3249
11913[cargo/3259]: https://github.com/rust-lang/cargo/pull/3259
11914[cargo/3280]: https://github.com/rust-lang/cargo/pull/3280
11915
11916
11917Version 1.13.0 (2016-11-10)
11918===========================
11919
11920Language
11921--------
11922
11923* [Stabilize the `?` operator][36995]. `?` is a simple way to propagate
11924 errors, like the `try!` macro, described in [RFC 0243].
11925* [Stabilize macros in type position][36014]. Described in [RFC 873].
11926* [Stabilize attributes on statements][36995]. Described in [RFC 0016].
11927* [Fix `#[derive]` for empty tuple structs/variants][35728]
11928* [Fix lifetime rules for 'if' conditions][36029]
11929* [Avoid loading and parsing unconfigured non-inline modules][36482]
11930
11931Compiler
11932--------
11933
11934* [Add the `-C link-arg` argument][36574]
11935* [Remove the old AST-based backend from rustc_trans][35764]
11936* [Don't enable NEON by default on armv7 Linux][35814]
11937* [Fix debug line number info for macro expansions][35238]
11938* [Do not emit "class method" debuginfo for types that are not
11939 DICompositeType][36008]
11940* [Warn about multiple conflicting #[repr] hints][34623]
11941* [When sizing DST, don't double-count nested struct prefixes][36351]
11942* [Default RUST_MIN_STACK to 16MiB for now][36505]
11943* [Improve rlib metadata format][36551]. Reduces rlib size significantly.
11944* [Reject macros with empty repetitions to avoid infinite loop][36721]
11945* [Expand macros without recursing to avoid stack overflows][36214]
11946
11947Diagnostics
11948-----------
11949
11950* [Replace macro backtraces with labeled local uses][35702]
11951* [Improve error message for misplaced doc comments][33922]
11952* [Buffer unix and lock windows to prevent message interleaving][35975]
11953* [Update lifetime errors to specifically note temporaries][36171]
11954* [Special case a few colors for Windows][36178]
11955* [Suggest `use self` when such an import resolves][36289]
11956* [Be more specific when type parameter shadows primitive type][36338]
11957* Many minor improvements
11958
11959Compile-time Optimizations
11960--------------------------
11961
11962* [Compute and cache HIR hashes at beginning][35854]
11963* [Don't hash types in loan paths][36004]
11964* [Cache projections in trans][35761]
11965* [Optimize the parser's last token handling][36527]
11966* [Only instantiate #[inline] functions in codegen units referencing
11967 them][36524]. This leads to big improvements in cases where crates export
11968 define many inline functions without using them directly.
11969* [Lazily allocate TypedArena's first chunk][36592]
11970* [Don't allocate during default HashSet creation][36734]
11971
11972Stabilized APIs
11973---------------
11974
11975* [`checked_abs`]
11976* [`wrapping_abs`]
11977* [`overflowing_abs`]
11978* [`RefCell::try_borrow`]
11979* [`RefCell::try_borrow_mut`]
11980
11981Libraries
11982---------
11983
11984* [Add `assert_ne!` and `debug_assert_ne!`][35074]
11985* [Make `vec_deque::Drain`, `hash_map::Drain`, and `hash_set::Drain`
11986 covariant][35354]
11987* [Implement `AsRef<[T]>` for `std::slice::Iter`][35559]
11988* [Implement `Debug` for `std::vec::IntoIter`][35707]
11989* [`CString`: avoid excessive growth just to 0-terminate][35871]
11990* [Implement `CoerceUnsized` for `{Cell, RefCell, UnsafeCell}`][35627]
11991* [Use arc4rand on FreeBSD][35884]
11992* [memrchr: Correct aligned offset computation][35969]
11993* [Improve Demangling of Rust Symbols][36059]
11994* [Use monotonic time in condition variables][35048]
11995* [Implement `Debug` for `std::path::{Components,Iter}`][36101]
11996* [Implement conversion traits for `char`][35755]
11997* [Fix illegal instruction caused by overflow in channel cloning][36104]
11998* [Zero first byte of CString on drop][36264]
11999* [Inherit overflow checks for sum and product][36372]
12000* [Add missing Eq implementations][36423]
12001* [Implement `Debug` for `DirEntry`][36631]
12002* [When `getaddrinfo` returns `EAI_SYSTEM` retrieve actual error from
12003 `errno`][36754]
12004* [`SipHasher`] is deprecated. Use [`DefaultHasher`].
12005* [Implement more traits for `std::io::ErrorKind`][35911]
12006* [Optimize BinaryHeap bounds checking][36072]
12007* [Work around pointer aliasing issue in `Vec::extend_from_slice`,
12008 `extend_with_element`][36355]
12009* [Fix overflow checking in unsigned pow()][34942]
12010
12011Cargo
12012-----
12013
12014* This release includes security fixes to both curl and OpenSSL.
12015* [Fix transitive doctests when panic=abort][cargo/3021]
12016* [Add --all-features flag to cargo][cargo/3038]
12017* [Reject path-based dependencies in `cargo package`][cargo/3060]
12018* [Don't parse the home directory more than once][cargo/3078]
12019* [Don't try to generate Cargo.lock on empty workspaces][cargo/3092]
12020* [Update OpenSSL to 1.0.2j][cargo/3121]
12021* [Add license and license_file to cargo metadata output][cargo/3110]
12022* [Make crates-io registry URL optional in config; ignore all changes to
12023 source.crates-io][cargo/3089]
12024* [Don't download dependencies from other platforms][cargo/3123]
12025* [Build transitive dev-dependencies when needed][cargo/3125]
12026* [Add support for per-target rustflags in .cargo/config][cargo/3157]
12027* [Avoid updating registry when adding existing deps][cargo/3144]
12028* [Warn about path overrides that won't work][cargo/3136]
12029* [Use workspaces during `cargo install`][cargo/3146]
12030* [Leak mspdbsrv.exe processes on Windows][cargo/3162]
12031* [Add --message-format flag][cargo/3000]
12032* [Pass target environment for rustdoc][cargo/3205]
12033* [Use `CommandExt::exec` for `cargo run` on Unix][cargo/2818]
12034* [Update curl and curl-sys][cargo/3241]
12035* [Call rustdoc test with the correct cfg flags of a package][cargo/3242]
12036
12037Tooling
12038-------
12039
12040* [rustdoc: Add the `--sysroot` argument][36586]
12041* [rustdoc: Fix a couple of issues with the search results][35655]
12042* [rustdoc: remove the `!` from macro URLs and titles][35234]
12043* [gdb: Fix pretty-printing special-cased Rust types][35585]
12044* [rustdoc: Filter more incorrect methods inherited through Deref][36266]
12045
12046Misc
12047----
12048
12049* [Remove unmaintained style guide][35124]
12050* [Add s390x support][36369]
12051* [Initial work at Haiku OS support][36727]
12052* [Add mips-uclibc targets][35734]
12053* [Crate-ify compiler-rt into compiler-builtins][35021]
12054* [Add rustc version info (git hash + date) to dist tarball][36213]
12055* Many documentation improvements
12056
12057Compatibility Notes
12058-------------------
12059
12060* [`SipHasher`] is deprecated. Use [`DefaultHasher`].
12061* [Deny (by default) transmuting from fn item types to pointer-sized
12062 types][34923]. Continuing the long transition to zero-sized fn items,
12063 per [RFC 401].
12064* [Fix `#[derive]` for empty tuple structs/variants][35728].
12065 Part of [RFC 1506].
12066* [Issue deprecation warnings for safe accesses to extern statics][36173]
12067* [Fix lifetime rules for 'if' conditions][36029].
12068* [Inherit overflow checks for sum and product][36372].
12069* [Forbid user-defined macros named "macro_rules"][36730].
12070
12071[33922]: https://github.com/rust-lang/rust/pull/33922
12072[34623]: https://github.com/rust-lang/rust/pull/34623
12073[34923]: https://github.com/rust-lang/rust/pull/34923
12074[34942]: https://github.com/rust-lang/rust/pull/34942
12075[35021]: https://github.com/rust-lang/rust/pull/35021
12076[35048]: https://github.com/rust-lang/rust/pull/35048
12077[35074]: https://github.com/rust-lang/rust/pull/35074
12078[35124]: https://github.com/rust-lang/rust/pull/35124
12079[35234]: https://github.com/rust-lang/rust/pull/35234
12080[35238]: https://github.com/rust-lang/rust/pull/35238
12081[35354]: https://github.com/rust-lang/rust/pull/35354
12082[35559]: https://github.com/rust-lang/rust/pull/35559
12083[35585]: https://github.com/rust-lang/rust/pull/35585
12084[35627]: https://github.com/rust-lang/rust/pull/35627
12085[35655]: https://github.com/rust-lang/rust/pull/35655
12086[35702]: https://github.com/rust-lang/rust/pull/35702
12087[35707]: https://github.com/rust-lang/rust/pull/35707
12088[35728]: https://github.com/rust-lang/rust/pull/35728
12089[35734]: https://github.com/rust-lang/rust/pull/35734
12090[35755]: https://github.com/rust-lang/rust/pull/35755
12091[35761]: https://github.com/rust-lang/rust/pull/35761
12092[35764]: https://github.com/rust-lang/rust/pull/35764
12093[35814]: https://github.com/rust-lang/rust/pull/35814
12094[35854]: https://github.com/rust-lang/rust/pull/35854
12095[35871]: https://github.com/rust-lang/rust/pull/35871
12096[35884]: https://github.com/rust-lang/rust/pull/35884
12097[35911]: https://github.com/rust-lang/rust/pull/35911
12098[35969]: https://github.com/rust-lang/rust/pull/35969
12099[35975]: https://github.com/rust-lang/rust/pull/35975
12100[36004]: https://github.com/rust-lang/rust/pull/36004
12101[36008]: https://github.com/rust-lang/rust/pull/36008
12102[36014]: https://github.com/rust-lang/rust/pull/36014
12103[36029]: https://github.com/rust-lang/rust/pull/36029
12104[36059]: https://github.com/rust-lang/rust/pull/36059
12105[36072]: https://github.com/rust-lang/rust/pull/36072
12106[36101]: https://github.com/rust-lang/rust/pull/36101
12107[36104]: https://github.com/rust-lang/rust/pull/36104
12108[36171]: https://github.com/rust-lang/rust/pull/36171
12109[36173]: https://github.com/rust-lang/rust/pull/36173
12110[36178]: https://github.com/rust-lang/rust/pull/36178
12111[36213]: https://github.com/rust-lang/rust/pull/36213
12112[36214]: https://github.com/rust-lang/rust/pull/36214
12113[36264]: https://github.com/rust-lang/rust/pull/36264
12114[36266]: https://github.com/rust-lang/rust/pull/36266
12115[36289]: https://github.com/rust-lang/rust/pull/36289
12116[36338]: https://github.com/rust-lang/rust/pull/36338
12117[36351]: https://github.com/rust-lang/rust/pull/36351
12118[36355]: https://github.com/rust-lang/rust/pull/36355
12119[36369]: https://github.com/rust-lang/rust/pull/36369
12120[36372]: https://github.com/rust-lang/rust/pull/36372
12121[36423]: https://github.com/rust-lang/rust/pull/36423
12122[36482]: https://github.com/rust-lang/rust/pull/36482
12123[36505]: https://github.com/rust-lang/rust/pull/36505
12124[36524]: https://github.com/rust-lang/rust/pull/36524
12125[36527]: https://github.com/rust-lang/rust/pull/36527
12126[36551]: https://github.com/rust-lang/rust/pull/36551
12127[36574]: https://github.com/rust-lang/rust/pull/36574
12128[36586]: https://github.com/rust-lang/rust/pull/36586
12129[36592]: https://github.com/rust-lang/rust/pull/36592
12130[36631]: https://github.com/rust-lang/rust/pull/36631
12131[36721]: https://github.com/rust-lang/rust/pull/36721
12132[36727]: https://github.com/rust-lang/rust/pull/36727
12133[36730]: https://github.com/rust-lang/rust/pull/36730
12134[36734]: https://github.com/rust-lang/rust/pull/36734
12135[36754]: https://github.com/rust-lang/rust/pull/36754
12136[36995]: https://github.com/rust-lang/rust/pull/36995
12137[RFC 0016]: https://github.com/rust-lang/rfcs/blob/master/text/0016-more-attributes.md
12138[RFC 0243]: https://github.com/rust-lang/rfcs/blob/master/text/0243-trait-based-exception-handling.md
12139[RFC 1506]: https://github.com/rust-lang/rfcs/blob/master/text/1506-adt-kinds.md
12140[RFC 401]: https://github.com/rust-lang/rfcs/blob/master/text/0401-coercions.md
12141[RFC 873]: https://github.com/rust-lang/rfcs/blob/master/text/0873-type-macros.md
12142[cargo/2818]: https://github.com/rust-lang/cargo/pull/2818
12143[cargo/3000]: https://github.com/rust-lang/cargo/pull/3000
12144[cargo/3021]: https://github.com/rust-lang/cargo/pull/3021
12145[cargo/3038]: https://github.com/rust-lang/cargo/pull/3038
12146[cargo/3060]: https://github.com/rust-lang/cargo/pull/3060
12147[cargo/3078]: https://github.com/rust-lang/cargo/pull/3078
12148[cargo/3089]: https://github.com/rust-lang/cargo/pull/3089
12149[cargo/3092]: https://github.com/rust-lang/cargo/pull/3092
12150[cargo/3110]: https://github.com/rust-lang/cargo/pull/3110
12151[cargo/3121]: https://github.com/rust-lang/cargo/pull/3121
12152[cargo/3123]: https://github.com/rust-lang/cargo/pull/3123
12153[cargo/3125]: https://github.com/rust-lang/cargo/pull/3125
12154[cargo/3136]: https://github.com/rust-lang/cargo/pull/3136
12155[cargo/3144]: https://github.com/rust-lang/cargo/pull/3144
12156[cargo/3146]: https://github.com/rust-lang/cargo/pull/3146
12157[cargo/3157]: https://github.com/rust-lang/cargo/pull/3157
12158[cargo/3162]: https://github.com/rust-lang/cargo/pull/3162
12159[cargo/3205]: https://github.com/rust-lang/cargo/pull/3205
12160[cargo/3241]: https://github.com/rust-lang/cargo/pull/3241
12161[cargo/3242]: https://github.com/rust-lang/cargo/pull/3242
12162[`checked_abs`]: https://doc.rust-lang.org/std/primitive.i32.html#method.checked_abs
12163[`wrapping_abs`]: https://doc.rust-lang.org/std/primitive.i32.html#method.wrapping_abs
12164[`overflowing_abs`]: https://doc.rust-lang.org/std/primitive.i32.html#method.overflowing_abs
12165[`RefCell::try_borrow`]: https://doc.rust-lang.org/std/cell/struct.RefCell.html#method.try_borrow
12166[`RefCell::try_borrow_mut`]: https://doc.rust-lang.org/std/cell/struct.RefCell.html#method.try_borrow_mut
12167[`SipHasher`]: https://doc.rust-lang.org/std/hash/struct.SipHasher.html
12168[`DefaultHasher`]: https://doc.rust-lang.org/std/collections/hash_map/struct.DefaultHasher.html
12169
12170
12171Version 1.12.1 (2016-10-20)
12172===========================
12173
12174Regression Fixes
12175----------------
12176
12177* [ICE: 'rustc' panicked at 'assertion failed: concrete_substs.is_normalized_for_trans()' #36381][36381]
12178* [Confusion with double negation and booleans][36856]
12179* [rustc 1.12.0 fails with SIGSEGV in release mode (syn crate 0.8.0)][36875]
12180* [Rustc 1.12.0 Windows build of `ethcore` crate fails with LLVM error][36924]
12181* [1.12.0: High memory usage when linking in release mode with debug info][36926]
12182* [Corrupted memory after updated to 1.12][36936]
12183* ["Let NullaryConstructor = something;" causes internal compiler error: "tried to overwrite interned AdtDef"][37026]
12184* [Fix ICE: inject bitcast if types mismatch for invokes/calls/stores][37112]
12185* [debuginfo: Handle spread_arg case in MIR-trans in a more stable way.][37153]
12186
12187[36381]: https://github.com/rust-lang/rust/issues/36381
12188[36856]: https://github.com/rust-lang/rust/issues/36856
12189[36875]: https://github.com/rust-lang/rust/issues/36875
12190[36924]: https://github.com/rust-lang/rust/issues/36924
12191[36926]: https://github.com/rust-lang/rust/issues/36926
12192[36936]: https://github.com/rust-lang/rust/issues/36936
12193[37026]: https://github.com/rust-lang/rust/issues/37026
12194[37112]: https://github.com/rust-lang/rust/issues/37112
12195[37153]: https://github.com/rust-lang/rust/issues/37153
12196
12197
12198Version 1.12.0 (2016-09-29)
12199===========================
12200
12201Highlights
12202----------
12203
12204* [`rustc` translates code to LLVM IR via its own "middle" IR (MIR)](https://github.com/rust-lang/rust/pull/34096).
12205 This translation pass is far simpler than the previous AST->LLVM pass, and
12206 creates opportunities to perform new optimizations directly on the MIR. It
12207 was previously described [on the Rust blog](https://blog.rust-lang.org/2016/04/19/MIR.html).
12208* [`rustc` presents a new, more readable error format, along with
12209 machine-readable JSON error output for use by IDEs](https://github.com/rust-lang/rust/pull/35401).
12210 Most common editors supporting Rust have been updated to work with it. It was
12211 previously described [on the Rust blog](https://blog.rust-lang.org/2016/08/10/Shape-of-errors-to-come.html).
12212
12213Compiler
12214--------
12215
12216* [`rustc` translates code to LLVM IR via its own "middle" IR (MIR)](https://github.com/rust-lang/rust/pull/34096).
12217 This translation pass is far simpler than the previous AST->LLVM pass, and
12218 creates opportunities to perform new optimizations directly on the MIR. It
12219 was previously described [on the Rust blog](https://blog.rust-lang.org/2016/04/19/MIR.html).
12220* [Print the Rust target name, not the LLVM target name, with
12221 `--print target-list`](https://github.com/rust-lang/rust/pull/35489)
12222* [The computation of `TypeId` is correct in some cases where it was previously
12223 producing inconsistent results](https://github.com/rust-lang/rust/pull/35267)
12224* [The `mips-unknown-linux-gnu` target uses hardware floating point by default](https://github.com/rust-lang/rust/pull/34910)
12225* [The `rustc` arguments, `--print target-cpus`, `--print target-features`,
12226 `--print relocation-models`, and `--print code-models` print the available
12227 options to the `-C target-cpu`, `-C target-feature`, `-C relocation-model` and
12228 `-C code-model` code generation arguments](https://github.com/rust-lang/rust/pull/34845)
12229* [`rustc` supports three new MUSL targets on ARM: `arm-unknown-linux-musleabi`,
12230 `arm-unknown-linux-musleabihf`, and `armv7-unknown-linux-musleabihf`](https://github.com/rust-lang/rust/pull/35060).
12231 These targets produce statically-linked binaries. There are no binary release
12232 builds yet though.
12233
12234Diagnostics
12235-----------
12236
12237* [`rustc` presents a new, more readable error format, along with
12238 machine-readable JSON error output for use by IDEs](https://github.com/rust-lang/rust/pull/35401).
12239 Most common editors supporting Rust have been updated to work with it. It was
12240 previously described [on the Rust blog](https://blog.rust-lang.org/2016/08/10/Shape-of-errors-to-come.html).
12241* [In error descriptions, references are now described in plain English,
12242 instead of as "&-ptr"](https://github.com/rust-lang/rust/pull/35611)
12243* [In error type descriptions, unknown numeric types are named `{integer}` or
12244 `{float}` instead of `_`](https://github.com/rust-lang/rust/pull/35080)
12245* [`rustc` emits a clearer error when inner attributes follow a doc comment](https://github.com/rust-lang/rust/pull/34676)
12246
12247Language
12248--------
12249
12250* [`macro_rules!` invocations can be made within `macro_rules!` invocations](https://github.com/rust-lang/rust/pull/34925)
12251* [`macro_rules!` meta-variables are hygienic](https://github.com/rust-lang/rust/pull/35453)
12252* [`macro_rules!` `tt` matchers can be reparsed correctly, making them much more
12253 useful](https://github.com/rust-lang/rust/pull/34908)
12254* [`macro_rules!` `stmt` matchers correctly consume the entire contents when
12255 inside non-braces invocations](https://github.com/rust-lang/rust/pull/34886)
12256* [Semicolons are properly required as statement delimiters inside
12257 `macro_rules!` invocations](https://github.com/rust-lang/rust/pull/34660)
12258* [`cfg_attr` works on `path` attributes](https://github.com/rust-lang/rust/pull/34546)
12259
12260Stabilized APIs
12261---------------
12262
12263* [`Cell::as_ptr`](https://doc.rust-lang.org/std/cell/struct.Cell.html#method.as_ptr)
12264* [`RefCell::as_ptr`](https://doc.rust-lang.org/std/cell/struct.RefCell.html#method.as_ptr)
12265* [`IpAddr::is_unspecified`](https://doc.rust-lang.org/std/net/enum.IpAddr.html#method.is_unspecified)
12266* [`IpAddr::is_loopback`](https://doc.rust-lang.org/std/net/enum.IpAddr.html#method.is_loopback)
12267* [`IpAddr::is_multicast`](https://doc.rust-lang.org/std/net/enum.IpAddr.html#method.is_multicast)
12268* [`Ipv4Addr::is_unspecified`](https://doc.rust-lang.org/std/net/struct.Ipv4Addr.html#method.is_unspecified)
12269* [`Ipv6Addr::octets`](https://doc.rust-lang.org/std/net/struct.Ipv6Addr.html#method.octets)
12270* [`LinkedList::contains`](https://doc.rust-lang.org/std/collections/linked_list/struct.LinkedList.html#method.contains)
12271* [`VecDeque::contains`](https://doc.rust-lang.org/std/collections/vec_deque/struct.VecDeque.html#method.contains)
12272* [`ExitStatusExt::from_raw`](https://doc.rust-lang.org/std/os/unix/process/trait.ExitStatusExt.html#tymethod.from_raw).
12273 Both on Unix and Windows.
12274* [`Receiver::recv_timeout`](https://doc.rust-lang.org/std/sync/mpsc/struct.Receiver.html#method.recv_timeout)
12275* [`RecvTimeoutError`](https://doc.rust-lang.org/std/sync/mpsc/enum.RecvTimeoutError.html)
12276* [`BinaryHeap::peek_mut`](https://doc.rust-lang.org/std/collections/binary_heap/struct.BinaryHeap.html#method.peek_mut)
12277* [`PeekMut`](https://doc.rust-lang.org/std/collections/binary_heap/struct.PeekMut.html)
12278* [`iter::Product`](https://doc.rust-lang.org/std/iter/trait.Product.html)
12279* [`iter::Sum`](https://doc.rust-lang.org/std/iter/trait.Sum.html)
12280* [`OccupiedEntry::remove_entry`](https://doc.rust-lang.org/std/collections/btree_map/struct.OccupiedEntry.html#method.remove_entry)
12281* [`VacantEntry::into_key`](https://doc.rust-lang.org/std/collections/btree_map/struct.VacantEntry.html#method.into_key)
12282
12283Libraries
12284---------
12285
12286* [The `format!` macro and friends now allow a single argument to be formatted
12287 in multiple styles](https://github.com/rust-lang/rust/pull/33642)
12288* [The lifetime bounds on `[T]::binary_search_by` and
12289 `[T]::binary_search_by_key` have been adjusted to be more flexible](https://github.com/rust-lang/rust/pull/34762)
12290* [`Option` implements `From` for its contained type](https://github.com/rust-lang/rust/pull/34828)
12291* [`Cell`, `RefCell` and `UnsafeCell` implement `From` for their contained type](https://github.com/rust-lang/rust/pull/35392)
12292* [`RwLock` panics if the reader count overflows](https://github.com/rust-lang/rust/pull/35378)
12293* [`vec_deque::Drain`, `hash_map::Drain` and `hash_set::Drain` are covariant](https://github.com/rust-lang/rust/pull/35354)
12294* [`vec::Drain` and `binary_heap::Drain` are covariant](https://github.com/rust-lang/rust/pull/34951)
12295* [`Cow<str>` implements `FromIterator` for `char`, `&str` and `String`](https://github.com/rust-lang/rust/pull/35064)
12296* [Sockets on Linux are correctly closed in subprocesses via `SOCK_CLOEXEC`](https://github.com/rust-lang/rust/pull/34946)
12297* [`hash_map::Entry`, `hash_map::VacantEntry` and `hash_map::OccupiedEntry`
12298 implement `Debug`](https://github.com/rust-lang/rust/pull/34937)
12299* [`btree_map::Entry`, `btree_map::VacantEntry` and `btree_map::OccupiedEntry`
12300 implement `Debug`](https://github.com/rust-lang/rust/pull/34885)
12301* [`String` implements `AddAssign`](https://github.com/rust-lang/rust/pull/34890)
12302* [Variadic `extern fn` pointers implement the `Clone`, `PartialEq`, `Eq`,
12303 `PartialOrd`, `Ord`, `Hash`, `fmt::Pointer`, and `fmt::Debug` traits](https://github.com/rust-lang/rust/pull/34879)
12304* [`FileType` implements `Debug`](https://github.com/rust-lang/rust/pull/34757)
12305* [References to `Mutex` and `RwLock` are unwind-safe](https://github.com/rust-lang/rust/pull/34756)
12306* [`mpsc::sync_channel` `Receiver`s return any available message before
12307 reporting a disconnect](https://github.com/rust-lang/rust/pull/34731)
12308* [Unicode definitions have been updated to 9.0](https://github.com/rust-lang/rust/pull/34599)
12309* [`env` iterators implement `DoubleEndedIterator`](https://github.com/rust-lang/rust/pull/33312)
12310
12311Cargo
12312-----
12313
12314* [Support local mirrors of registries](https://github.com/rust-lang/cargo/pull/2857)
12315* [Add support for command aliases](https://github.com/rust-lang/cargo/pull/2679)
12316* [Allow `opt-level="s"` / `opt-level="z"` in profile overrides](https://github.com/rust-lang/cargo/pull/3007)
12317* [Make `cargo doc --open --target` work as expected](https://github.com/rust-lang/cargo/pull/2988)
12318* [Speed up noop registry updates](https://github.com/rust-lang/cargo/pull/2974)
12319* [Update OpenSSL](https://github.com/rust-lang/cargo/pull/2971)
12320* [Fix `--panic=abort` with plugins](https://github.com/rust-lang/cargo/pull/2954)
12321* [Always pass `-C metadata` to the compiler](https://github.com/rust-lang/cargo/pull/2946)
12322* [Fix depending on git repos with workspaces](https://github.com/rust-lang/cargo/pull/2938)
12323* [Add a `--lib` flag to `cargo new`](https://github.com/rust-lang/cargo/pull/2921)
12324* [Add `http.cainfo` for custom certs](https://github.com/rust-lang/cargo/pull/2917)
12325* [Indicate the compilation profile after compiling](https://github.com/rust-lang/cargo/pull/2909)
12326* [Allow enabling features for dependencies with `--features`](https://github.com/rust-lang/cargo/pull/2876)
12327* [Add `--jobs` flag to `cargo package`](https://github.com/rust-lang/cargo/pull/2867)
12328* [Add `--dry-run` to `cargo publish`](https://github.com/rust-lang/cargo/pull/2849)
12329* [Add support for `RUSTDOCFLAGS`](https://github.com/rust-lang/cargo/pull/2794)
12330
12331Performance
12332-----------
12333
12334* [`panic::catch_unwind` is more optimized](https://github.com/rust-lang/rust/pull/35444)
12335* [`panic::catch_unwind` no longer accesses thread-local storage on entry](https://github.com/rust-lang/rust/pull/34866)
12336
12337Tooling
12338-------
12339
12340* [Test binaries now support a `--test-threads` argument to specify the number
12341 of threads used to run tests, and which acts the same as the
12342 `RUST_TEST_THREADS` environment variable](https://github.com/rust-lang/rust/pull/35414)
12343* [The test runner now emits a warning when tests run over 60 seconds](https://github.com/rust-lang/rust/pull/35405)
12344* [rustdoc: Fix methods in search results](https://github.com/rust-lang/rust/pull/34752)
12345* [`rust-lldb` warns about unsupported versions of LLDB](https://github.com/rust-lang/rust/pull/34646)
12346* [Rust releases now come with source packages that can be installed by rustup
12347 via `rustup component add rust-src`](https://github.com/rust-lang/rust/pull/34366).
12348 The resulting source code can be used by tools and IDES, located in the
12349 sysroot under `lib/rustlib/src`.
12350
12351Misc
12352----
12353
12354* [The compiler can now be built against LLVM 3.9](https://github.com/rust-lang/rust/pull/35594)
12355* Many minor improvements to the documentation.
12356* [The Rust exception handling "personality" routine is now written in Rust](https://github.com/rust-lang/rust/pull/34832)
12357
12358Compatibility Notes
12359-------------------
12360
12361* [When printing Windows `OsStr`s, unpaired surrogate codepoints are escaped
12362 with the lowercase format instead of the uppercase](https://github.com/rust-lang/rust/pull/35084)
12363* [When formatting strings, if "precision" is specified, the "fill",
12364 "align" and "width" specifiers are no longer ignored](https://github.com/rust-lang/rust/pull/34544)
12365* [The `Debug` impl for strings no longer escapes all non-ASCII characters](https://github.com/rust-lang/rust/pull/34485)
12366
12367
12368Version 1.11.0 (2016-08-18)
12369===========================
12370
12371Language
12372--------
12373
12374* [Support nested `cfg_attr` attributes](https://github.com/rust-lang/rust/pull/34216)
12375* [Allow statement-generating braced macro invocations at the end of blocks](https://github.com/rust-lang/rust/pull/34436)
12376* [Macros can be expanded inside of trait definitions](https://github.com/rust-lang/rust/pull/34213)
12377* [`#[macro_use]` works properly when it is itself expanded from a macro](https://github.com/rust-lang/rust/pull/34032)
12378
12379Stabilized APIs
12380---------------
12381
12382* [`BinaryHeap::append`](https://doc.rust-lang.org/std/collections/binary_heap/struct.BinaryHeap.html#method.append)
12383* [`BTreeMap::append`](https://doc.rust-lang.org/std/collections/btree_map/struct.BTreeMap.html#method.append)
12384* [`BTreeMap::split_off`](https://doc.rust-lang.org/std/collections/btree_map/struct.BTreeMap.html#method.split_off)
12385* [`BTreeSet::append`](https://doc.rust-lang.org/std/collections/btree_set/struct.BTreeSet.html#method.append)
12386* [`BTreeSet::split_off`](https://doc.rust-lang.org/std/collections/btree_set/struct.BTreeSet.html#method.split_off)
12387* [`f32::to_degrees`](https://doc.rust-lang.org/std/primitive.f32.html#method.to_degrees)
12388 (in libcore - previously stabilized in libstd)
12389* [`f32::to_radians`](https://doc.rust-lang.org/std/primitive.f32.html#method.to_radians)
12390 (in libcore - previously stabilized in libstd)
12391* [`f64::to_degrees`](https://doc.rust-lang.org/std/primitive.f64.html#method.to_degrees)
12392 (in libcore - previously stabilized in libstd)
12393* [`f64::to_radians`](https://doc.rust-lang.org/std/primitive.f64.html#method.to_radians)
12394 (in libcore - previously stabilized in libstd)
12395* [`Iterator::sum`](https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.sum)
12396* [`Iterator::product`](https://doc.rust-lang.org/std/iter/trait.Iterator.html#method.product)
12397* [`Cell::get_mut`](https://doc.rust-lang.org/std/cell/struct.Cell.html#method.get_mut)
12398* [`RefCell::get_mut`](https://doc.rust-lang.org/std/cell/struct.RefCell.html#method.get_mut)
12399
12400Libraries
12401---------
12402
12403* [The `thread_local!` macro supports multiple definitions in a single
12404 invocation, and can apply attributes](https://github.com/rust-lang/rust/pull/34077)
12405* [`Cow` implements `Default`](https://github.com/rust-lang/rust/pull/34305)
12406* [`Wrapping` implements binary, octal, lower-hex and upper-hex
12407 `Display` formatting](https://github.com/rust-lang/rust/pull/34190)
12408* [The range types implement `Hash`](https://github.com/rust-lang/rust/pull/34180)
12409* [`lookup_host` ignores unknown address types](https://github.com/rust-lang/rust/pull/34067)
12410* [`assert_eq!` accepts a custom error message, like `assert!` does](https://github.com/rust-lang/rust/pull/33976)
12411* [The main thread is now called "main" instead of "&lt;main&gt;"](https://github.com/rust-lang/rust/pull/33803)
12412
12413Cargo
12414-----
12415
12416* [Disallow specifying features of transitive deps](https://github.com/rust-lang/cargo/pull/2821)
12417* [Add color support for Windows consoles](https://github.com/rust-lang/cargo/pull/2804)
12418* [Fix `harness = false` on `[lib]` sections](https://github.com/rust-lang/cargo/pull/2795)
12419* [Don't panic when `links` contains a '.'](https://github.com/rust-lang/cargo/pull/2787)
12420* [Build scripts can emit warnings](https://github.com/rust-lang/cargo/pull/2630),
12421 and `-vv` prints warnings for all crates.
12422* [Ignore file locks on OS X NFS mounts](https://github.com/rust-lang/cargo/pull/2720)
12423* [Don't warn about `package.metadata` keys](https://github.com/rust-lang/cargo/pull/2668).
12424 This provides room for expansion by arbitrary tools.
12425* [Add support for cdylib crate types](https://github.com/rust-lang/cargo/pull/2741)
12426* [Prevent publishing crates when files are dirty](https://github.com/rust-lang/cargo/pull/2781)
12427* [Don't fetch all crates on clean](https://github.com/rust-lang/cargo/pull/2704)
12428* [Propagate --color option to rustc](https://github.com/rust-lang/cargo/pull/2779)
12429* [Fix `cargo doc --open` on Windows](https://github.com/rust-lang/cargo/pull/2780)
12430* [Improve autocompletion](https://github.com/rust-lang/cargo/pull/2772)
12431* [Configure colors of stderr as well as stdout](https://github.com/rust-lang/cargo/pull/2739)
12432
12433Performance
12434-----------
12435
12436* [Caching projections speeds up type check dramatically for some
12437 workloads](https://github.com/rust-lang/rust/pull/33816)
12438* [The default `HashMap` hasher is SipHash 1-3 instead of SipHash 2-4](https://github.com/rust-lang/rust/pull/33940)
12439 This hasher is faster, but is believed to provide sufficient
12440 protection from collision attacks.
12441* [Comparison of `Ipv4Addr` is 10x faster](https://github.com/rust-lang/rust/pull/33891)
12442
12443Rustdoc
12444-------
12445
12446* [Fix empty implementation section on some module pages](https://github.com/rust-lang/rust/pull/34536)
12447* [Fix inlined renamed re-exports in import lists](https://github.com/rust-lang/rust/pull/34479)
12448* [Fix search result layout for enum variants and struct fields](https://github.com/rust-lang/rust/pull/34477)
12449* [Fix issues with source links to external crates](https://github.com/rust-lang/rust/pull/34387)
12450* [Fix redirect pages for renamed re-exports](https://github.com/rust-lang/rust/pull/34245)
12451
12452Tooling
12453-------
12454
12455* [rustc is better at finding the MSVC toolchain](https://github.com/rust-lang/rust/pull/34492)
12456* [When emitting debug info, rustc emits frame pointers for closures,
12457 shims and glue, as it does for all other functions](https://github.com/rust-lang/rust/pull/33909)
12458* [rust-lldb warns about unsupported versions of LLDB](https://github.com/rust-lang/rust/pull/34646)
12459* Many more errors have been given error codes and extended
12460 explanations
12461* API documentation continues to be improved, with many new examples
12462
12463Misc
12464----
12465
12466* [rustc no longer hangs when dependencies recursively re-export
12467 submodules](https://github.com/rust-lang/rust/pull/34542)
12468* [rustc requires LLVM 3.7+](https://github.com/rust-lang/rust/pull/34104)
12469* [The 'How Safe and Unsafe Interact' chapter of The Rustonomicon was
12470 rewritten](https://github.com/rust-lang/rust/pull/33895)
12471* [rustc support 16-bit pointer sizes](https://github.com/rust-lang/rust/pull/33460).
12472 No targets use this yet, but it works toward AVR support.
12473
12474Compatibility Notes
12475-------------------
12476
12477* [`const`s and `static`s may not have unsized types](https://github.com/rust-lang/rust/pull/34443)
12478* [The new follow-set rules that place restrictions on `macro_rules!`
12479 in order to ensure syntax forward-compatibility have been enabled](https://github.com/rust-lang/rust/pull/33982)
12480 This was an [amendment to RFC 550](https://github.com/rust-lang/rfcs/pull/1384),
12481 and has been a warning since 1.10.
12482* [`cfg` attribute process has been refactored to fix various bugs](https://github.com/rust-lang/rust/pull/33706).
12483 This causes breakage in some corner cases.
12484
12485
12486Version 1.10.0 (2016-07-07)
12487===========================
12488
12489Language
12490--------
12491
12492* [`Copy` types are required to have a trivial implementation of `Clone`](https://github.com/rust-lang/rust/pull/33420).
12493 [RFC 1521](https://github.com/rust-lang/rfcs/blob/master/text/1521-copy-clone-semantics.md).
12494* [Single-variant enums support the `#[repr(..)]` attribute](https://github.com/rust-lang/rust/pull/33355).
12495* [Fix `#[derive(RustcEncodable)]` in the presence of other `encode` methods](https://github.com/rust-lang/rust/pull/32908).
12496* [`panic!` can be converted to a runtime abort with the
12497 `-C panic=abort` flag](https://github.com/rust-lang/rust/pull/32900).
12498 [RFC 1513](https://github.com/rust-lang/rfcs/blob/master/text/1513-less-unwinding.md).
12499* [Add a new crate type, 'cdylib'](https://github.com/rust-lang/rust/pull/33553).
12500 cdylibs are dynamic libraries suitable for loading by non-Rust hosts.
12501 [RFC 1510](https://github.com/rust-lang/rfcs/blob/master/text/1510-cdylib.md).
12502 Note that Cargo does not yet directly support cdylibs.
12503
12504Stabilized APIs
12505---------------
12506
12507* `os::windows::fs::OpenOptionsExt::access_mode`
12508* `os::windows::fs::OpenOptionsExt::share_mode`
12509* `os::windows::fs::OpenOptionsExt::custom_flags`
12510* `os::windows::fs::OpenOptionsExt::attributes`
12511* `os::windows::fs::OpenOptionsExt::security_qos_flags`
12512* `os::unix::fs::OpenOptionsExt::custom_flags`
12513* [`sync::Weak::new`](http://doc.rust-lang.org/alloc/arc/struct.Weak.html#method.new)
12514* `Default for sync::Weak`
12515* [`panic::set_hook`](http://doc.rust-lang.org/std/panic/fn.set_hook.html)
12516* [`panic::take_hook`](http://doc.rust-lang.org/std/panic/fn.take_hook.html)
12517* [`panic::PanicInfo`](http://doc.rust-lang.org/std/panic/struct.PanicInfo.html)
12518* [`panic::PanicInfo::payload`](http://doc.rust-lang.org/std/panic/struct.PanicInfo.html#method.payload)
12519* [`panic::PanicInfo::location`](http://doc.rust-lang.org/std/panic/struct.PanicInfo.html#method.location)
12520* [`panic::Location`](http://doc.rust-lang.org/std/panic/struct.Location.html)
12521* [`panic::Location::file`](http://doc.rust-lang.org/std/panic/struct.Location.html#method.file)
12522* [`panic::Location::line`](http://doc.rust-lang.org/std/panic/struct.Location.html#method.line)
12523* [`ffi::CStr::from_bytes_with_nul`](http://doc.rust-lang.org/std/ffi/struct.CStr.html#method.from_bytes_with_nul)
12524* [`ffi::CStr::from_bytes_with_nul_unchecked`](http://doc.rust-lang.org/std/ffi/struct.CStr.html#method.from_bytes_with_nul_unchecked)
12525* [`ffi::FromBytesWithNulError`](http://doc.rust-lang.org/std/ffi/struct.FromBytesWithNulError.html)
12526* [`fs::Metadata::modified`](http://doc.rust-lang.org/std/fs/struct.Metadata.html#method.modified)
12527* [`fs::Metadata::accessed`](http://doc.rust-lang.org/std/fs/struct.Metadata.html#method.accessed)
12528* [`fs::Metadata::created`](http://doc.rust-lang.org/std/fs/struct.Metadata.html#method.created)
12529* `sync::atomic::Atomic{Usize,Isize,Bool,Ptr}::compare_exchange`
12530* `sync::atomic::Atomic{Usize,Isize,Bool,Ptr}::compare_exchange_weak`
12531* `collections::{btree,hash}_map::{Occupied,Vacant,}Entry::key`
12532* `os::unix::net::{UnixStream, UnixListener, UnixDatagram, SocketAddr}`
12533* [`SocketAddr::is_unnamed`](http://doc.rust-lang.org/std/os/unix/net/struct.SocketAddr.html#method.is_unnamed)
12534* [`SocketAddr::as_pathname`](http://doc.rust-lang.org/std/os/unix/net/struct.SocketAddr.html#method.as_pathname)
12535* [`UnixStream::connect`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.connect)
12536* [`UnixStream::pair`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.pair)
12537* [`UnixStream::try_clone`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.try_clone)
12538* [`UnixStream::local_addr`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.local_addr)
12539* [`UnixStream::peer_addr`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.peer_addr)
12540* [`UnixStream::set_read_timeout`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.read_timeout)
12541* [`UnixStream::set_write_timeout`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.write_timeout)
12542* [`UnixStream::read_timeout`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.read_timeout)
12543* [`UnixStream::write_timeout`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.write_timeout)
12544* [`UnixStream::set_nonblocking`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.set_nonblocking)
12545* [`UnixStream::take_error`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.take_error)
12546* [`UnixStream::shutdown`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixStream.html#method.shutdown)
12547* Read/Write/RawFd impls for `UnixStream`
12548* [`UnixListener::bind`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixListener.html#method.bind)
12549* [`UnixListener::accept`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixListener.html#method.accept)
12550* [`UnixListener::try_clone`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixListener.html#method.try_clone)
12551* [`UnixListener::local_addr`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixListener.html#method.local_addr)
12552* [`UnixListener::set_nonblocking`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixListener.html#method.set_nonblocking)
12553* [`UnixListener::take_error`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixListener.html#method.take_error)
12554* [`UnixListener::incoming`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixListener.html#method.incoming)
12555* RawFd impls for `UnixListener`
12556* [`UnixDatagram::bind`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.bind)
12557* [`UnixDatagram::unbound`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.unbound)
12558* [`UnixDatagram::pair`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.pair)
12559* [`UnixDatagram::connect`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.connect)
12560* [`UnixDatagram::try_clone`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.try_clone)
12561* [`UnixDatagram::local_addr`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.local_addr)
12562* [`UnixDatagram::peer_addr`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.peer_addr)
12563* [`UnixDatagram::recv_from`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.recv_from)
12564* [`UnixDatagram::recv`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.recv)
12565* [`UnixDatagram::send_to`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.send_to)
12566* [`UnixDatagram::send`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.send)
12567* [`UnixDatagram::set_read_timeout`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.set_read_timeout)
12568* [`UnixDatagram::set_write_timeout`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.set_write_timeout)
12569* [`UnixDatagram::read_timeout`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.read_timeout)
12570* [`UnixDatagram::write_timeout`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.write_timeout)
12571* [`UnixDatagram::set_nonblocking`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.set_nonblocking)
12572* [`UnixDatagram::take_error`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.take_error)
12573* [`UnixDatagram::shutdown`](http://doc.rust-lang.org/std/os/unix/net/struct.UnixDatagram.html#method.shutdown)
12574* RawFd impls for `UnixDatagram`
12575* `{BTree,Hash}Map::values_mut`
12576* [`<[_]>::binary_search_by_key`](http://doc.rust-lang.org/std/primitive.slice.html#method.binary_search_by_key)
12577
12578Libraries
12579---------
12580
12581* [The `abs_sub` method of floats is deprecated](https://github.com/rust-lang/rust/pull/33664).
12582 The semantics of this minor method are subtle and probably not what
12583 most people want.
12584* [Add implementation of Ord for Cell<T> and RefCell<T> where T: Ord](https://github.com/rust-lang/rust/pull/33306).
12585* [On Linux, if `HashMap`s can't be initialized with `getrandom` they
12586 will fall back to `/dev/urandom` temporarily to avoid blocking
12587 during early boot](https://github.com/rust-lang/rust/pull/33086).
12588* [Implemented negation for wrapping numerals](https://github.com/rust-lang/rust/pull/33067).
12589* [Implement `Clone` for `binary_heap::IntoIter`](https://github.com/rust-lang/rust/pull/33050).
12590* [Implement `Display` and `Hash` for `std::num::Wrapping`](https://github.com/rust-lang/rust/pull/33023).
12591* [Add `Default` implementation for `&CStr`, `CString`](https://github.com/rust-lang/rust/pull/32990).
12592* [Implement `From<Vec<T>>` and `Into<Vec<T>>` for `VecDeque<T>`](https://github.com/rust-lang/rust/pull/32866).
12593* [Implement `Default` for `UnsafeCell`, `fmt::Error`, `Condvar`,
12594 `Mutex`, `RwLock`](https://github.com/rust-lang/rust/pull/32785).
12595
12596Cargo
12597-----
12598* [Cargo.toml supports the `profile.*.panic` option](https://github.com/rust-lang/cargo/pull/2687).
12599 This controls the runtime behavior of the `panic!` macro
12600 and can be either "unwind" (the default), or "abort".
12601 [RFC 1513](https://github.com/rust-lang/rfcs/blob/master/text/1513-less-unwinding.md).
12602* [Don't throw away errors with `-p` arguments](https://github.com/rust-lang/cargo/pull/2723).
12603* [Report status to stderr instead of stdout](https://github.com/rust-lang/cargo/pull/2693).
12604* [Build scripts are passed a `CARGO_MANIFEST_LINKS` environment
12605 variable that corresponds to the `links` field of the manifest](https://github.com/rust-lang/cargo/pull/2710).
12606* [Ban keywords from crate names](https://github.com/rust-lang/cargo/pull/2707).
12607* [Canonicalize `CARGO_HOME` on Windows](https://github.com/rust-lang/cargo/pull/2604).
12608* [Retry network requests](https://github.com/rust-lang/cargo/pull/2396).
12609 By default they are retried twice, which can be customized with the
12610 `net.retry` value in `.cargo/config`.
12611* [Don't print extra error info for failing subcommands](https://github.com/rust-lang/cargo/pull/2674).
12612* [Add `--force` flag to `cargo install`](https://github.com/rust-lang/cargo/pull/2405).
12613* [Don't use `flock` on NFS mounts](https://github.com/rust-lang/cargo/pull/2623).
12614* [Prefer building `cargo install` artifacts in temporary directories](https://github.com/rust-lang/cargo/pull/2610).
12615 Makes it possible to install multiple crates in parallel.
12616* [Add `cargo test --doc`](https://github.com/rust-lang/cargo/pull/2578).
12617* [Add `cargo --explain`](https://github.com/rust-lang/cargo/pull/2551).
12618* [Don't print warnings when `-q` is passed](https://github.com/rust-lang/cargo/pull/2576).
12619* [Add `cargo doc --lib` and `--bin`](https://github.com/rust-lang/cargo/pull/2577).
12620* [Don't require build script output to be UTF-8](https://github.com/rust-lang/cargo/pull/2560).
12621* [Correctly attempt multiple git usernames](https://github.com/rust-lang/cargo/pull/2584).
12622
12623Performance
12624-----------
12625
12626* [rustc memory usage was reduced by refactoring the context used for
12627 type checking](https://github.com/rust-lang/rust/pull/33425).
12628* [Speed up creation of `HashMap`s by caching the random keys used
12629 to initialize the hash state](https://github.com/rust-lang/rust/pull/33318).
12630* [The `find` implementation for `Chain` iterators is 2x faster](https://github.com/rust-lang/rust/pull/33289).
12631* [Trait selection optimizations speed up type checking by 15%](https://github.com/rust-lang/rust/pull/33138).
12632* [Efficient trie lookup for boolean Unicode properties](https://github.com/rust-lang/rust/pull/33098).
12633 10x faster than the previous lookup tables.
12634* [Special case `#[derive(Copy, Clone)]` to avoid bloat](https://github.com/rust-lang/rust/pull/31414).
12635
12636Usability
12637---------
12638
12639* Many incremental improvements to documentation and rustdoc.
12640* [rustdoc: List blanket trait impls](https://github.com/rust-lang/rust/pull/33514).
12641* [rustdoc: Clean up ABI rendering](https://github.com/rust-lang/rust/pull/33151).
12642* [Indexing with the wrong type produces a more informative error](https://github.com/rust-lang/rust/pull/33401).
12643* [Improve diagnostics for constants being used in irrefutable patterns](https://github.com/rust-lang/rust/pull/33406).
12644* [When many method candidates are in scope limit the suggestions to 10](https://github.com/rust-lang/rust/pull/33338).
12645* [Remove confusing suggestion when calling a `fn` type](https://github.com/rust-lang/rust/pull/33325).
12646* [Do not suggest changing `&mut self` to `&mut mut self`](https://github.com/rust-lang/rust/pull/33319).
12647
12648Misc
12649----
12650
12651* [Update i686-linux-android features to match Android ABI](https://github.com/rust-lang/rust/pull/33651).
12652* [Update aarch64-linux-android features to match Android ABI](https://github.com/rust-lang/rust/pull/33500).
12653* [`std` no longer prints backtraces on platforms where the running
12654 module must be loaded with `env::current_exe`, which can't be relied
12655 on](https://github.com/rust-lang/rust/pull/33554).
12656* This release includes std binaries for the i586-unknown-linux-gnu,
12657 i686-unknown-linux-musl, and armv7-linux-androideabi targets. The
12658 i586 target is for old x86 hardware without SSE2, and the armv7
12659 target is for Android running on modern ARM architectures.
12660* [The `rust-gdb` and `rust-lldb` scripts are distributed on all
12661 Unix platforms](https://github.com/rust-lang/rust/pull/32835).
12662* [On Unix the runtime aborts by calling `libc::abort` instead of
12663 generating an illegal instruction](https://github.com/rust-lang/rust/pull/31457).
12664* [Rust is now bootstrapped from the previous release of Rust,
12665 instead of a snapshot from an arbitrary commit](https://github.com/rust-lang/rust/pull/32942).
12666
12667Compatibility Notes
12668-------------------
12669
12670* [`AtomicBool` is now bool-sized, not word-sized](https://github.com/rust-lang/rust/pull/33579).
12671* [`target_env` for Linux ARM targets is just `gnu`, not
12672 `gnueabihf`, `gnueabi`, etc](https://github.com/rust-lang/rust/pull/33403).
12673* [Consistently panic on overflow in `Duration::new`](https://github.com/rust-lang/rust/pull/33072).
12674* [Change `String::truncate` to panic less](https://github.com/rust-lang/rust/pull/32977).
12675* [Add `:block` to the follow set for `:ty` and `:path`](https://github.com/rust-lang/rust/pull/32945).
12676 Affects how macros are parsed.
12677* [Fix macro hygiene bug](https://github.com/rust-lang/rust/pull/32923).
12678* [Feature-gated attributes on macro-generated macro invocations are
12679 now rejected](https://github.com/rust-lang/rust/pull/32791).
12680* [Suppress fallback and ambiguity errors during type inference](https://github.com/rust-lang/rust/pull/32258).
12681 This caused some minor changes to type inference.
12682
12683
12684Version 1.9.0 (2016-05-26)
12685==========================
12686
12687Language
12688--------
12689
12690* The `#[deprecated]` attribute when applied to an API will generate
12691 warnings when used. The warnings may be suppressed with
12692 `#[allow(deprecated)]`. [RFC 1270].
12693* [`fn` item types are zero sized, and each `fn` names a unique
12694 type][1.9fn]. This will break code that transmutes `fn`s, so calling
12695 `transmute` on a `fn` type will generate a warning for a few cycles,
12696 then will be converted to an error.
12697* [Field and method resolution understand visibility, so private
12698 fields and methods cannot prevent the proper use of public fields
12699 and methods][1.9fv].
12700* [The parser considers unicode codepoints in the
12701 `PATTERN_WHITE_SPACE` category to be whitespace][1.9ws].
12702
12703Stabilized APIs
12704---------------
12705
12706* [`std::panic`]
12707* [`std::panic::catch_unwind`] (renamed from `recover`)
12708* [`std::panic::resume_unwind`] (renamed from `propagate`)
12709* [`std::panic::AssertUnwindSafe`] (renamed from `AssertRecoverSafe`)
12710* [`std::panic::UnwindSafe`] (renamed from `RecoverSafe`)
12711* [`str::is_char_boundary`]
12712* [`<*const T>::as_ref`]
12713* [`<*mut T>::as_ref`]
12714* [`<*mut T>::as_mut`]
12715* [`AsciiExt::make_ascii_uppercase`]
12716* [`AsciiExt::make_ascii_lowercase`]
12717* [`char::decode_utf16`]
12718* [`char::DecodeUtf16`]
12719* [`char::DecodeUtf16Error`]
12720* [`char::DecodeUtf16Error::unpaired_surrogate`]
12721* [`BTreeSet::take`]
12722* [`BTreeSet::replace`]
12723* [`BTreeSet::get`]
12724* [`HashSet::take`]
12725* [`HashSet::replace`]
12726* [`HashSet::get`]
12727* [`OsString::with_capacity`]
12728* [`OsString::clear`]
12729* [`OsString::capacity`]
12730* [`OsString::reserve`]
12731* [`OsString::reserve_exact`]
12732* [`OsStr::is_empty`]
12733* [`OsStr::len`]
12734* [`std::os::unix::thread`]
12735* [`RawPthread`]
12736* [`JoinHandleExt`]
12737* [`JoinHandleExt::as_pthread_t`]
12738* [`JoinHandleExt::into_pthread_t`]
12739* [`HashSet::hasher`]
12740* [`HashMap::hasher`]
12741* [`CommandExt::exec`]
12742* [`File::try_clone`]
12743* [`SocketAddr::set_ip`]
12744* [`SocketAddr::set_port`]
12745* [`SocketAddrV4::set_ip`]
12746* [`SocketAddrV4::set_port`]
12747* [`SocketAddrV6::set_ip`]
12748* [`SocketAddrV6::set_port`]
12749* [`SocketAddrV6::set_flowinfo`]
12750* [`SocketAddrV6::set_scope_id`]
12751* [`slice::copy_from_slice`]
12752* [`ptr::read_volatile`]
12753* [`ptr::write_volatile`]
12754* [`OpenOptions::create_new`]
12755* [`TcpStream::set_nodelay`]
12756* [`TcpStream::nodelay`]
12757* [`TcpStream::set_ttl`]
12758* [`TcpStream::ttl`]
12759* [`TcpStream::set_only_v6`]
12760* [`TcpStream::only_v6`]
12761* [`TcpStream::take_error`]
12762* [`TcpStream::set_nonblocking`]
12763* [`TcpListener::set_ttl`]
12764* [`TcpListener::ttl`]
12765* [`TcpListener::set_only_v6`]
12766* [`TcpListener::only_v6`]
12767* [`TcpListener::take_error`]
12768* [`TcpListener::set_nonblocking`]
12769* [`UdpSocket::set_broadcast`]
12770* [`UdpSocket::broadcast`]
12771* [`UdpSocket::set_multicast_loop_v4`]
12772* [`UdpSocket::multicast_loop_v4`]
12773* [`UdpSocket::set_multicast_ttl_v4`]
12774* [`UdpSocket::multicast_ttl_v4`]
12775* [`UdpSocket::set_multicast_loop_v6`]
12776* [`UdpSocket::multicast_loop_v6`]
12777* [`UdpSocket::set_multicast_ttl_v6`]
12778* [`UdpSocket::multicast_ttl_v6`]
12779* [`UdpSocket::set_ttl`]
12780* [`UdpSocket::ttl`]
12781* [`UdpSocket::set_only_v6`]
12782* [`UdpSocket::only_v6`]
12783* [`UdpSocket::join_multicast_v4`]
12784* [`UdpSocket::join_multicast_v6`]
12785* [`UdpSocket::leave_multicast_v4`]
12786* [`UdpSocket::leave_multicast_v6`]
12787* [`UdpSocket::take_error`]
12788* [`UdpSocket::connect`]
12789* [`UdpSocket::send`]
12790* [`UdpSocket::recv`]
12791* [`UdpSocket::set_nonblocking`]
12792
12793Libraries
12794---------
12795
12796* [`std::sync::Once` is poisoned if its initialization function
12797 fails][1.9o].
12798* [`cell::Ref` and `cell::RefMut` can contain unsized types][1.9cu].
12799* [Most types implement `fmt::Debug`][1.9db].
12800* [The default buffer size used by `BufReader` and `BufWriter` was
12801 reduced to 8K, from 64K][1.9bf]. This is in line with the buffer size
12802 used by other languages.
12803* [`Instant`, `SystemTime` and `Duration` implement `+=` and `-=`.
12804 `Duration` additionally implements `*=` and `/=`][1.9ta].
12805* [`Skip` is a `DoubleEndedIterator`][1.9sk].
12806* [`From<[u8; 4]>` is implemented for `Ipv4Addr`][1.9fi].
12807* [`Chain` implements `BufRead`][1.9ch].
12808* [`HashMap`, `HashSet` and iterators are covariant][1.9hc].
12809
12810Cargo
12811-----
12812
12813* [Cargo can now run concurrently][1.9cc].
12814* [Top-level overrides allow specific revisions of crates to be
12815 overridden through the entire crate graph][1.9ct]. This is intended
12816 to make upgrades easier for large projects, by allowing crates to be
12817 forked temporarily until they've been upgraded and republished.
12818* [Cargo exports a `CARGO_PKG_AUTHORS` environment variable][1.9cp].
12819* [Cargo will pass the contents of the `RUSTFLAGS` variable to `rustc`
12820 on the commandline][1.9cf]. `rustc` arguments can also be specified
12821 in the `build.rustflags` configuration key.
12822
12823Performance
12824-----------
12825
12826* [The time complexity of comparing variables for equivalence during type
12827 unification is reduced from _O_(_n_!) to _O_(_n_)][1.9tu]. This leads
12828 to major compilation time improvement in some scenarios.
12829* [`ToString` is specialized for `str`, giving it the same performance
12830 as `to_owned`][1.9ts].
12831* [Spawning processes with `Command::output` no longer creates extra
12832 threads][1.9sp].
12833* [`#[derive(PartialEq)]` and `#[derive(PartialOrd)]` emit less code
12834 for C-like enums][1.9cl].
12835
12836Misc
12837----
12838
12839* [Passing the `--quiet` flag to a test runner will produce
12840 much-abbreviated output][1.9q].
12841* The Rust Project now publishes std binaries for the
12842 `mips-unknown-linux-musl`, `mipsel-unknown-linux-musl`, and
12843 `i586-pc-windows-msvc` targets.
12844
12845Compatibility Notes
12846-------------------
12847
12848* [`std::sync::Once` is poisoned if its initialization function
12849 fails][1.9o].
12850* [It is illegal to define methods with the same name in overlapping
12851 inherent `impl` blocks][1.9sn].
12852* [`fn` item types are zero sized, and each `fn` names a unique
12853 type][1.9fn]. This will break code that transmutes `fn`s, so calling
12854 `transmute` on a `fn` type will generate a warning for a few cycles,
12855 then will be converted to an error.
12856* [Improvements to const evaluation may trigger new errors when integer
12857 literals are out of range][1.9ce].
12858
12859
12860[1.9bf]: https://github.com/rust-lang/rust/pull/32695
12861[1.9cc]: https://github.com/rust-lang/cargo/pull/2486
12862[1.9ce]: https://github.com/rust-lang/rust/pull/30587
12863[1.9cf]: https://github.com/rust-lang/cargo/pull/2241
12864[1.9ch]: https://github.com/rust-lang/rust/pull/32541
12865[1.9cl]: https://github.com/rust-lang/rust/pull/31977
12866[1.9cp]: https://github.com/rust-lang/cargo/pull/2465
12867[1.9ct]: https://github.com/rust-lang/cargo/pull/2385
12868[1.9cu]: https://github.com/rust-lang/rust/pull/32652
12869[1.9db]: https://github.com/rust-lang/rust/pull/32054
12870[1.9fi]: https://github.com/rust-lang/rust/pull/32050
12871[1.9fn]: https://github.com/rust-lang/rust/pull/31710
12872[1.9fv]: https://github.com/rust-lang/rust/pull/31938
12873[1.9hc]: https://github.com/rust-lang/rust/pull/32635
12874[1.9o]: https://github.com/rust-lang/rust/pull/32325
12875[1.9q]: https://github.com/rust-lang/rust/pull/31887
12876[1.9sk]: https://github.com/rust-lang/rust/pull/31700
12877[1.9sn]: https://github.com/rust-lang/rust/pull/31925
12878[1.9sp]: https://github.com/rust-lang/rust/pull/31618
12879[1.9ta]: https://github.com/rust-lang/rust/pull/32448
12880[1.9ts]: https://github.com/rust-lang/rust/pull/32586
12881[1.9tu]: https://github.com/rust-lang/rust/pull/32062
12882[1.9ws]: https://github.com/rust-lang/rust/pull/29734
12883[RFC 1270]: https://github.com/rust-lang/rfcs/blob/master/text/1270-deprecation.md
12884[`<*const T>::as_ref`]: http://doc.rust-lang.org/nightly/std/primitive.pointer.html#method.as_ref
12885[`<*mut T>::as_mut`]: http://doc.rust-lang.org/nightly/std/primitive.pointer.html#method.as_mut
12886[`<*mut T>::as_ref`]: http://doc.rust-lang.org/nightly/std/primitive.pointer.html#method.as_ref
12887[`slice::copy_from_slice`]: http://doc.rust-lang.org/nightly/std/primitive.slice.html#method.copy_from_slice
12888[`AsciiExt::make_ascii_lowercase`]: http://doc.rust-lang.org/nightly/std/ascii/trait.AsciiExt.html#tymethod.make_ascii_lowercase
12889[`AsciiExt::make_ascii_uppercase`]: http://doc.rust-lang.org/nightly/std/ascii/trait.AsciiExt.html#tymethod.make_ascii_uppercase
12890[`BTreeSet::get`]: http://doc.rust-lang.org/nightly/collections/btree/set/struct.BTreeSet.html#method.get
12891[`BTreeSet::replace`]: http://doc.rust-lang.org/nightly/collections/btree/set/struct.BTreeSet.html#method.replace
12892[`BTreeSet::take`]: http://doc.rust-lang.org/nightly/collections/btree/set/struct.BTreeSet.html#method.take
12893[`CommandExt::exec`]: http://doc.rust-lang.org/nightly/std/os/unix/process/trait.CommandExt.html#tymethod.exec
12894[`File::try_clone`]: http://doc.rust-lang.org/nightly/std/fs/struct.File.html#method.try_clone
12895[`HashMap::hasher`]: http://doc.rust-lang.org/nightly/std/collections/struct.HashMap.html#method.hasher
12896[`HashSet::get`]: http://doc.rust-lang.org/nightly/std/collections/struct.HashSet.html#method.get
12897[`HashSet::hasher`]: http://doc.rust-lang.org/nightly/std/collections/struct.HashSet.html#method.hasher
12898[`HashSet::replace`]: http://doc.rust-lang.org/nightly/std/collections/struct.HashSet.html#method.replace
12899[`HashSet::take`]: http://doc.rust-lang.org/nightly/std/collections/struct.HashSet.html#method.take
12900[`JoinHandleExt::as_pthread_t`]: http://doc.rust-lang.org/nightly/std/os/unix/thread/trait.JoinHandleExt.html#tymethod.as_pthread_t
12901[`JoinHandleExt::into_pthread_t`]: http://doc.rust-lang.org/nightly/std/os/unix/thread/trait.JoinHandleExt.html#tymethod.into_pthread_t
12902[`JoinHandleExt`]: http://doc.rust-lang.org/nightly/std/os/unix/thread/trait.JoinHandleExt.html
12903[`OpenOptions::create_new`]: http://doc.rust-lang.org/nightly/std/fs/struct.OpenOptions.html#method.create_new
12904[`OsStr::is_empty`]: http://doc.rust-lang.org/nightly/std/ffi/struct.OsStr.html#method.is_empty
12905[`OsStr::len`]: http://doc.rust-lang.org/nightly/std/ffi/struct.OsStr.html#method.len
12906[`OsString::capacity`]: http://doc.rust-lang.org/nightly/std/ffi/struct.OsString.html#method.capacity
12907[`OsString::clear`]: http://doc.rust-lang.org/nightly/std/ffi/struct.OsString.html#method.clear
12908[`OsString::reserve_exact`]: http://doc.rust-lang.org/nightly/std/ffi/struct.OsString.html#method.reserve_exact
12909[`OsString::reserve`]: http://doc.rust-lang.org/nightly/std/ffi/struct.OsString.html#method.reserve
12910[`OsString::with_capacity`]: http://doc.rust-lang.org/nightly/std/ffi/struct.OsString.html#method.with_capacity
12911[`RawPthread`]: http://doc.rust-lang.org/nightly/std/os/unix/thread/type.RawPthread.html
12912[`SocketAddr::set_ip`]: http://doc.rust-lang.org/nightly/std/net/enum.SocketAddr.html#method.set_ip
12913[`SocketAddr::set_port`]: http://doc.rust-lang.org/nightly/std/net/enum.SocketAddr.html#method.set_port
12914[`SocketAddrV4::set_ip`]: http://doc.rust-lang.org/nightly/std/net/struct.SocketAddrV4.html#method.set_ip
12915[`SocketAddrV4::set_port`]: http://doc.rust-lang.org/nightly/std/net/struct.SocketAddrV4.html#method.set_port
12916[`SocketAddrV6::set_flowinfo`]: http://doc.rust-lang.org/nightly/std/net/struct.SocketAddrV6.html#method.set_flowinfo
12917[`SocketAddrV6::set_ip`]: http://doc.rust-lang.org/nightly/std/net/struct.SocketAddrV6.html#method.set_ip
12918[`SocketAddrV6::set_port`]: http://doc.rust-lang.org/nightly/std/net/struct.SocketAddrV6.html#method.set_port
12919[`SocketAddrV6::set_scope_id`]: http://doc.rust-lang.org/nightly/std/net/struct.SocketAddrV6.html#method.set_scope_id
12920[`TcpListener::only_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.only_v6
12921[`TcpListener::set_nonblocking`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_nonblocking
12922[`TcpListener::set_only_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_only_v6
12923[`TcpListener::set_ttl`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_ttl
12924[`TcpListener::take_error`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.take_error
12925[`TcpListener::ttl`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.ttl
12926[`TcpStream::nodelay`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.nodelay
12927[`TcpStream::only_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.only_v6
12928[`TcpStream::set_nodelay`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_nodelay
12929[`TcpStream::set_nonblocking`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_nonblocking
12930[`TcpStream::set_only_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_only_v6
12931[`TcpStream::set_ttl`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_ttl
12932[`TcpStream::take_error`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.take_error
12933[`TcpStream::ttl`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.ttl
12934[`UdpSocket::broadcast`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.broadcast
12935[`UdpSocket::connect`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.connect
12936[`UdpSocket::join_multicast_v4`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.join_multicast_v4
12937[`UdpSocket::join_multicast_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.join_multicast_v6
12938[`UdpSocket::leave_multicast_v4`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.leave_multicast_v4
12939[`UdpSocket::leave_multicast_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.leave_multicast_v6
12940[`UdpSocket::multicast_loop_v4`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.multicast_loop_v4
12941[`UdpSocket::multicast_loop_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.multicast_loop_v6
12942[`UdpSocket::multicast_ttl_v4`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.multicast_ttl_v4
12943[`UdpSocket::multicast_ttl_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.multicast_ttl_v6
12944[`UdpSocket::only_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.only_v6
12945[`UdpSocket::recv`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.recv
12946[`UdpSocket::send`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.send
12947[`UdpSocket::set_broadcast`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.set_broadcast
12948[`UdpSocket::set_multicast_loop_v4`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.set_multicast_loop_v4
12949[`UdpSocket::set_multicast_loop_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.set_multicast_loop_v6
12950[`UdpSocket::set_multicast_ttl_v4`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.set_multicast_ttl_v4
12951[`UdpSocket::set_multicast_ttl_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.set_multicast_ttl_v6
12952[`UdpSocket::set_nonblocking`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.set_nonblocking
12953[`UdpSocket::set_only_v6`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.set_only_v6
12954[`UdpSocket::set_ttl`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.set_ttl
12955[`UdpSocket::take_error`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.take_error
12956[`UdpSocket::ttl`]: http://doc.rust-lang.org/nightly/std/net/struct.UdpSocket.html#method.ttl
12957[`char::DecodeUtf16Error::unpaired_surrogate`]: http://doc.rust-lang.org/nightly/std/char/struct.DecodeUtf16Error.html#method.unpaired_surrogate
12958[`char::DecodeUtf16Error`]: http://doc.rust-lang.org/nightly/std/char/struct.DecodeUtf16Error.html
12959[`char::DecodeUtf16`]: http://doc.rust-lang.org/nightly/std/char/struct.DecodeUtf16.html
12960[`char::decode_utf16`]: http://doc.rust-lang.org/nightly/std/char/fn.decode_utf16.html
12961[`ptr::read_volatile`]: http://doc.rust-lang.org/nightly/std/ptr/fn.read_volatile.html
12962[`ptr::write_volatile`]: http://doc.rust-lang.org/nightly/std/ptr/fn.write_volatile.html
12963[`std::os::unix::thread`]: http://doc.rust-lang.org/nightly/std/os/unix/thread/index.html
12964[`std::panic::AssertUnwindSafe`]: http://doc.rust-lang.org/nightly/std/panic/struct.AssertUnwindSafe.html
12965[`std::panic::UnwindSafe`]: http://doc.rust-lang.org/nightly/std/panic/trait.UnwindSafe.html
12966[`std::panic::catch_unwind`]: http://doc.rust-lang.org/nightly/std/panic/fn.catch_unwind.html
12967[`std::panic::resume_unwind`]: http://doc.rust-lang.org/nightly/std/panic/fn.resume_unwind.html
12968[`std::panic`]: http://doc.rust-lang.org/nightly/std/panic/index.html
12969[`str::is_char_boundary`]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.is_char_boundary
12970
12971
12972Version 1.8.0 (2016-04-14)
12973==========================
12974
12975Language
12976--------
12977
12978* Rust supports overloading of compound assignment statements like
12979 `+=` by implementing the [`AddAssign`], [`SubAssign`],
12980 [`MulAssign`], [`DivAssign`], [`RemAssign`], [`BitAndAssign`],
12981 [`BitOrAssign`], [`BitXorAssign`], [`ShlAssign`], or [`ShrAssign`]
12982 traits. [RFC 953].
12983* Empty structs can be defined with braces, as in `struct Foo { }`, in
12984 addition to the non-braced form, `struct Foo;`. [RFC 218].
12985
12986Libraries
12987---------
12988
12989* Stabilized APIs:
12990 * [`str::encode_utf16`] (renamed from `utf16_units`)
12991 * [`str::EncodeUtf16`] (renamed from `Utf16Units`)
12992 * [`Ref::map`]
12993 * [`RefMut::map`]
12994 * [`ptr::drop_in_place`]
12995 * [`time::Instant`]
12996 * [`time::SystemTime`]
12997 * [`Instant::now`]
12998 * [`Instant::duration_since`] (renamed from `duration_from_earlier`)
12999 * [`Instant::elapsed`]
13000 * [`SystemTime::now`]
13001 * [`SystemTime::duration_since`] (renamed from `duration_from_earlier`)
13002 * [`SystemTime::elapsed`]
13003 * Various `Add`/`Sub` impls for `Time` and `SystemTime`
13004 * [`SystemTimeError`]
13005 * [`SystemTimeError::duration`]
13006 * Various impls for `SystemTimeError`
13007 * [`UNIX_EPOCH`]
13008 * [`AddAssign`], [`SubAssign`], [`MulAssign`], [`DivAssign`],
13009 [`RemAssign`], [`BitAndAssign`], [`BitOrAssign`],
13010 [`BitXorAssign`], [`ShlAssign`], [`ShrAssign`].
13011* [The `write!` and `writeln!` macros correctly emit errors if any of
13012 their arguments can't be formatted][1.8w].
13013* [Various I/O functions support large files on 32-bit Linux][1.8l].
13014* [The Unix-specific `raw` modules, which contain a number of
13015 redefined C types are deprecated][1.8r], including `os::raw::unix`,
13016 `os::raw::macos`, and `os::raw::linux`. These modules defined types
13017 such as `ino_t` and `dev_t`. The inconsistency of these definitions
13018 across platforms was making it difficult to implement `std`
13019 correctly. Those that need these definitions should use the `libc`
13020 crate. [RFC 1415].
13021* The Unix-specific `MetadataExt` traits, including
13022 `os::unix::fs::MetadataExt`, which expose values such as inode
13023 numbers [no longer return platform-specific types][1.8r], but
13024 instead return widened integers. [RFC 1415].
13025* [`btree_set::{IntoIter, Iter, Range}` are covariant][1.8cv].
13026* [Atomic loads and stores are not volatile][1.8a].
13027* [All types in `sync::mpsc` implement `fmt::Debug`][1.8mp].
13028
13029Performance
13030-----------
13031
13032* [Inlining hash functions lead to a 3% compile-time improvement in
13033 some workloads][1.8h].
13034* When using jemalloc, its symbols are [unprefixed so that it
13035 overrides the libc malloc implementation][1.8h]. This means that for
13036 rustc, LLVM is now using jemalloc, which results in a 6%
13037 compile-time improvement on a specific workload.
13038* [Avoid quadratic growth in function size due to cleanups][1.8cu].
13039
13040Misc
13041----
13042
13043* [32-bit MSVC builds finally implement unwinding][1.8ms].
13044 i686-pc-windows-msvc is now considered a tier-1 platform.
13045* [The `--print targets` flag prints a list of supported targets][1.8t].
13046* [The `--print cfg` flag prints the `cfg`s defined for the current
13047 target][1.8cf].
13048* [`rustc` can be built with an new Cargo-based build system, written
13049 in Rust][1.8b]. It will eventually replace Rust's Makefile-based
13050 build system. To enable it configure with `configure --rustbuild`.
13051* [Errors for non-exhaustive `match` patterns now list up to 3 missing
13052 variants while also indicating the total number of missing variants
13053 if more than 3][1.8m].
13054* [Executable stacks are disabled on Linux and BSD][1.8nx].
13055* The Rust Project now publishes binary releases of the standard
13056 library for a number of tier-2 targets:
13057 `armv7-unknown-linux-gnueabihf`, `powerpc-unknown-linux-gnu`,
13058 `powerpc64-unknown-linux-gnu`, `powerpc64le-unknown-linux-gnu`
13059 `x86_64-rumprun-netbsd`. These can be installed with
13060 tools such as [multirust][1.8mr].
13061
13062Cargo
13063-----
13064
13065* [`cargo init` creates a new Cargo project in the current
13066 directory][1.8ci]. It is otherwise like `cargo new`.
13067* [Cargo has configuration keys for `-v` and
13068 `--color`][1.8cc]. `verbose` and `color`, respectively, go in the
13069 `[term]` section of `.cargo/config`.
13070* [Configuration keys that evaluate to strings or integers can be set
13071 via environment variables][1.8ce]. For example the `build.jobs` key
13072 can be set via `CARGO_BUILD_JOBS`. Environment variables take
13073 precedence over config files.
13074* [Target-specific dependencies support Rust `cfg` syntax for
13075 describing targets][1.8cfg] so that dependencies for multiple
13076 targets can be specified together. [RFC 1361].
13077* [The environment variables `CARGO_TARGET_ROOT`, `RUSTC`, and
13078 `RUSTDOC` take precedence over the `build.target-dir`,
13079 `build.rustc`, and `build.rustdoc` configuration values][1.8cfv].
13080* [The child process tree is killed on Windows when Cargo is
13081 killed][1.8ck].
13082* [The `build.target` configuration value sets the target platform,
13083 like `--target`][1.8ct].
13084
13085Compatibility Notes
13086-------------------
13087
13088* [Unstable compiler flags have been further restricted][1.8u]. Since
13089 1.0 `-Z` flags have been considered unstable, and other flags that
13090 were considered unstable additionally required passing `-Z
13091 unstable-options` to access. Unlike unstable language and library
13092 features though, these options have been accessible on the stable
13093 release channel. Going forward, *new unstable flags will not be
13094 available on the stable release channel*, and old unstable flags
13095 will warn about their usage. In the future, all unstable flags will
13096 be unavailable on the stable release channel.
13097* [It is no longer possible to `match` on empty enum variants using
13098 the `Variant(..)` syntax][1.8v]. This has been a warning since 1.6.
13099* The Unix-specific `MetadataExt` traits, including
13100 `os::unix::fs::MetadataExt`, which expose values such as inode
13101 numbers [no longer return platform-specific types][1.8r], but
13102 instead return widened integers. [RFC 1415].
13103* [Modules sourced from the filesystem cannot appear within arbitrary
13104 blocks, but only within other modules][1.8mf].
13105* [`--cfg` compiler flags are parsed strictly as identifiers][1.8c].
13106* On Unix, [stack overflow triggers a runtime abort instead of a
13107 SIGSEGV][1.8so].
13108* [`Command::spawn` and its equivalents return an error if any of
13109 its command-line arguments contain interior `NUL`s][1.8n].
13110* [Tuple and unit enum variants from other crates are in the type
13111 namespace][1.8tn].
13112* [On Windows `rustc` emits `.lib` files for the `staticlib` library
13113 type instead of `.a` files][1.8st]. Additionally, for the MSVC
13114 toolchain, `rustc` emits import libraries named `foo.dll.lib`
13115 instead of `foo.lib`.
13116
13117
13118[1.8a]: https://github.com/rust-lang/rust/pull/30962
13119[1.8b]: https://github.com/rust-lang/rust/pull/31123
13120[1.8c]: https://github.com/rust-lang/rust/pull/31530
13121[1.8cc]: https://github.com/rust-lang/cargo/pull/2397
13122[1.8ce]: https://github.com/rust-lang/cargo/pull/2398
13123[1.8cf]: https://github.com/rust-lang/rust/pull/31278
13124[1.8cfg]: https://github.com/rust-lang/cargo/pull/2328
13125[1.8ci]: https://github.com/rust-lang/cargo/pull/2081
13126[1.8ck]: https://github.com/rust-lang/cargo/pull/2370
13127[1.8ct]: https://github.com/rust-lang/cargo/pull/2335
13128[1.8cu]: https://github.com/rust-lang/rust/pull/31390
13129[1.8cfv]: https://github.com/rust-lang/cargo/issues/2365
13130[1.8cv]: https://github.com/rust-lang/rust/pull/30998
13131[1.8h]: https://github.com/rust-lang/rust/pull/31460
13132[1.8l]: https://github.com/rust-lang/rust/pull/31668
13133[1.8m]: https://github.com/rust-lang/rust/pull/31020
13134[1.8mf]: https://github.com/rust-lang/rust/pull/31534
13135[1.8mp]: https://github.com/rust-lang/rust/pull/30894
13136[1.8mr]: https://users.rust-lang.org/t/multirust-0-8-with-cross-std-installation/4901
13137[1.8ms]: https://github.com/rust-lang/rust/pull/30448
13138[1.8n]: https://github.com/rust-lang/rust/pull/31056
13139[1.8nx]: https://github.com/rust-lang/rust/pull/30859
13140[1.8r]: https://github.com/rust-lang/rust/pull/31551
13141[1.8so]: https://github.com/rust-lang/rust/pull/31333
13142[1.8st]: https://github.com/rust-lang/rust/pull/29520
13143[1.8t]: https://github.com/rust-lang/rust/pull/31358
13144[1.8tn]: https://github.com/rust-lang/rust/pull/30882
13145[1.8u]: https://github.com/rust-lang/rust/pull/31793
13146[1.8v]: https://github.com/rust-lang/rust/pull/31757
13147[1.8w]: https://github.com/rust-lang/rust/pull/31904
13148[RFC 1361]: https://github.com/rust-lang/rfcs/blob/master/text/1361-cargo-cfg-dependencies.md
13149[RFC 1415]: https://github.com/rust-lang/rfcs/blob/master/text/1415-trim-std-os.md
13150[RFC 218]: https://github.com/rust-lang/rfcs/blob/master/text/0218-empty-struct-with-braces.md
13151[RFC 953]: https://github.com/rust-lang/rfcs/blob/master/text/0953-op-assign.md
13152[`AddAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.AddAssign.html
13153[`BitAndAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.BitAndAssign.html
13154[`BitOrAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.BitOrAssign.html
13155[`BitXorAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.BitXorAssign.html
13156[`DivAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.DivAssign.html
13157[`Instant::duration_since`]: http://doc.rust-lang.org/nightly/std/time/struct.Instant.html#method.duration_since
13158[`Instant::elapsed`]: http://doc.rust-lang.org/nightly/std/time/struct.Instant.html#method.elapsed
13159[`Instant::now`]: http://doc.rust-lang.org/nightly/std/time/struct.Instant.html#method.now
13160[`MulAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.MulAssign.html
13161[`Ref::map`]: http://doc.rust-lang.org/nightly/std/cell/struct.Ref.html#method.map
13162[`RefMut::map`]: http://doc.rust-lang.org/nightly/std/cell/struct.RefMut.html#method.map
13163[`RemAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.RemAssign.html
13164[`ShlAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.ShlAssign.html
13165[`ShrAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.ShrAssign.html
13166[`SubAssign`]: http://doc.rust-lang.org/nightly/std/ops/trait.SubAssign.html
13167[`SystemTime::duration_since`]: http://doc.rust-lang.org/nightly/std/time/struct.SystemTime.html#method.duration_since
13168[`SystemTime::elapsed`]: http://doc.rust-lang.org/nightly/std/time/struct.SystemTime.html#method.elapsed
13169[`SystemTime::now`]: http://doc.rust-lang.org/nightly/std/time/struct.SystemTime.html#method.now
13170[`SystemTimeError::duration`]: http://doc.rust-lang.org/nightly/std/time/struct.SystemTimeError.html#method.duration
13171[`SystemTimeError`]: http://doc.rust-lang.org/nightly/std/time/struct.SystemTimeError.html
13172[`UNIX_EPOCH`]: http://doc.rust-lang.org/nightly/std/time/constant.UNIX_EPOCH.html
13173[`ptr::drop_in_place`]: http://doc.rust-lang.org/nightly/std/ptr/fn.drop_in_place.html
13174[`str::EncodeUtf16`]: http://doc.rust-lang.org/nightly/std/str/struct.EncodeUtf16.html
13175[`str::encode_utf16`]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.encode_utf16
13176[`time::Instant`]: http://doc.rust-lang.org/nightly/std/time/struct.Instant.html
13177[`time::SystemTime`]: http://doc.rust-lang.org/nightly/std/time/struct.SystemTime.html
13178
13179
13180Version 1.7.0 (2016-03-03)
13181==========================
13182
13183Libraries
13184---------
13185
13186* Stabilized APIs
13187 * `Path`
13188 * [`Path::strip_prefix`] (renamed from relative_from)
13189 * [`path::StripPrefixError`] (new error type returned from strip_prefix)
13190 * `Ipv4Addr`
13191 * [`Ipv4Addr::is_loopback`]
13192 * [`Ipv4Addr::is_private`]
13193 * [`Ipv4Addr::is_link_local`]
13194 * [`Ipv4Addr::is_multicast`]
13195 * [`Ipv4Addr::is_broadcast`]
13196 * [`Ipv4Addr::is_documentation`]
13197 * `Ipv6Addr`
13198 * [`Ipv6Addr::is_unspecified`]
13199 * [`Ipv6Addr::is_loopback`]
13200 * [`Ipv6Addr::is_multicast`]
13201 * `Vec`
13202 * [`Vec::as_slice`]
13203 * [`Vec::as_mut_slice`]
13204 * `String`
13205 * [`String::as_str`]
13206 * [`String::as_mut_str`]
13207 * Slices
13208 * `<[T]>::`[`clone_from_slice`], which now requires the two slices to
13209 be the same length
13210 * `<[T]>::`[`sort_by_key`]
13211 * checked, saturated, and overflowing operations
13212 * [`i32::checked_rem`], [`i32::checked_neg`], [`i32::checked_shl`], [`i32::checked_shr`]
13213 * [`i32::saturating_mul`]
13214 * [`i32::overflowing_add`], [`i32::overflowing_sub`], [`i32::overflowing_mul`], [`i32::overflowing_div`]
13215 * [`i32::overflowing_rem`], [`i32::overflowing_neg`], [`i32::overflowing_shl`], [`i32::overflowing_shr`]
13216 * [`u32::checked_rem`], [`u32::checked_neg`], [`u32::checked_shl`], [`u32::checked_shl`]
13217 * [`u32::saturating_mul`]
13218 * [`u32::overflowing_add`], [`u32::overflowing_sub`], [`u32::overflowing_mul`], [`u32::overflowing_div`]
13219 * [`u32::overflowing_rem`], [`u32::overflowing_neg`], [`u32::overflowing_shl`], [`u32::overflowing_shr`]
13220 * and checked, saturated, and overflowing operations for other primitive types
13221 * FFI
13222 * [`ffi::IntoStringError`]
13223 * [`CString::into_string`]
13224 * [`CString::into_bytes`]
13225 * [`CString::into_bytes_with_nul`]
13226 * `From<CString> for Vec<u8>`
13227 * `IntoStringError`
13228 * [`IntoStringError::into_cstring`]
13229 * [`IntoStringError::utf8_error`]
13230 * `Error for IntoStringError`
13231 * Hashing
13232 * [`std::hash::BuildHasher`]
13233 * [`BuildHasher::Hasher`]
13234 * [`BuildHasher::build_hasher`]
13235 * [`std::hash::BuildHasherDefault`]
13236 * [`HashMap::with_hasher`]
13237 * [`HashMap::with_capacity_and_hasher`]
13238 * [`HashSet::with_hasher`]
13239 * [`HashSet::with_capacity_and_hasher`]
13240 * [`std::collections::hash_map::RandomState`]
13241 * [`RandomState::new`]
13242* [Validating UTF-8 is faster by a factor of between 7 and 14x for
13243 ASCII input][1.7utf8]. This means that creating `String`s and `str`s
13244 from bytes is faster.
13245* [The performance of `LineWriter` (and thus `io::stdout`) was
13246 improved by using `memchr` to search for newlines][1.7m].
13247* [`f32::to_degrees` and `f32::to_radians` are stable][1.7f]. The
13248 `f64` variants were stabilized previously.
13249* [`BTreeMap` was rewritten to use less memory and improve the performance
13250 of insertion and iteration, the latter by as much as 5x][1.7bm].
13251* [`BTreeSet` and its iterators, `Iter`, `IntoIter`, and `Range` are
13252 covariant over their contained type][1.7bt].
13253* [`LinkedList` and its iterators, `Iter` and `IntoIter` are covariant
13254 over their contained type][1.7ll].
13255* [`str::replace` now accepts a `Pattern`][1.7rp], like other string
13256 searching methods.
13257* [`Any` is implemented for unsized types][1.7a].
13258* [`Hash` is implemented for `Duration`][1.7h].
13259
13260Misc
13261----
13262
13263* [When running tests with `--test`, rustdoc will pass `--cfg`
13264 arguments to the compiler][1.7dt].
13265* [The compiler is built with RPATH information by default][1.7rpa].
13266 This means that it will be possible to run `rustc` when installed in
13267 unusual configurations without configuring the dynamic linker search
13268 path explicitly.
13269* [`rustc` passes `--enable-new-dtags` to GNU ld][1.7dta]. This makes
13270 any RPATH entries (emitted with `-C rpath`) *not* take precedence
13271 over `LD_LIBRARY_PATH`.
13272
13273Cargo
13274-----
13275
13276* [`cargo rustc` accepts a `--profile` flag that runs `rustc` under
13277 any of the compilation profiles, 'dev', 'bench', or 'test'][1.7cp].
13278* [The `rerun-if-changed` build script directive no longer causes the
13279 build script to incorrectly run twice in certain scenarios][1.7rr].
13280
13281Compatibility Notes
13282-------------------
13283
13284* Soundness fixes to the interactions between associated types and
13285 lifetimes, specified in [RFC 1214], [now generate errors][1.7sf] for
13286 code that violates the new rules. This is a significant change that
13287 is known to break existing code, so it has emitted warnings for the
13288 new error cases since 1.4 to give crate authors time to adapt. The
13289 details of what is changing are subtle; read the RFC for more.
13290* [Several bugs in the compiler's visibility calculations were
13291 fixed][1.7v]. Since this was found to break significant amounts of
13292 code, the new errors will be emitted as warnings for several release
13293 cycles, under the `private_in_public` lint.
13294* Defaulted type parameters were accidentally accepted in positions
13295 that were not intended. In this release, [defaulted type parameters
13296 appearing outside of type definitions will generate a
13297 warning][1.7d], which will become an error in future releases.
13298* [Parsing "." as a float results in an error instead of 0][1.7p].
13299 That is, `".".parse::<f32>()` returns `Err`, not `Ok(0.0)`.
13300* [Borrows of closure parameters may not outlive the closure][1.7bc].
13301
13302[1.7a]: https://github.com/rust-lang/rust/pull/30928
13303[1.7bc]: https://github.com/rust-lang/rust/pull/30341
13304[1.7bm]: https://github.com/rust-lang/rust/pull/30426
13305[1.7bt]: https://github.com/rust-lang/rust/pull/30998
13306[1.7cp]: https://github.com/rust-lang/cargo/pull/2224
13307[1.7d]: https://github.com/rust-lang/rust/pull/30724
13308[1.7dt]: https://github.com/rust-lang/rust/pull/30372
13309[1.7dta]: https://github.com/rust-lang/rust/pull/30394
13310[1.7f]: https://github.com/rust-lang/rust/pull/30672
13311[1.7h]: https://github.com/rust-lang/rust/pull/30818
13312[1.7ll]: https://github.com/rust-lang/rust/pull/30663
13313[1.7m]: https://github.com/rust-lang/rust/pull/30381
13314[1.7p]: https://github.com/rust-lang/rust/pull/30681
13315[1.7rp]: https://github.com/rust-lang/rust/pull/29498
13316[1.7rpa]: https://github.com/rust-lang/rust/pull/30353
13317[1.7rr]: https://github.com/rust-lang/cargo/pull/2279
13318[1.7sf]: https://github.com/rust-lang/rust/pull/30389
13319[1.7utf8]: https://github.com/rust-lang/rust/pull/30740
13320[1.7v]: https://github.com/rust-lang/rust/pull/29973
13321[RFC 1214]: https://github.com/rust-lang/rfcs/blob/master/text/1214-projections-lifetimes-and-wf.md
13322[`BuildHasher::Hasher`]: http://doc.rust-lang.org/nightly/std/hash/trait.Hasher.html
13323[`BuildHasher::build_hasher`]: http://doc.rust-lang.org/nightly/std/hash/trait.BuildHasher.html#tymethod.build_hasher
13324[`CString::into_bytes_with_nul`]: http://doc.rust-lang.org/nightly/std/ffi/struct.CString.html#method.into_bytes_with_nul
13325[`CString::into_bytes`]: http://doc.rust-lang.org/nightly/std/ffi/struct.CString.html#method.into_bytes
13326[`CString::into_string`]: http://doc.rust-lang.org/nightly/std/ffi/struct.CString.html#method.into_string
13327[`HashMap::with_capacity_and_hasher`]: http://doc.rust-lang.org/nightly/std/collections/struct.HashMap.html#method.with_capacity_and_hasher
13328[`HashMap::with_hasher`]: http://doc.rust-lang.org/nightly/std/collections/struct.HashMap.html#method.with_hasher
13329[`HashSet::with_capacity_and_hasher`]: http://doc.rust-lang.org/nightly/std/collections/struct.HashSet.html#method.with_capacity_and_hasher
13330[`HashSet::with_hasher`]: http://doc.rust-lang.org/nightly/std/collections/struct.HashSet.html#method.with_hasher
13331[`IntoStringError::into_cstring`]: http://doc.rust-lang.org/nightly/std/ffi/struct.IntoStringError.html#method.into_cstring
13332[`IntoStringError::utf8_error`]: http://doc.rust-lang.org/nightly/std/ffi/struct.IntoStringError.html#method.utf8_error
13333[`Ipv4Addr::is_broadcast`]: http://doc.rust-lang.org/nightly/std/net/struct.Ipv4Addr.html#method.is_broadcast
13334[`Ipv4Addr::is_documentation`]: http://doc.rust-lang.org/nightly/std/net/struct.Ipv4Addr.html#method.is_documentation
13335[`Ipv4Addr::is_link_local`]: http://doc.rust-lang.org/nightly/std/net/struct.Ipv4Addr.html#method.is_link_local
13336[`Ipv4Addr::is_loopback`]: http://doc.rust-lang.org/nightly/std/net/struct.Ipv4Addr.html#method.is_loopback
13337[`Ipv4Addr::is_multicast`]: http://doc.rust-lang.org/nightly/std/net/struct.Ipv4Addr.html#method.is_multicast
13338[`Ipv4Addr::is_private`]: http://doc.rust-lang.org/nightly/std/net/struct.Ipv4Addr.html#method.is_private
13339[`Ipv6Addr::is_loopback`]: http://doc.rust-lang.org/nightly/std/net/struct.Ipv6Addr.html#method.is_loopback
13340[`Ipv6Addr::is_multicast`]: http://doc.rust-lang.org/nightly/std/net/struct.Ipv6Addr.html#method.is_multicast
13341[`Ipv6Addr::is_unspecified`]: http://doc.rust-lang.org/nightly/std/net/struct.Ipv6Addr.html#method.is_unspecified
13342[`Path::strip_prefix`]: http://doc.rust-lang.org/nightly/std/path/struct.Path.html#method.strip_prefix
13343[`RandomState::new`]: http://doc.rust-lang.org/nightly/std/collections/hash_map/struct.RandomState.html#method.new
13344[`String::as_mut_str`]: http://doc.rust-lang.org/nightly/std/string/struct.String.html#method.as_mut_str
13345[`String::as_str`]: http://doc.rust-lang.org/nightly/std/string/struct.String.html#method.as_str
13346[`Vec::as_mut_slice`]: http://doc.rust-lang.org/nightly/std/vec/struct.Vec.html#method.as_mut_slice
13347[`Vec::as_slice`]: http://doc.rust-lang.org/nightly/std/vec/struct.Vec.html#method.as_slice
13348[`clone_from_slice`]: http://doc.rust-lang.org/nightly/std/primitive.slice.html#method.clone_from_slice
13349[`ffi::IntoStringError`]: http://doc.rust-lang.org/nightly/std/ffi/struct.IntoStringError.html
13350[`i32::checked_neg`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.checked_neg
13351[`i32::checked_rem`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.checked_rem
13352[`i32::checked_shl`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.checked_shl
13353[`i32::checked_shr`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.checked_shr
13354[`i32::overflowing_add`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.overflowing_add
13355[`i32::overflowing_div`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.overflowing_div
13356[`i32::overflowing_mul`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.overflowing_mul
13357[`i32::overflowing_neg`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.overflowing_neg
13358[`i32::overflowing_rem`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.overflowing_rem
13359[`i32::overflowing_shl`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.overflowing_shl
13360[`i32::overflowing_shr`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.overflowing_shr
13361[`i32::overflowing_sub`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.overflowing_sub
13362[`i32::saturating_mul`]: http://doc.rust-lang.org/nightly/std/primitive.i32.html#method.saturating_mul
13363[`path::StripPrefixError`]: http://doc.rust-lang.org/nightly/std/path/struct.StripPrefixError.html
13364[`sort_by_key`]: http://doc.rust-lang.org/nightly/std/primitive.slice.html#method.sort_by_key
13365[`std::collections::hash_map::RandomState`]: http://doc.rust-lang.org/nightly/std/collections/hash_map/struct.RandomState.html
13366[`std::hash::BuildHasherDefault`]: http://doc.rust-lang.org/nightly/std/hash/struct.BuildHasherDefault.html
13367[`std::hash::BuildHasher`]: http://doc.rust-lang.org/nightly/std/hash/trait.BuildHasher.html
13368[`u32::checked_neg`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.checked_neg
13369[`u32::checked_rem`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.checked_rem
13370[`u32::checked_neg`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.checked_neg
13371[`u32::checked_shl`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.checked_shl
13372[`u32::overflowing_add`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.overflowing_add
13373[`u32::overflowing_div`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.overflowing_div
13374[`u32::overflowing_mul`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.overflowing_mul
13375[`u32::overflowing_neg`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.overflowing_neg
13376[`u32::overflowing_rem`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.overflowing_rem
13377[`u32::overflowing_shl`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.overflowing_shl
13378[`u32::overflowing_shr`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.overflowing_shr
13379[`u32::overflowing_sub`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.overflowing_sub
13380[`u32::saturating_mul`]: http://doc.rust-lang.org/nightly/std/primitive.u32.html#method.saturating_mul
13381
13382
13383Version 1.6.0 (2016-01-21)
13384==========================
13385
13386Language
13387--------
13388
13389* The `#![no_std]` attribute causes a crate to not be linked to the
13390 standard library, but only the [core library][1.6co], as described
13391 in [RFC 1184]. The core library defines common types and traits but
13392 has no platform dependencies whatsoever, and is the basis for Rust
13393 software in environments that cannot support a full port of the
13394 standard library, such as operating systems. Most of the core
13395 library is now stable.
13396
13397Libraries
13398---------
13399
13400* Stabilized APIs:
13401 [`Read::read_exact`],
13402 [`ErrorKind::UnexpectedEof`] (renamed from `UnexpectedEOF`),
13403 [`fs::DirBuilder`], [`fs::DirBuilder::new`],
13404 [`fs::DirBuilder::recursive`], [`fs::DirBuilder::create`],
13405 [`os::unix::fs::DirBuilderExt`],
13406 [`os::unix::fs::DirBuilderExt::mode`], [`vec::Drain`],
13407 [`vec::Vec::drain`], [`string::Drain`], [`string::String::drain`],
13408 [`vec_deque::Drain`], [`vec_deque::VecDeque::drain`],
13409 [`collections::hash_map::Drain`],
13410 [`collections::hash_map::HashMap::drain`],
13411 [`collections::hash_set::Drain`],
13412 [`collections::hash_set::HashSet::drain`],
13413 [`collections::binary_heap::Drain`],
13414 [`collections::binary_heap::BinaryHeap::drain`],
13415 [`Vec::extend_from_slice`] (renamed from `push_all`),
13416 [`Mutex::get_mut`], [`Mutex::into_inner`], [`RwLock::get_mut`],
13417 [`RwLock::into_inner`],
13418 [`Iterator::min_by_key`] (renamed from `min_by`),
13419 [`Iterator::max_by_key`] (renamed from `max_by`).
13420* The [core library][1.6co] is stable, as are most of its APIs.
13421* [The `assert_eq!` macro supports arguments that don't implement
13422 `Sized`][1.6ae], such as arrays. In this way it behaves more like
13423 `assert!`.
13424* Several timer functions that take duration in milliseconds [are
13425 deprecated in favor of those that take `Duration`][1.6ms]. These
13426 include `Condvar::wait_timeout_ms`, `thread::sleep_ms`, and
13427 `thread::park_timeout_ms`.
13428* The algorithm by which `Vec` reserves additional elements was
13429 [tweaked to not allocate excessive space][1.6a] while still growing
13430 exponentially.
13431* `From` conversions are [implemented from integers to floats][1.6f]
13432 in cases where the conversion is lossless. Thus they are not
13433 implemented for 32-bit ints to `f32`, nor for 64-bit ints to `f32`
13434 or `f64`. They are also not implemented for `isize` and `usize`
13435 because the implementations would be platform-specific. `From` is
13436 also implemented from `f32` to `f64`.
13437* `From<&Path>` and `From<PathBuf>` are implemented for `Cow<Path>`.
13438* `From<T>` is implemented for `Box<T>`, `Rc<T>` and `Arc<T>`.
13439* `IntoIterator` is implemented for `&PathBuf` and `&Path`.
13440* [`BinaryHeap` was refactored][1.6bh] for modest performance
13441 improvements.
13442* Sorting slices that are already sorted [is 50% faster in some
13443 cases][1.6s].
13444
13445Cargo
13446-----
13447
13448* Cargo will look in `$CARGO_HOME/bin` for subcommands [by default][1.6c].
13449* Cargo build scripts can specify their dependencies by emitting the
13450 [`rerun-if-changed`][1.6rr] key.
13451* crates.io will reject publication of crates with dependencies that
13452 have a wildcard version constraint. Crates with wildcard
13453 dependencies were seen to cause a variety of problems, as described
13454 in [RFC 1241]. Since 1.5 publication of such crates has emitted a
13455 warning.
13456* `cargo clean` [accepts a `--release` flag][1.6cc] to clean the
13457 release folder. A variety of artifacts that Cargo failed to clean
13458 are now correctly deleted.
13459
13460Misc
13461----
13462
13463* The `unreachable_code` lint [warns when a function call's argument
13464 diverges][1.6dv].
13465* The parser indicates [failures that may be caused by
13466 confusingly-similar Unicode characters][1.6uc]
13467* Certain macro errors [are reported at definition time][1.6m], not
13468 expansion.
13469
13470Compatibility Notes
13471-------------------
13472
13473* The compiler no longer makes use of the [`RUST_PATH`][1.6rp]
13474 environment variable when locating crates. This was a pre-cargo
13475 feature for integrating with the package manager that was
13476 accidentally never removed.
13477* [A number of bugs were fixed in the privacy checker][1.6p] that
13478 could cause previously-accepted code to break.
13479* [Modules and unit/tuple structs may not share the same name][1.6ts].
13480* [Bugs in pattern matching unit structs were fixed][1.6us]. The tuple
13481 struct pattern syntax (`Foo(..)`) can no longer be used to match
13482 unit structs. This is a warning now, but will become an error in
13483 future releases. Patterns that share the same name as a const are
13484 now an error.
13485* A bug was fixed that causes [rustc not to apply default type
13486 parameters][1.6xc] when resolving certain method implementations of
13487 traits defined in other crates.
13488
13489[1.6a]: https://github.com/rust-lang/rust/pull/29454
13490[1.6ae]: https://github.com/rust-lang/rust/pull/29770
13491[1.6bh]: https://github.com/rust-lang/rust/pull/29811
13492[1.6c]: https://github.com/rust-lang/cargo/pull/2192
13493[1.6cc]: https://github.com/rust-lang/cargo/pull/2131
13494[1.6co]: http://doc.rust-lang.org/core/index.html
13495[1.6dv]: https://github.com/rust-lang/rust/pull/30000
13496[1.6f]: https://github.com/rust-lang/rust/pull/29129
13497[1.6m]: https://github.com/rust-lang/rust/pull/29828
13498[1.6ms]: https://github.com/rust-lang/rust/pull/29604
13499[1.6p]: https://github.com/rust-lang/rust/pull/29726
13500[1.6rp]: https://github.com/rust-lang/rust/pull/30034
13501[1.6rr]: https://github.com/rust-lang/cargo/pull/2134
13502[1.6s]: https://github.com/rust-lang/rust/pull/29675
13503[1.6ts]: https://github.com/rust-lang/rust/issues/21546
13504[1.6uc]: https://github.com/rust-lang/rust/pull/29837
13505[1.6us]: https://github.com/rust-lang/rust/pull/29383
13506[1.6xc]: https://github.com/rust-lang/rust/issues/30123
13507[RFC 1184]: https://github.com/rust-lang/rfcs/blob/master/text/1184-stabilize-no_std.md
13508[RFC 1241]: https://github.com/rust-lang/rfcs/blob/master/text/1241-no-wildcard-deps.md
13509[`ErrorKind::UnexpectedEof`]: http://doc.rust-lang.org/nightly/std/io/enum.ErrorKind.html#variant.UnexpectedEof
13510[`Iterator::max_by_key`]: http://doc.rust-lang.org/nightly/std/iter/trait.Iterator.html#method.max_by_key
13511[`Iterator::min_by_key`]: http://doc.rust-lang.org/nightly/std/iter/trait.Iterator.html#method.min_by_key
13512[`Mutex::get_mut`]: http://doc.rust-lang.org/nightly/std/sync/struct.Mutex.html#method.get_mut
13513[`Mutex::into_inner`]: http://doc.rust-lang.org/nightly/std/sync/struct.Mutex.html#method.into_inner
13514[`Read::read_exact`]: http://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_exact
13515[`RwLock::get_mut`]: http://doc.rust-lang.org/nightly/std/sync/struct.RwLock.html#method.get_mut
13516[`RwLock::into_inner`]: http://doc.rust-lang.org/nightly/std/sync/struct.RwLock.html#method.into_inner
13517[`Vec::extend_from_slice`]: http://doc.rust-lang.org/nightly/collections/vec/struct.Vec.html#method.extend_from_slice
13518[`collections::binary_heap::BinaryHeap::drain`]: http://doc.rust-lang.org/nightly/std/collections/binary_heap/struct.BinaryHeap.html#method.drain
13519[`collections::binary_heap::Drain`]: http://doc.rust-lang.org/nightly/std/collections/binary_heap/struct.Drain.html
13520[`collections::hash_map::Drain`]: http://doc.rust-lang.org/nightly/std/collections/hash_map/struct.Drain.html
13521[`collections::hash_map::HashMap::drain`]: http://doc.rust-lang.org/nightly/std/collections/hash_map/struct.HashMap.html#method.drain
13522[`collections::hash_set::Drain`]: http://doc.rust-lang.org/nightly/std/collections/hash_set/struct.Drain.html
13523[`collections::hash_set::HashSet::drain`]: http://doc.rust-lang.org/nightly/std/collections/hash_set/struct.HashSet.html#method.drain
13524[`fs::DirBuilder::create`]: http://doc.rust-lang.org/nightly/std/fs/struct.DirBuilder.html#method.create
13525[`fs::DirBuilder::new`]: http://doc.rust-lang.org/nightly/std/fs/struct.DirBuilder.html#method.new
13526[`fs::DirBuilder::recursive`]: http://doc.rust-lang.org/nightly/std/fs/struct.DirBuilder.html#method.recursive
13527[`fs::DirBuilder`]: http://doc.rust-lang.org/nightly/std/fs/struct.DirBuilder.html
13528[`os::unix::fs::DirBuilderExt::mode`]: http://doc.rust-lang.org/nightly/std/os/unix/fs/trait.DirBuilderExt.html#tymethod.mode
13529[`os::unix::fs::DirBuilderExt`]: http://doc.rust-lang.org/nightly/std/os/unix/fs/trait.DirBuilderExt.html
13530[`string::Drain`]: http://doc.rust-lang.org/nightly/std/string/struct.Drain.html
13531[`string::String::drain`]: http://doc.rust-lang.org/nightly/std/string/struct.String.html#method.drain
13532[`vec::Drain`]: http://doc.rust-lang.org/nightly/std/vec/struct.Drain.html
13533[`vec::Vec::drain`]: http://doc.rust-lang.org/nightly/std/vec/struct.Vec.html#method.drain
13534[`vec_deque::Drain`]: http://doc.rust-lang.org/nightly/std/collections/vec_deque/struct.Drain.html
13535[`vec_deque::VecDeque::drain`]: http://doc.rust-lang.org/nightly/std/collections/vec_deque/struct.VecDeque.html#method.drain
13536
13537
13538Version 1.5.0 (2015-12-10)
13539==========================
13540
13541* ~700 changes, numerous bugfixes
13542
13543Highlights
13544----------
13545
13546* Stabilized APIs:
13547 [`BinaryHeap::from`], [`BinaryHeap::into_sorted_vec`],
13548 [`BinaryHeap::into_vec`], [`Condvar::wait_timeout`],
13549 [`FileTypeExt::is_block_device`], [`FileTypeExt::is_char_device`],
13550 [`FileTypeExt::is_fifo`], [`FileTypeExt::is_socket`],
13551 [`FileTypeExt`], [`Formatter::alternate`], [`Formatter::fill`],
13552 [`Formatter::precision`], [`Formatter::sign_aware_zero_pad`],
13553 [`Formatter::sign_minus`], [`Formatter::sign_plus`],
13554 [`Formatter::width`], [`Iterator::cmp`], [`Iterator::eq`],
13555 [`Iterator::ge`], [`Iterator::gt`], [`Iterator::le`],
13556 [`Iterator::lt`], [`Iterator::ne`], [`Iterator::partial_cmp`],
13557 [`Path::canonicalize`], [`Path::exists`], [`Path::is_dir`],
13558 [`Path::is_file`], [`Path::metadata`], [`Path::read_dir`],
13559 [`Path::read_link`], [`Path::symlink_metadata`],
13560 [`Utf8Error::valid_up_to`], [`Vec::resize`],
13561 [`VecDeque::as_mut_slices`], [`VecDeque::as_slices`],
13562 [`VecDeque::insert`], [`VecDeque::shrink_to_fit`],
13563 [`VecDeque::swap_remove_back`], [`VecDeque::swap_remove_front`],
13564 [`slice::split_first_mut`], [`slice::split_first`],
13565 [`slice::split_last_mut`], [`slice::split_last`],
13566 [`char::from_u32_unchecked`], [`fs::canonicalize`],
13567 [`str::MatchIndices`], [`str::RMatchIndices`],
13568 [`str::match_indices`], [`str::rmatch_indices`],
13569 [`str::slice_mut_unchecked`], [`string::ParseError`].
13570* Rust applications hosted on crates.io can be installed locally to
13571 `~/.cargo/bin` with the [`cargo install`] command. Among other
13572 things this makes it easier to augment Cargo with new subcommands:
13573 when a binary named e.g. `cargo-foo` is found in `$PATH` it can be
13574 invoked as `cargo foo`.
13575* Crates with wildcard (`*`) dependencies will [emit warnings when
13576 published][1.5w]. In 1.6 it will no longer be possible to publish
13577 crates with wildcard dependencies.
13578
13579Breaking Changes
13580----------------
13581
13582* The rules determining when a particular lifetime must outlive
13583 a particular value (known as '[dropck]') have been [modified
13584 to not rely on parametricity][1.5p].
13585* [Implementations of `AsRef` and `AsMut` were added to `Box`, `Rc`,
13586 and `Arc`][1.5a]. Because these smart pointer types implement
13587 `Deref`, this causes breakage in cases where the interior type
13588 contains methods of the same name.
13589* [Correct a bug in Rc/Arc][1.5c] that caused [dropck] to be unaware
13590 that they could drop their content. Soundness fix.
13591* All method invocations are [properly checked][1.5wf1] for
13592 [well-formedness][1.5wf2]. Soundness fix.
13593* Traits whose supertraits contain `Self` are [not object
13594 safe][1.5o]. Soundness fix.
13595* Target specifications support a [`no_default_libraries`][1.5nd]
13596 setting that controls whether `-nodefaultlibs` is passed to the
13597 linker, and in turn the `is_like_windows` setting no longer affects
13598 the `-nodefaultlibs` flag.
13599* `#[derive(Show)]`, long-deprecated, [has been removed][1.5ds].
13600* The `#[inline]` and `#[repr]` attributes [can only appear
13601 in valid locations][1.5at].
13602* Native libraries linked from the local crate are [passed to
13603 the linker before native libraries from upstream crates][1.5nl].
13604* Two rarely-used attributes, `#[no_debug]` and
13605 `#[omit_gdb_pretty_printer_section]` [are feature gated][1.5fg].
13606* Negation of unsigned integers, which has been a warning for
13607 several releases, [is now behind a feature gate and will
13608 generate errors][1.5nu].
13609* The parser accidentally accepted visibility modifiers on
13610 enum variants, a bug [which has been fixed][1.5ev].
13611* [A bug was fixed that allowed `use` statements to import unstable
13612 features][1.5use].
13613
13614Language
13615--------
13616
13617* When evaluating expressions at compile-time that are not
13618 compile-time constants (const-evaluating expressions in non-const
13619 contexts), incorrect code such as overlong bitshifts and arithmetic
13620 overflow will [generate a warning instead of an error][1.5ce],
13621 delaying the error until runtime. This will allow the
13622 const-evaluator to be expanded in the future backwards-compatibly.
13623* The `improper_ctypes` lint [no longer warns about using `isize` and
13624 `usize` in FFI][1.5ict].
13625
13626Libraries
13627---------
13628
13629* `Arc<T>` and `Rc<T>` are [covariant with respect to `T` instead of
13630 invariant][1.5c].
13631* `Default` is [implemented for mutable slices][1.5d].
13632* `FromStr` is [implemented for `SockAddrV4` and `SockAddrV6`][1.5s].
13633* There are now `From` conversions [between floating point
13634 types][1.5f] where the conversions are lossless.
13635* There are now `From` conversions [between integer types][1.5i] where
13636 the conversions are lossless.
13637* [`fs::Metadata` implements `Clone`][1.5fs].
13638* The `parse` method [accepts a leading "+" when parsing
13639 integers][1.5pi].
13640* [`AsMut` is implemented for `Vec`][1.5am].
13641* The `clone_from` implementations for `String` and `BinaryHeap` [have
13642 been optimized][1.5cf] and no longer rely on the default impl.
13643* The `extern "Rust"`, `extern "C"`, `unsafe extern "Rust"` and
13644 `unsafe extern "C"` function types now [implement `Clone`,
13645 `PartialEq`, `Eq`, `PartialOrd`, `Ord`, `Hash`, `fmt::Pointer`, and
13646 `fmt::Debug` for up to 12 arguments][1.5fp].
13647* [Dropping `Vec`s is much faster in unoptimized builds when the
13648 element types don't implement `Drop`][1.5dv].
13649* A bug that caused in incorrect behavior when [combining `VecDeque`
13650 with zero-sized types][1.5vdz] was resolved.
13651* [`PartialOrd` for slices is faster][1.5po].
13652
13653Miscellaneous
13654-------------
13655
13656* [Crate metadata size was reduced by 20%][1.5md].
13657* [Improvements to code generation reduced the size of libcore by 3.3
13658 MB and rustc's memory usage by 18MB][1.5m].
13659* [Improvements to deref translation increased performance in
13660 unoptimized builds][1.5dr].
13661* Various errors in trait resolution [are deduplicated to only be
13662 reported once][1.5te].
13663* Rust has preliminary [support for rumprun kernels][1.5rr].
13664* Rust has preliminary [support for NetBSD on amd64][1.5na].
13665
13666[1.5use]: https://github.com/rust-lang/rust/pull/28364
13667[1.5po]: https://github.com/rust-lang/rust/pull/28436
13668[1.5ev]: https://github.com/rust-lang/rust/pull/28442
13669[1.5nu]: https://github.com/rust-lang/rust/pull/28468
13670[1.5dr]: https://github.com/rust-lang/rust/pull/28491
13671[1.5vdz]: https://github.com/rust-lang/rust/pull/28494
13672[1.5md]: https://github.com/rust-lang/rust/pull/28521
13673[1.5fg]: https://github.com/rust-lang/rust/pull/28522
13674[1.5dv]: https://github.com/rust-lang/rust/pull/28531
13675[1.5na]: https://github.com/rust-lang/rust/pull/28543
13676[1.5fp]: https://github.com/rust-lang/rust/pull/28560
13677[1.5rr]: https://github.com/rust-lang/rust/pull/28593
13678[1.5cf]: https://github.com/rust-lang/rust/pull/28602
13679[1.5nl]: https://github.com/rust-lang/rust/pull/28605
13680[1.5te]: https://github.com/rust-lang/rust/pull/28645
13681[1.5at]: https://github.com/rust-lang/rust/pull/28650
13682[1.5am]: https://github.com/rust-lang/rust/pull/28663
13683[1.5m]: https://github.com/rust-lang/rust/pull/28778
13684[1.5ict]: https://github.com/rust-lang/rust/pull/28779
13685[1.5a]: https://github.com/rust-lang/rust/pull/28811
13686[1.5pi]: https://github.com/rust-lang/rust/pull/28826
13687[1.5ce]: https://github.com/rust-lang/rfcs/blob/master/text/1229-compile-time-asserts.md
13688[1.5p]: https://github.com/rust-lang/rfcs/blob/master/text/1238-nonparametric-dropck.md
13689[1.5i]: https://github.com/rust-lang/rust/pull/28921
13690[1.5fs]: https://github.com/rust-lang/rust/pull/29021
13691[1.5f]: https://github.com/rust-lang/rust/pull/29129
13692[1.5ds]: https://github.com/rust-lang/rust/pull/29148
13693[1.5s]: https://github.com/rust-lang/rust/pull/29190
13694[1.5d]: https://github.com/rust-lang/rust/pull/29245
13695[1.5o]: https://github.com/rust-lang/rust/pull/29259
13696[1.5nd]: https://github.com/rust-lang/rust/pull/28578
13697[1.5wf2]: https://github.com/rust-lang/rfcs/blob/master/text/1214-projections-lifetimes-and-wf.md
13698[1.5wf1]: https://github.com/rust-lang/rust/pull/28669
13699[dropck]: https://doc.rust-lang.org/nightly/nomicon/dropck.html
13700[1.5c]: https://github.com/rust-lang/rust/pull/29110
13701[1.5w]: https://github.com/rust-lang/rfcs/blob/master/text/1241-no-wildcard-deps.md
13702[`cargo install`]: https://github.com/rust-lang/rfcs/blob/master/text/1200-cargo-install.md
13703[`BinaryHeap::from`]: http://doc.rust-lang.org/nightly/std/convert/trait.From.html#method.from
13704[`BinaryHeap::into_sorted_vec`]: http://doc.rust-lang.org/nightly/std/collections/struct.BinaryHeap.html#method.into_sorted_vec
13705[`BinaryHeap::into_vec`]: http://doc.rust-lang.org/nightly/std/collections/struct.BinaryHeap.html#method.into_vec
13706[`Condvar::wait_timeout`]: http://doc.rust-lang.org/nightly/std/sync/struct.Condvar.html#method.wait_timeout
13707[`FileTypeExt::is_block_device`]: http://doc.rust-lang.org/nightly/std/os/unix/fs/trait.FileTypeExt.html#tymethod.is_block_device
13708[`FileTypeExt::is_char_device`]: http://doc.rust-lang.org/nightly/std/os/unix/fs/trait.FileTypeExt.html#tymethod.is_char_device
13709[`FileTypeExt::is_fifo`]: http://doc.rust-lang.org/nightly/std/os/unix/fs/trait.FileTypeExt.html#tymethod.is_fifo
13710[`FileTypeExt::is_socket`]: http://doc.rust-lang.org/nightly/std/os/unix/fs/trait.FileTypeExt.html#tymethod.is_socket
13711[`FileTypeExt`]: http://doc.rust-lang.org/nightly/std/os/unix/fs/trait.FileTypeExt.html
13712[`Formatter::alternate`]: http://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.alternate
13713[`Formatter::fill`]: http://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.fill
13714[`Formatter::precision`]: http://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.precision
13715[`Formatter::sign_aware_zero_pad`]: http://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.sign_aware_zero_pad
13716[`Formatter::sign_minus`]: http://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.sign_minus
13717[`Formatter::sign_plus`]: http://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.sign_plus
13718[`Formatter::width`]: http://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.width
13719[`Iterator::cmp`]: http://doc.rust-lang.org/nightly/core/iter/trait.Iterator.html#method.cmp
13720[`Iterator::eq`]: http://doc.rust-lang.org/nightly/core/iter/trait.Iterator.html#method.eq
13721[`Iterator::ge`]: http://doc.rust-lang.org/nightly/core/iter/trait.Iterator.html#method.ge
13722[`Iterator::gt`]: http://doc.rust-lang.org/nightly/core/iter/trait.Iterator.html#method.gt
13723[`Iterator::le`]: http://doc.rust-lang.org/nightly/core/iter/trait.Iterator.html#method.le
13724[`Iterator::lt`]: http://doc.rust-lang.org/nightly/core/iter/trait.Iterator.html#method.lt
13725[`Iterator::ne`]: http://doc.rust-lang.org/nightly/core/iter/trait.Iterator.html#method.ne
13726[`Iterator::partial_cmp`]: http://doc.rust-lang.org/nightly/core/iter/trait.Iterator.html#method.partial_cmp
13727[`Path::canonicalize`]: http://doc.rust-lang.org/nightly/std/path/struct.Path.html#method.canonicalize
13728[`Path::exists`]: http://doc.rust-lang.org/nightly/std/path/struct.Path.html#method.exists
13729[`Path::is_dir`]: http://doc.rust-lang.org/nightly/std/path/struct.Path.html#method.is_dir
13730[`Path::is_file`]: http://doc.rust-lang.org/nightly/std/path/struct.Path.html#method.is_file
13731[`Path::metadata`]: http://doc.rust-lang.org/nightly/std/path/struct.Path.html#method.metadata
13732[`Path::read_dir`]: http://doc.rust-lang.org/nightly/std/path/struct.Path.html#method.read_dir
13733[`Path::read_link`]: http://doc.rust-lang.org/nightly/std/path/struct.Path.html#method.read_link
13734[`Path::symlink_metadata`]: http://doc.rust-lang.org/nightly/std/path/struct.Path.html#method.symlink_metadata
13735[`Utf8Error::valid_up_to`]: http://doc.rust-lang.org/nightly/core/str/struct.Utf8Error.html#method.valid_up_to
13736[`Vec::resize`]: http://doc.rust-lang.org/nightly/std/vec/struct.Vec.html#method.resize
13737[`VecDeque::as_mut_slices`]: http://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.as_mut_slices
13738[`VecDeque::as_slices`]: http://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.as_slices
13739[`VecDeque::insert`]: http://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.insert
13740[`VecDeque::shrink_to_fit`]: http://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.shrink_to_fit
13741[`VecDeque::swap_remove_back`]: http://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.swap_remove_back
13742[`VecDeque::swap_remove_front`]: http://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.swap_remove_front
13743[`slice::split_first_mut`]: http://doc.rust-lang.org/nightly/std/primitive.slice.html#method.split_first_mut
13744[`slice::split_first`]: http://doc.rust-lang.org/nightly/std/primitive.slice.html#method.split_first
13745[`slice::split_last_mut`]: http://doc.rust-lang.org/nightly/std/primitive.slice.html#method.split_last_mut
13746[`slice::split_last`]: http://doc.rust-lang.org/nightly/std/primitive.slice.html#method.split_last
13747[`char::from_u32_unchecked`]: http://doc.rust-lang.org/nightly/std/char/fn.from_u32_unchecked.html
13748[`fs::canonicalize`]: http://doc.rust-lang.org/nightly/std/fs/fn.canonicalize.html
13749[`str::MatchIndices`]: http://doc.rust-lang.org/nightly/std/str/struct.MatchIndices.html
13750[`str::RMatchIndices`]: http://doc.rust-lang.org/nightly/std/str/struct.RMatchIndices.html
13751[`str::match_indices`]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.match_indices
13752[`str::rmatch_indices`]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.rmatch_indices
13753[`str::slice_mut_unchecked`]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.slice_mut_unchecked
13754[`string::ParseError`]: http://doc.rust-lang.org/nightly/std/string/enum.ParseError.html
13755
13756Version 1.4.0 (2015-10-29)
13757==========================
13758
13759* ~1200 changes, numerous bugfixes
13760
13761Highlights
13762----------
13763
13764* Windows builds targeting the 64-bit MSVC ABI and linker (instead of
13765 GNU) are now supported and recommended for use.
13766
13767Breaking Changes
13768----------------
13769
13770* [Several changes have been made to fix type soundness and improve
13771 the behavior of associated types][sound]. See [RFC 1214]. Although
13772 we have mostly introduced these changes as warnings this release, to
13773 become errors next release, there are still some scenarios that will
13774 see immediate breakage.
13775* [The `str::lines` and `BufRead::lines` iterators treat `\r\n` as
13776 line breaks in addition to `\n`][crlf].
13777* [Loans of `'static` lifetime extend to the end of a function][stat].
13778* [`str::parse` no longer introduces avoidable rounding error when
13779 parsing floating point numbers. Together with earlier changes to
13780 float formatting/output, "round trips" like f.to_string().parse()
13781 now preserve the value of f exactly. Additionally, leading plus
13782 signs are now accepted][fp3].
13783
13784
13785Language
13786--------
13787
13788* `use` statements that import multiple items [can now rename
13789 them][i], as in `use foo::{bar as kitten, baz as puppy}`.
13790* [Binops work correctly on fat pointers][binfat].
13791* `pub extern crate`, which does not behave as expected, [issues a
13792 warning][pec] until a better solution is found.
13793
13794Libraries
13795---------
13796
13797* [Many APIs were stabilized][stab]: `<Box<str>>::into_string`,
13798 [`Arc::downgrade`], [`Arc::get_mut`], [`Arc::make_mut`],
13799 [`Arc::try_unwrap`], [`Box::from_raw`], [`Box::into_raw`], [`CStr::to_str`],
13800 [`CStr::to_string_lossy`], [`CString::from_raw`], [`CString::into_raw`],
13801 [`IntoRawFd::into_raw_fd`], [`IntoRawFd`],
13802 `IntoRawHandle::into_raw_handle`, `IntoRawHandle`,
13803 `IntoRawSocket::into_raw_socket`, `IntoRawSocket`, [`Rc::downgrade`],
13804 [`Rc::get_mut`], [`Rc::make_mut`], [`Rc::try_unwrap`], [`Result::expect`],
13805 [`String::into_boxed_str`], [`TcpStream::read_timeout`],
13806 [`TcpStream::set_read_timeout`], [`TcpStream::set_write_timeout`],
13807 [`TcpStream::write_timeout`], [`UdpSocket::read_timeout`],
13808 [`UdpSocket::set_read_timeout`], [`UdpSocket::set_write_timeout`],
13809 [`UdpSocket::write_timeout`], `Vec::append`, `Vec::split_off`,
13810 [`VecDeque::append`], [`VecDeque::retain`], [`VecDeque::split_off`],
13811 [`rc::Weak::upgrade`], [`rc::Weak`], [`slice::Iter::as_slice`],
13812 [`slice::IterMut::into_slice`], [`str::CharIndices::as_str`],
13813 [`str::Chars::as_str`], [`str::split_at_mut`], [`str::split_at`],
13814 [`sync::Weak::upgrade`], [`sync::Weak`], [`thread::park_timeout`],
13815 [`thread::sleep`].
13816* [Some APIs were deprecated][dep]: `BTreeMap::with_b`,
13817 `BTreeSet::with_b`, `Option::as_mut_slice`, `Option::as_slice`,
13818 `Result::as_mut_slice`, `Result::as_slice`, `f32::from_str_radix`,
13819 `f64::from_str_radix`.
13820* [Reverse-searching strings is faster with the 'two-way'
13821 algorithm][s].
13822* [`std::io::copy` allows `?Sized` arguments][cc].
13823* The `Windows`, `Chunks`, and `ChunksMut` iterators over slices all
13824 [override `count`, `nth` and `last` with an *O*(1)
13825 implementation][it].
13826* [`Default` is implemented for arrays up to `[T; 32]`][d].
13827* [`IntoRawFd` has been added to the Unix-specific prelude,
13828 `IntoRawSocket` and `IntoRawHandle` to the Windows-specific
13829 prelude][pr].
13830* [`Extend<String>` and `FromIterator<String` are both implemented for
13831 `String`][es].
13832* [`IntoIterator` is implemented for references to `Option` and
13833 `Result`][into2].
13834* [`HashMap` and `HashSet` implement `Extend<&T>` where `T:
13835 Copy`][ext] as part of [RFC 839]. This will cause type inference
13836 breakage in rare situations.
13837* [`BinaryHeap` implements `Debug`][bh2].
13838* [`Borrow` and `BorrowMut` are implemented for fixed-size
13839 arrays][bm].
13840* [`extern fn`s with the "Rust" and "C" ABIs implement common
13841 traits including `Eq`, `Ord`, `Debug`, `Hash`][fp].
13842* [String comparison is faster][faststr].
13843* `&mut T` where `T: std::fmt::Write` [also implements
13844 `std::fmt::Write`][mutw].
13845* [A stable regression in `VecDeque::push_back` and other
13846 capacity-altering methods that caused panics for zero-sized types
13847 was fixed][vd].
13848* [Function pointers implement traits for up to 12 parameters][fp2].
13849
13850Miscellaneous
13851-------------
13852
13853* The compiler [no longer uses the 'morestack' feature to prevent
13854 stack overflow][mm]. Instead it uses guard pages and stack
13855 probes (though stack probes are not yet implemented on any platform
13856 but Windows).
13857* [The compiler matches traits faster when projections are involved][p].
13858* The 'improper_ctypes' lint [no longer warns about use of `isize` and
13859 `usize`][ffi].
13860* [Cargo now displays useful information about what its doing during
13861 `cargo update`][cu].
13862
13863[`Arc::downgrade`]: http://doc.rust-lang.org/nightly/alloc/arc/struct.Arc.html#method.downgrade
13864[`Arc::make_mut`]: http://doc.rust-lang.org/nightly/alloc/arc/struct.Arc.html#method.make_mut
13865[`Arc::get_mut`]: http://doc.rust-lang.org/nightly/alloc/arc/struct.Arc.html#method.get_mut
13866[`Arc::try_unwrap`]: http://doc.rust-lang.org/nightly/alloc/arc/struct.Arc.html#method.try_unwrap
13867[`Box::from_raw`]: http://doc.rust-lang.org/nightly/alloc/boxed/struct.Box.html#method.from_raw
13868[`Box::into_raw`]: http://doc.rust-lang.org/nightly/alloc/boxed/struct.Box.html#method.into_raw
13869[`CStr::to_str`]: http://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.to_str
13870[`CStr::to_string_lossy`]: http://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html#method.to_string_lossy
13871[`CString::from_raw`]: http://doc.rust-lang.org/nightly/std/ffi/struct.CString.html#method.from_raw
13872[`CString::into_raw`]: http://doc.rust-lang.org/nightly/std/ffi/struct.CString.html#method.into_raw
13873[`IntoRawFd::into_raw_fd`]: http://doc.rust-lang.org/nightly/std/os/unix/io/trait.IntoRawFd.html#tymethod.into_raw_fd
13874[`IntoRawFd`]: http://doc.rust-lang.org/nightly/std/os/unix/io/trait.IntoRawFd.html
13875[`Rc::downgrade`]: http://doc.rust-lang.org/nightly/alloc/rc/struct.Rc.html#method.downgrade
13876[`Rc::get_mut`]: http://doc.rust-lang.org/nightly/alloc/rc/struct.Rc.html#method.get_mut
13877[`Rc::make_mut`]: http://doc.rust-lang.org/nightly/alloc/rc/struct.Rc.html#method.make_mut
13878[`Rc::try_unwrap`]: http://doc.rust-lang.org/nightly/alloc/rc/struct.Rc.html#method.try_unwrap
13879[`Result::expect`]: http://doc.rust-lang.org/nightly/core/result/enum.Result.html#method.expect
13880[`String::into_boxed_str`]: http://doc.rust-lang.org/nightly/collections/string/struct.String.html#method.into_boxed_str
13881[`TcpStream::read_timeout`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.read_timeout
13882[`TcpStream::set_read_timeout`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_read_timeout
13883[`TcpStream::write_timeout`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.write_timeout
13884[`TcpStream::set_write_timeout`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_write_timeout
13885[`UdpSocket::read_timeout`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.read_timeout
13886[`UdpSocket::set_read_timeout`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_read_timeout
13887[`UdpSocket::write_timeout`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.write_timeout
13888[`UdpSocket::set_write_timeout`]: http://doc.rust-lang.org/nightly/std/net/struct.TcpStream.html#method.set_write_timeout
13889[`VecDeque::append`]: http://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.append
13890[`VecDeque::retain`]: http://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.retain
13891[`VecDeque::split_off`]: http://doc.rust-lang.org/nightly/std/collections/struct.VecDeque.html#method.split_off
13892[`rc::Weak::upgrade`]: http://doc.rust-lang.org/nightly/std/rc/struct.Weak.html#method.upgrade
13893[`rc::Weak`]: http://doc.rust-lang.org/nightly/std/rc/struct.Weak.html
13894[`slice::Iter::as_slice`]: http://doc.rust-lang.org/nightly/std/slice/struct.Iter.html#method.as_slice
13895[`slice::IterMut::into_slice`]: http://doc.rust-lang.org/nightly/std/slice/struct.IterMut.html#method.into_slice
13896[`str::CharIndices::as_str`]: http://doc.rust-lang.org/nightly/std/str/struct.CharIndices.html#method.as_str
13897[`str::Chars::as_str`]: http://doc.rust-lang.org/nightly/std/str/struct.Chars.html#method.as_str
13898[`str::split_at_mut`]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.split_at_mut
13899[`str::split_at`]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.split_at
13900[`sync::Weak::upgrade`]: http://doc.rust-lang.org/nightly/std/sync/struct.Weak.html#method.upgrade
13901[`sync::Weak`]: http://doc.rust-lang.org/nightly/std/sync/struct.Weak.html
13902[`thread::park_timeout`]: http://doc.rust-lang.org/nightly/std/thread/fn.park_timeout.html
13903[`thread::sleep`]: http://doc.rust-lang.org/nightly/std/thread/fn.sleep.html
13904[bh2]: https://github.com/rust-lang/rust/pull/28156
13905[binfat]: https://github.com/rust-lang/rust/pull/28270
13906[bm]: https://github.com/rust-lang/rust/pull/28197
13907[cc]: https://github.com/rust-lang/rust/pull/27531
13908[crlf]: https://github.com/rust-lang/rust/pull/28034
13909[cu]: https://github.com/rust-lang/cargo/pull/1931
13910[d]: https://github.com/rust-lang/rust/pull/27825
13911[dep]: https://github.com/rust-lang/rust/pull/28339
13912[es]: https://github.com/rust-lang/rust/pull/27956
13913[ext]: https://github.com/rust-lang/rust/pull/28094
13914[faststr]: https://github.com/rust-lang/rust/pull/28338
13915[ffi]: https://github.com/rust-lang/rust/pull/28779
13916[fp]: https://github.com/rust-lang/rust/pull/28268
13917[fp2]: https://github.com/rust-lang/rust/pull/28560
13918[fp3]: https://github.com/rust-lang/rust/pull/27307
13919[i]: https://github.com/rust-lang/rust/pull/27451
13920[into2]: https://github.com/rust-lang/rust/pull/28039
13921[it]: https://github.com/rust-lang/rust/pull/27652
13922[mm]: https://github.com/rust-lang/rust/pull/27338
13923[mutw]: https://github.com/rust-lang/rust/pull/28368
13924[sound]: https://github.com/rust-lang/rust/pull/27641
13925[p]: https://github.com/rust-lang/rust/pull/27866
13926[pec]: https://github.com/rust-lang/rust/pull/28486
13927[pr]: https://github.com/rust-lang/rust/pull/27896
13928[RFC 839]: https://github.com/rust-lang/rfcs/blob/master/text/0839-embrace-extend-extinguish.md
13929[RFC 1214]: https://github.com/rust-lang/rfcs/blob/master/text/1214-projections-lifetimes-and-wf.md
13930[s]: https://github.com/rust-lang/rust/pull/27474
13931[stab]: https://github.com/rust-lang/rust/pull/28339
13932[stat]: https://github.com/rust-lang/rust/pull/28321
13933[vd]: https://github.com/rust-lang/rust/pull/28494
13934
13935Version 1.3.0 (2015-09-17)
13936==============================
13937
13938* ~900 changes, numerous bugfixes
13939
13940Highlights
13941----------
13942
13943* The [new object lifetime defaults][nold] have been [turned
13944 on][nold2] after a cycle of warnings about the change. Now types
13945 like `&'a Box<Trait>` (or `&'a Rc<Trait>`, etc) will change from
13946 being interpreted as `&'a Box<Trait+'a>` to `&'a
13947 Box<Trait+'static>`.
13948* [The Rustonomicon][nom] is a new book in the official documentation
13949 that dives into writing unsafe Rust.
13950* The [`Duration`] API, [has been stabilized][ds]. This basic unit of
13951 timekeeping is employed by other std APIs, as well as out-of-tree
13952 time crates.
13953
13954Breaking Changes
13955----------------
13956
13957* The [new object lifetime defaults][nold] have been [turned
13958 on][nold2] after a cycle of warnings about the change.
13959* There is a known [regression][lr] in how object lifetime elision is
13960 interpreted, the proper solution for which is undetermined.
13961* The `#[prelude_import]` attribute, an internal implementation
13962 detail, was accidentally stabilized previously. [It has been put
13963 behind the `prelude_import` feature gate][pi]. This change is
13964 believed to break no existing code.
13965* The behavior of [`size_of_val`][dst1] and [`align_of_val`][dst2] is
13966 [more sane for dynamically sized types][dst3]. Code that relied on
13967 the previous behavior is thought to be broken.
13968* The `dropck` rules, which checks that destructors can't access
13969 destroyed values, [have been updated][dropck] to match the
13970 [RFC][dropckrfc]. This fixes some soundness holes, and as such will
13971 cause some previously-compiling code to no longer build.
13972
13973Language
13974--------
13975
13976* The [new object lifetime defaults][nold] have been [turned
13977 on][nold2] after a cycle of warnings about the change.
13978* Semicolons may [now follow types and paths in
13979 macros](https://github.com/rust-lang/rust/pull/27000).
13980* The behavior of [`size_of_val`][dst1] and [`align_of_val`][dst2] is
13981 [more sane for dynamically sized types][dst3]. Code that relied on
13982 the previous behavior is not known to exist, and suspected to be
13983 broken.
13984* `'static` variables [may now be recursive][st].
13985* `ref` bindings choose between [`Deref`] and [`DerefMut`]
13986 implementations correctly.
13987* The `dropck` rules, which checks that destructors can't access
13988 destroyed values, [have been updated][dropck] to match the
13989 [RFC][dropckrfc].
13990
13991Libraries
13992---------
13993
13994* The [`Duration`] API, [has been stabilized][ds], as well as the
13995 `std::time` module, which presently contains only `Duration`.
13996* `Box<str>` and `Box<[T]>` both implement `Clone`.
13997* The owned C string, [`CString`], implements [`Borrow`] and the
13998 borrowed C string, [`CStr`], implements [`ToOwned`]. The two of
13999 these allow C strings to be borrowed and cloned in generic code.
14000* [`CStr`] implements [`Debug`].
14001* [`AtomicPtr`] implements [`Debug`].
14002* [`Error`] trait objects [can be downcast to their concrete types][e]
14003 in many common configurations, using the [`is`], [`downcast`],
14004 [`downcast_ref`] and [`downcast_mut`] methods, similarly to the
14005 [`Any`] trait.
14006* Searching for substrings now [employs the two-way algorithm][search]
14007 instead of doing a naive search. This gives major speedups to a
14008 number of methods, including [`contains`][sc], [`find`][sf],
14009 [`rfind`][srf], [`split`][ss]. [`starts_with`][ssw] and
14010 [`ends_with`][sew] are also faster.
14011* The performance of `PartialEq` for slices is [much faster][ps].
14012* The [`Hash`] trait offers the default method, [`hash_slice`], which
14013 is overridden and optimized by the implementations for scalars.
14014* The [`Hasher`] trait now has a number of specialized `write_*`
14015 methods for primitive types, for efficiency.
14016* The I/O-specific error type, [`std::io::Error`][ie], gained a set of
14017 methods for accessing the 'inner error', if any: [`get_ref`][iegr],
14018 [`get_mut`][iegm], [`into_inner`][ieii]. As well, the implementation
14019 of [`std::error::Error::cause`][iec] also delegates to the inner
14020 error.
14021* [`process::Child`][pc] gained the [`id`] method, which returns a
14022 `u32` representing the platform-specific process identifier.
14023* The [`connect`] method on slices is deprecated, replaced by the new
14024 [`join`] method (note that both of these are on the *unstable*
14025 [`SliceConcatExt`] trait, but through the magic of the prelude are
14026 available to stable code anyway).
14027* The [`Div`] operator is implemented for [`Wrapping`] types.
14028* [`DerefMut` is implemented for `String`][dms].
14029* Performance of SipHash (the default hasher for `HashMap`) is
14030 [better for long data][sh].
14031* [`AtomicPtr`] implements [`Send`].
14032* The [`read_to_end`] implementations for [`Stdin`] and [`File`]
14033 are now [specialized to use uninitialized buffers for increased
14034 performance][rte].
14035* Lifetime parameters of foreign functions [are now resolved
14036 properly][f].
14037
14038Misc
14039----
14040
14041* Rust can now, with some coercion, [produce programs that run on
14042 Windows XP][xp], though XP is not considered a supported platform.
14043* Porting Rust on Windows from the GNU toolchain to MSVC continues
14044 ([1][win1], [2][win2], [3][win3], [4][win4]). It is still not
14045 recommended for use in 1.3, though should be fully-functional
14046 in the [64-bit 1.4 beta][b14].
14047* On Fedora-based systems installation will [properly configure the
14048 dynamic linker][fl].
14049* The compiler gained many new extended error descriptions, which can
14050 be accessed with the `--explain` flag.
14051* The `dropck` pass, which checks that destructors can't access
14052 destroyed values, [has been rewritten][27261]. This fixes some
14053 soundness holes, and as such will cause some previously-compiling
14054 code to no longer build.
14055* `rustc` now uses [LLVM to write archive files where possible][ar].
14056 Eventually this will eliminate the compiler's dependency on the ar
14057 utility.
14058* Rust has [preliminary support for i686 FreeBSD][26959] (it has long
14059 supported FreeBSD on x86_64).
14060* The [`unused_mut`][lum], [`unconditional_recursion`][lur],
14061 [`improper_ctypes`][lic], and [`negate_unsigned`][lnu] lints are
14062 more strict.
14063* If landing pads are disabled (with `-Z no-landing-pads`), [`panic!`
14064 will kill the process instead of leaking][nlp].
14065
14066[`Any`]: http://doc.rust-lang.org/nightly/std/any/trait.Any.html
14067[`AtomicPtr`]: http://doc.rust-lang.org/nightly/std/sync/atomic/struct.AtomicPtr.html
14068[`Borrow`]: http://doc.rust-lang.org/nightly/std/borrow/trait.Borrow.html
14069[`CStr`]: http://doc.rust-lang.org/nightly/std/ffi/struct.CStr.html
14070[`CString`]: http://doc.rust-lang.org/nightly/std/ffi/struct.CString.html
14071[`Debug`]: http://doc.rust-lang.org/nightly/std/fmt/trait.Debug.html
14072[`DerefMut`]: http://doc.rust-lang.org/nightly/std/ops/trait.DerefMut.html
14073[`Deref`]: http://doc.rust-lang.org/nightly/std/ops/trait.Deref.html
14074[`Div`]: http://doc.rust-lang.org/nightly/std/ops/trait.Div.html
14075[`Duration`]: http://doc.rust-lang.org/nightly/std/time/struct.Duration.html
14076[`Error`]: http://doc.rust-lang.org/nightly/std/error/trait.Error.html
14077[`File`]: http://doc.rust-lang.org/nightly/std/fs/struct.File.html
14078[`Hash`]: http://doc.rust-lang.org/nightly/std/hash/trait.Hash.html
14079[`Hasher`]: http://doc.rust-lang.org/nightly/std/hash/trait.Hasher.html
14080[`Send`]: http://doc.rust-lang.org/nightly/std/marker/trait.Send.html
14081[`SliceConcatExt`]: http://doc.rust-lang.org/nightly/std/slice/trait.SliceConcatExt.html
14082[`Stdin`]: http://doc.rust-lang.org/nightly/std/io/struct.Stdin.html
14083[`ToOwned`]: http://doc.rust-lang.org/nightly/std/borrow/trait.ToOwned.html
14084[`Wrapping`]: http://doc.rust-lang.org/nightly/std/num/struct.Wrapping.html
14085[`connect`]: http://doc.rust-lang.org/nightly/std/slice/trait.SliceConcatExt.html#method.connect
14086[`downcast_mut`]: http://doc.rust-lang.org/nightly/std/error/trait.Error.html#method.downcast_mut
14087[`downcast_ref`]: http://doc.rust-lang.org/nightly/std/error/trait.Error.html#method.downcast_ref
14088[`downcast`]: http://doc.rust-lang.org/nightly/std/error/trait.Error.html#method.downcast
14089[`hash_slice`]: http://doc.rust-lang.org/nightly/std/hash/trait.Hash.html#method.hash_slice
14090[`id`]: http://doc.rust-lang.org/nightly/std/process/struct.Child.html#method.id
14091[`is`]: http://doc.rust-lang.org/nightly/std/error/trait.Error.html#method.is
14092[`join`]: http://doc.rust-lang.org/nightly/std/slice/trait.SliceConcatExt.html#method.join
14093[`read_to_end`]: http://doc.rust-lang.org/nightly/std/io/trait.Read.html#method.read_to_end
14094[ar]: https://github.com/rust-lang/rust/pull/26926
14095[b14]: https://static.rust-lang.org/dist/rust-beta-x86_64-pc-windows-msvc.msi
14096[dms]: https://github.com/rust-lang/rust/pull/26241
14097[27261]: https://github.com/rust-lang/rust/pull/27261
14098[dropckrfc]: https://github.com/rust-lang/rfcs/blob/master/text/0769-sound-generic-drop.md
14099[ds]: https://github.com/rust-lang/rust/pull/26818
14100[dst1]: http://doc.rust-lang.org/nightly/std/mem/fn.size_of_val.html
14101[dst2]: http://doc.rust-lang.org/nightly/std/mem/fn.align_of_val.html
14102[dst3]: https://github.com/rust-lang/rust/pull/27351
14103[e]: https://github.com/rust-lang/rust/pull/24793
14104[f]: https://github.com/rust-lang/rust/pull/26588
14105[26959]: https://github.com/rust-lang/rust/pull/26959
14106[fl]: https://github.com/rust-lang/rust-installer/pull/41
14107[ie]: http://doc.rust-lang.org/nightly/std/io/struct.Error.html
14108[iec]: http://doc.rust-lang.org/nightly/std/io/struct.Error.html#method.cause
14109[iegm]: http://doc.rust-lang.org/nightly/std/io/struct.Error.html#method.get_mut
14110[iegr]: http://doc.rust-lang.org/nightly/std/io/struct.Error.html#method.get_ref
14111[ieii]: http://doc.rust-lang.org/nightly/std/io/struct.Error.html#method.into_inner
14112[lic]: https://github.com/rust-lang/rust/pull/26583
14113[lnu]: https://github.com/rust-lang/rust/pull/27026
14114[lr]: https://github.com/rust-lang/rust/issues/27248
14115[lum]: https://github.com/rust-lang/rust/pull/26378
14116[lur]: https://github.com/rust-lang/rust/pull/26783
14117[nlp]: https://github.com/rust-lang/rust/pull/27176
14118[nold2]: https://github.com/rust-lang/rust/pull/27045
14119[nold]: https://github.com/rust-lang/rfcs/blob/master/text/1156-adjust-default-object-bounds.md
14120[nom]: http://doc.rust-lang.org/nightly/nomicon/
14121[pc]: http://doc.rust-lang.org/nightly/std/process/struct.Child.html
14122[pi]: https://github.com/rust-lang/rust/pull/26699
14123[ps]: https://github.com/rust-lang/rust/pull/26884
14124[rte]: https://github.com/rust-lang/rust/pull/26950
14125[sc]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.contains
14126[search]: https://github.com/rust-lang/rust/pull/26327
14127[sew]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.ends_with
14128[sf]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.find
14129[sh]: https://github.com/rust-lang/rust/pull/27280
14130[srf]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.rfind
14131[ss]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.split
14132[ssw]: http://doc.rust-lang.org/nightly/std/primitive.str.html#method.starts_with
14133[st]: https://github.com/rust-lang/rust/pull/26630
14134[win1]: https://github.com/rust-lang/rust/pull/26569
14135[win2]: https://github.com/rust-lang/rust/pull/26741
14136[win3]: https://github.com/rust-lang/rust/pull/26741
14137[win4]: https://github.com/rust-lang/rust/pull/27210
14138[xp]: https://github.com/rust-lang/rust/pull/26569
14139
14140Version 1.2.0 (2015-08-07)
14141==========================
14142
14143* ~1200 changes, numerous bugfixes
14144
14145Highlights
14146----------
14147
14148* [Dynamically-sized-type coercions][dst] allow smart pointer types
14149 like `Rc` to contain types without a fixed size, arrays and trait
14150 objects, finally enabling use of `Rc<[T]>` and completing the
14151 implementation of DST.
14152* [Parallel codegen][parcodegen] is now working again, which can
14153 substantially speed up large builds in debug mode; It also gets
14154 another ~33% speedup when bootstrapping on a 4 core machine (using 8
14155 jobs). It's not enabled by default, but will be "in the near
14156 future". It can be activated with the `-C codegen-units=N` flag to
14157 `rustc`.
14158* This is the first release with [experimental support for linking
14159 with the MSVC linker and lib C on Windows (instead of using the GNU
14160 variants via MinGW)][win]. It is yet recommended only for the most
14161 intrepid Rustaceans.
14162* Benchmark compilations are showing a 30% improvement in
14163 bootstrapping over 1.1.
14164
14165Breaking Changes
14166----------------
14167
14168* The [`to_uppercase`] and [`to_lowercase`] methods on `char` now do
14169 unicode case mapping, which is a previously-planned change in
14170 behavior and considered a bugfix.
14171* [`mem::align_of`] now specifies [the *minimum alignment* for
14172 T][align], which is usually the alignment programs are interested
14173 in, and the same value reported by clang's
14174 `alignof`. [`mem::min_align_of`] is deprecated. This is not known to
14175 break real code.
14176* [The `#[packed]` attribute is no longer silently accepted by the
14177 compiler][packed]. This attribute did nothing and code that
14178 mentioned it likely did not work as intended.
14179* Associated type defaults are [now behind the
14180 `associated_type_defaults` feature gate][ad]. In 1.1 associated type
14181 defaults *did not work*, but could be mentioned syntactically. As
14182 such this breakage has minimal impact.
14183
14184Language
14185--------
14186
14187* Patterns with `ref mut` now correctly invoke [`DerefMut`] when
14188 matching against dereferenceable values.
14189
14190Libraries
14191---------
14192
14193* The [`Extend`] trait, which grows a collection from an iterator, is
14194 implemented over iterators of references, for `String`, `Vec`,
14195 `LinkedList`, `VecDeque`, `EnumSet`, `BinaryHeap`, `VecMap`,
14196 `BTreeSet` and `BTreeMap`. [RFC][extend-rfc].
14197* The [`iter::once`] function returns an iterator that yields a single
14198 element, and [`iter::empty`] returns an iterator that yields no
14199 elements.
14200* The [`matches`] and [`rmatches`] methods on `str` return iterators
14201 over substring matches.
14202* [`Cell`] and [`RefCell`] both implement `Eq`.
14203* A number of methods for wrapping arithmetic are added to the
14204 integral types, [`wrapping_div`], [`wrapping_rem`],
14205 [`wrapping_neg`], [`wrapping_shl`], [`wrapping_shr`]. These are in
14206 addition to the existing [`wrapping_add`], [`wrapping_sub`], and
14207 [`wrapping_mul`] methods, and alternatives to the [`Wrapping`]
14208 type.. It is illegal for the default arithmetic operations in Rust
14209 to overflow; the desire to wrap must be explicit.
14210* The `{:#?}` formatting specifier [displays the alternate,
14211 pretty-printed][debugfmt] form of the `Debug` formatter. This
14212 feature was actually introduced prior to 1.0 with little
14213 fanfare.
14214* [`fmt::Formatter`] implements [`fmt::Write`], a `fmt`-specific trait
14215 for writing data to formatted strings, similar to [`io::Write`].
14216* [`fmt::Formatter`] adds 'debug builder' methods, [`debug_struct`],
14217 [`debug_tuple`], [`debug_list`], [`debug_set`], [`debug_map`]. These
14218 are used by code generators to emit implementations of [`Debug`].
14219* `str` has new [`to_uppercase`][strup] and [`to_lowercase`][strlow]
14220 methods that convert case, following Unicode case mapping.
14221* It is now easier to handle poisoned locks. The [`PoisonError`]
14222 type, returned by failing lock operations, exposes `into_inner`,
14223 `get_ref`, and `get_mut`, which all give access to the inner lock
14224 guard, and allow the poisoned lock to continue to operate. The
14225 `is_poisoned` method of [`RwLock`] and [`Mutex`] can poll for a
14226 poisoned lock without attempting to take the lock.
14227* On Unix the [`FromRawFd`] trait is implemented for [`Stdio`], and
14228 [`AsRawFd`] for [`ChildStdin`], [`ChildStdout`], [`ChildStderr`].
14229 On Windows the `FromRawHandle` trait is implemented for `Stdio`,
14230 and `AsRawHandle` for `ChildStdin`, `ChildStdout`,
14231 `ChildStderr`.
14232* [`io::ErrorKind`] has a new variant, `InvalidData`, which indicates
14233 malformed input.
14234
14235Misc
14236----
14237
14238* `rustc` employs smarter heuristics for guessing at [typos].
14239* `rustc` emits more efficient code for [no-op conversions between
14240 unsafe pointers][nop].
14241* Fat pointers are now [passed in pairs of immediate arguments][fat],
14242 resulting in faster compile times and smaller code.
14243
14244[`Extend`]: https://doc.rust-lang.org/nightly/std/iter/trait.Extend.html
14245[extend-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0839-embrace-extend-extinguish.md
14246[`iter::once`]: https://doc.rust-lang.org/nightly/std/iter/fn.once.html
14247[`iter::empty`]: https://doc.rust-lang.org/nightly/std/iter/fn.empty.html
14248[`matches`]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.matches
14249[`rmatches`]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.rmatches
14250[`Cell`]: https://doc.rust-lang.org/nightly/std/cell/struct.Cell.html
14251[`RefCell`]: https://doc.rust-lang.org/nightly/std/cell/struct.RefCell.html
14252[`wrapping_add`]: https://doc.rust-lang.org/nightly/std/primitive.i8.html#method.wrapping_add
14253[`wrapping_sub`]: https://doc.rust-lang.org/nightly/std/primitive.i8.html#method.wrapping_sub
14254[`wrapping_mul`]: https://doc.rust-lang.org/nightly/std/primitive.i8.html#method.wrapping_mul
14255[`wrapping_div`]: https://doc.rust-lang.org/nightly/std/primitive.i8.html#method.wrapping_div
14256[`wrapping_rem`]: https://doc.rust-lang.org/nightly/std/primitive.i8.html#method.wrapping_rem
14257[`wrapping_neg`]: https://doc.rust-lang.org/nightly/std/primitive.i8.html#method.wrapping_neg
14258[`wrapping_shl`]: https://doc.rust-lang.org/nightly/std/primitive.i8.html#method.wrapping_shl
14259[`wrapping_shr`]: https://doc.rust-lang.org/nightly/std/primitive.i8.html#method.wrapping_shr
14260[`Wrapping`]: https://doc.rust-lang.org/nightly/std/num/struct.Wrapping.html
14261[`fmt::Formatter`]: https://doc.rust-lang.org/nightly/std/fmt/struct.Formatter.html
14262[`fmt::Write`]: https://doc.rust-lang.org/nightly/std/fmt/trait.Write.html
14263[`io::Write`]: https://doc.rust-lang.org/nightly/std/io/trait.Write.html
14264[`debug_struct`]: https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.debug_struct
14265[`debug_tuple`]: https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.debug_tuple
14266[`debug_list`]: https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.debug_list
14267[`debug_set`]: https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.debug_set
14268[`debug_map`]: https://doc.rust-lang.org/nightly/core/fmt/struct.Formatter.html#method.debug_map
14269[`Debug`]: https://doc.rust-lang.org/nightly/std/fmt/trait.Debug.html
14270[strup]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.to_uppercase
14271[strlow]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.to_lowercase
14272[`to_uppercase`]: https://doc.rust-lang.org/nightly/std/primitive.char.html#method.to_uppercase
14273[`to_lowercase`]: https://doc.rust-lang.org/nightly/std/primitive.char.html#method.to_lowercase
14274[`PoisonError`]: https://doc.rust-lang.org/nightly/std/sync/struct.PoisonError.html
14275[`RwLock`]: https://doc.rust-lang.org/nightly/std/sync/struct.RwLock.html
14276[`Mutex`]: https://doc.rust-lang.org/nightly/std/sync/struct.Mutex.html
14277[`FromRawFd`]: https://doc.rust-lang.org/nightly/std/os/unix/io/trait.FromRawFd.html
14278[`AsRawFd`]: https://doc.rust-lang.org/nightly/std/os/unix/io/trait.AsRawFd.html
14279[`Stdio`]: https://doc.rust-lang.org/nightly/std/process/struct.Stdio.html
14280[`ChildStdin`]: https://doc.rust-lang.org/nightly/std/process/struct.ChildStdin.html
14281[`ChildStdout`]: https://doc.rust-lang.org/nightly/std/process/struct.ChildStdout.html
14282[`ChildStderr`]: https://doc.rust-lang.org/nightly/std/process/struct.ChildStderr.html
14283[`io::ErrorKind`]: https://doc.rust-lang.org/nightly/std/io/enum.ErrorKind.html
14284[debugfmt]: https://www.reddit.com/r/rust/comments/3ceaui/psa_produces_prettyprinted_debug_output/
14285[`DerefMut`]: https://doc.rust-lang.org/nightly/std/ops/trait.DerefMut.html
14286[`mem::align_of`]: https://doc.rust-lang.org/nightly/std/mem/fn.align_of.html
14287[align]: https://github.com/rust-lang/rust/pull/25646
14288[`mem::min_align_of`]: https://doc.rust-lang.org/nightly/std/mem/fn.min_align_of.html
14289[typos]: https://github.com/rust-lang/rust/pull/26087
14290[nop]: https://github.com/rust-lang/rust/pull/26336
14291[fat]: https://github.com/rust-lang/rust/pull/26411
14292[dst]: https://github.com/rust-lang/rfcs/blob/master/text/0982-dst-coercion.md
14293[parcodegen]: https://github.com/rust-lang/rust/pull/26018
14294[packed]: https://github.com/rust-lang/rust/pull/25541
14295[ad]: https://github.com/rust-lang/rust/pull/27382
14296[win]: https://github.com/rust-lang/rust/pull/25350
14297
14298Version 1.1.0 (2015-06-25)
14299=========================
14300
14301* ~850 changes, numerous bugfixes
14302
14303Highlights
14304----------
14305
14306* The [`std::fs` module has been expanded][fs] to expand the set of
14307 functionality exposed:
14308 * `DirEntry` now supports optimizations like `file_type` and `metadata` which
14309 don't incur a syscall on some platforms.
14310 * A `symlink_metadata` function has been added.
14311 * The `fs::Metadata` structure now lowers to its OS counterpart, providing
14312 access to all underlying information.
14313* The compiler now contains extended explanations of many errors. When an error
14314 with an explanation occurs the compiler suggests using the `--explain` flag
14315 to read the explanation. Error explanations are also [available online][err-index].
14316* Thanks to multiple [improvements][sk] to [type checking][pre], as
14317 well as other work, the time to bootstrap the compiler decreased by
14318 32%.
14319
14320Libraries
14321---------
14322
14323* The [`str::split_whitespace`] method splits a string on unicode
14324 whitespace boundaries.
14325* On both Windows and Unix, new extension traits provide conversion of
14326 I/O types to and from the underlying system handles. On Unix, these
14327 traits are [`FromRawFd`] and [`AsRawFd`], on Windows `FromRawHandle`
14328 and `AsRawHandle`. These are implemented for `File`, `TcpStream`,
14329 `TcpListener`, and `UpdSocket`. Further implementations for
14330 `std::process` will be stabilized later.
14331* On Unix, [`std::os::unix::symlink`] creates symlinks. On
14332 Windows, symlinks can be created with
14333 `std::os::windows::symlink_dir` and
14334 `std::os::windows::symlink_file`.
14335* The `mpsc::Receiver` type can now be converted into an iterator with
14336 `into_iter` on the [`IntoIterator`] trait.
14337* `Ipv4Addr` can be created from `u32` with the `From<u32>`
14338 implementation of the [`From`] trait.
14339* The `Debug` implementation for `RangeFull` [creates output that is
14340 more consistent with other implementations][rf].
14341* [`Debug` is implemented for `File`][file].
14342* The `Default` implementation for `Arc` [no longer requires `Sync +
14343 Send`][arc].
14344* [The `Iterator` methods `count`, `nth`, and `last` have been
14345 overridden for slices to have *O*(1) performance instead of *O*(*n*)][si].
14346* Incorrect handling of paths on Windows has been improved in both the
14347 compiler and the standard library.
14348* [`AtomicPtr` gained a `Default` implementation][ap].
14349* In accordance with Rust's policy on arithmetic overflow `abs` now
14350 [panics on overflow when debug assertions are enabled][abs].
14351* The [`Cloned`] iterator, which was accidentally left unstable for
14352 1.0 [has been stabilized][c].
14353* The [`Incoming`] iterator, which iterates over incoming TCP
14354 connections, and which was accidentally unnamable in 1.0, [is now
14355 properly exported][inc].
14356* [`BinaryHeap`] no longer corrupts itself [when functions called by
14357 `sift_up` or `sift_down` panic][bh].
14358* The [`split_off`] method of `LinkedList` [no longer corrupts
14359 the list in certain scenarios][ll].
14360
14361Misc
14362----
14363
14364* Type checking performance [has improved notably][sk] with
14365 [multiple improvements][pre].
14366* The compiler [suggests code changes][ch] for more errors.
14367* rustc and it's build system have experimental support for [building
14368 toolchains against MUSL][m] instead of glibc on Linux.
14369* The compiler defines the `target_env` cfg value, which is used for
14370 distinguishing toolchains that are otherwise for the same
14371 platform. Presently this is set to `gnu` for common GNU Linux
14372 targets and for MinGW targets, and `musl` for MUSL Linux targets.
14373* The [`cargo rustc`][crc] command invokes a build with custom flags
14374 to rustc.
14375* [Android executables are always position independent][pie].
14376* [The `drop_with_repr_extern` lint warns about mixing `repr(C)`
14377 with `Drop`][24935].
14378
14379[`str::split_whitespace`]: https://doc.rust-lang.org/nightly/std/primitive.str.html#method.split_whitespace
14380[`FromRawFd`]: https://doc.rust-lang.org/nightly/std/os/unix/io/trait.FromRawFd.html
14381[`AsRawFd`]: https://doc.rust-lang.org/nightly/std/os/unix/io/trait.AsRawFd.html
14382[`std::os::unix::symlink`]: https://doc.rust-lang.org/nightly/std/os/unix/fs/fn.symlink.html
14383[`IntoIterator`]: https://doc.rust-lang.org/nightly/std/iter/trait.IntoIterator.html
14384[`From`]: https://doc.rust-lang.org/nightly/std/convert/trait.From.html
14385[rf]: https://github.com/rust-lang/rust/pull/24491
14386[err-index]: https://doc.rust-lang.org/error-index.html
14387[sk]: https://github.com/rust-lang/rust/pull/24615
14388[pre]: https://github.com/rust-lang/rust/pull/25323
14389[file]: https://github.com/rust-lang/rust/pull/24598
14390[ch]: https://github.com/rust-lang/rust/pull/24683
14391[arc]: https://github.com/rust-lang/rust/pull/24695
14392[si]: https://github.com/rust-lang/rust/pull/24701
14393[ap]: https://github.com/rust-lang/rust/pull/24834
14394[m]: https://github.com/rust-lang/rust/pull/24777
14395[fs]: https://github.com/rust-lang/rfcs/blob/master/text/1044-io-fs-2.1.md
14396[crc]: https://github.com/rust-lang/cargo/pull/1568
14397[pie]: https://github.com/rust-lang/rust/pull/24953
14398[abs]: https://github.com/rust-lang/rust/pull/25441
14399[c]: https://github.com/rust-lang/rust/pull/25496
14400[`Cloned`]: https://doc.rust-lang.org/nightly/std/iter/struct.Cloned.html
14401[`Incoming`]: https://doc.rust-lang.org/nightly/std/net/struct.Incoming.html
14402[inc]: https://github.com/rust-lang/rust/pull/25522
14403[bh]: https://github.com/rust-lang/rust/pull/25856
14404[`BinaryHeap`]: https://doc.rust-lang.org/nightly/std/collections/struct.BinaryHeap.html
14405[ll]: https://github.com/rust-lang/rust/pull/26022
14406[`split_off`]: https://doc.rust-lang.org/nightly/collections/linked_list/struct.LinkedList.html#method.split_off
14407[24935]: https://github.com/rust-lang/rust/pull/24935
14408
14409Version 1.0.0 (2015-05-15)
14410========================
14411
14412* ~1500 changes, numerous bugfixes
14413
14414Highlights
14415----------
14416
14417* The vast majority of the standard library is now `#[stable]`. It is
14418 no longer possible to use unstable features with a stable build of
14419 the compiler.
14420* Many popular crates on [crates.io] now work on the stable release
14421 channel.
14422* Arithmetic on basic integer types now [checks for overflow in debug
14423 builds][overflow].
14424
14425Language
14426--------
14427
14428* Several [restrictions have been added to trait coherence][coh] in
14429 order to make it easier for upstream authors to change traits
14430 without breaking downstream code.
14431* Digits of binary and octal literals are [lexed more eagerly][lex] to
14432 improve error messages and macro behavior. For example, `0b1234` is
14433 now lexed as `0b1234` instead of two tokens, `0b1` and `234`.
14434* Trait bounds [are always invariant][inv], eliminating the need for
14435 the `PhantomFn` and `MarkerTrait` lang items, which have been
14436 removed.
14437* ["-" is no longer a valid character in crate names][cr], the `extern crate
14438 "foo" as bar` syntax has been replaced with `extern crate foo as
14439 bar`, and Cargo now automatically translates "-" in *package* names
14440 to underscore for the crate name.
14441* [Lifetime shadowing is an error][lt].
14442* [`Send` no longer implies `'static`][send-rfc].
14443* [UFCS now supports trait-less associated paths][moar-ufcs] like
14444 `MyType::default()`.
14445* Primitive types [now have inherent methods][prim-inherent],
14446 obviating the need for extension traits like `SliceExt`.
14447* Methods with `Self: Sized` in their `where` clause are [considered
14448 object-safe][self-sized], allowing many extension traits like
14449 `IteratorExt` to be merged into the traits they extended.
14450* You can now [refer to associated types][assoc-where] whose
14451 corresponding trait bounds appear only in a `where` clause.
14452* The final bits of [OIBIT landed][oibit-final], meaning that traits
14453 like `Send` and `Sync` are now library-defined.
14454* A [Reflect trait][reflect] was introduced, which means that
14455 downcasting via the `Any` trait is effectively limited to concrete
14456 types. This helps retain the potentially-important "parametricity"
14457 property: generic code cannot behave differently for different type
14458 arguments except in minor ways.
14459* The `unsafe_destructor` feature is now deprecated in favor of the
14460 [new `dropck`][rfc769]. This change is a major reduction in unsafe
14461 code.
14462
14463Libraries
14464---------
14465
14466* The `thread_local` module [has been renamed to `std::thread`][th].
14467* The methods of `IteratorExt` [have been moved to the `Iterator`
14468 trait itself][23300].
14469* Several traits that implement Rust's conventions for type
14470 conversions, `AsMut`, `AsRef`, `From`, and `Into` have been
14471 [centralized in the `std::convert` module][con].
14472* The `FromError` trait [was removed in favor of `From`][fe].
14473* The basic sleep function [has moved to
14474 `std::thread::sleep_ms`][slp].
14475* The `splitn` function now takes an `n` parameter that represents the
14476 number of items yielded by the returned iterator [instead of the
14477 number of 'splits'][spl].
14478* [On Unix, all file descriptors are `CLOEXEC` by default][clo].
14479* [Derived implementations of `PartialOrd` now order enums according
14480 to their explicitly-assigned discriminants][po].
14481* [Methods for searching strings are generic over `Pattern`s][pat],
14482 implemented presently by `&char`, `&str`, `FnMut(char) -> bool` and
14483 some others.
14484* [In method resolution, object methods are resolved before inherent
14485 methods][meth].
14486* [`String::from_str` has been deprecated in favor of the `From` impl,
14487 `String::from`][24517].
14488* [`io::Error` implements `Sync`][ios].
14489* [The `words` method on `&str` has been replaced with
14490 `split_whitespace`][sw], to avoid answering the tricky question, 'what is
14491 a word?'
14492* The new path and IO modules are complete and `#[stable]`. This
14493 was the major library focus for this cycle.
14494* The path API was [revised][path-normalize] to normalize `.`,
14495 adjusting the tradeoffs in favor of the most common usage.
14496* A large number of remaining APIs in `std` were also stabilized
14497 during this cycle; about 75% of the non-deprecated API surface
14498 is now stable.
14499* The new [string pattern API][string-pattern] landed, which makes
14500 the string slice API much more internally consistent and flexible.
14501* A new set of [generic conversion traits][conversion] replaced
14502 many existing ad hoc traits.
14503* Generic numeric traits were [completely removed][num-traits]. This
14504 was made possible thanks to inherent methods for primitive types,
14505 and the removal gives maximal flexibility for designing a numeric
14506 hierarchy in the future.
14507* The `Fn` traits are now related via [inheritance][fn-inherit]
14508 and provide ergonomic [blanket implementations][fn-blanket].
14509* The `Index` and `IndexMut` traits were changed to
14510 [take the index by value][index-value], enabling code like
14511 `hash_map["string"]` to work.
14512* `Copy` now [inherits][copy-clone] from `Clone`, meaning that all
14513 `Copy` data is known to be `Clone` as well.
14514
14515Misc
14516----
14517
14518* Many errors now have extended explanations that can be accessed with
14519 the `--explain` flag to `rustc`.
14520* Many new examples have been added to the standard library
14521 documentation.
14522* rustdoc has received a number of improvements focused on completion
14523 and polish.
14524* Metadata was tuned, shrinking binaries [by 27%][metadata-shrink].
14525* Much headway was made on ecosystem-wide CI, making it possible
14526 to [compare builds for breakage][ci-compare].
14527
14528
14529[crates.io]: http://crates.io
14530[clo]: https://github.com/rust-lang/rust/pull/24034
14531[coh]: https://github.com/rust-lang/rfcs/blob/master/text/1023-rebalancing-coherence.md
14532[con]: https://github.com/rust-lang/rust/pull/23875
14533[cr]: https://github.com/rust-lang/rust/pull/23419
14534[fe]: https://github.com/rust-lang/rust/pull/23879
14535[23300]: https://github.com/rust-lang/rust/pull/23300
14536[inv]: https://github.com/rust-lang/rust/pull/23938
14537[ios]: https://github.com/rust-lang/rust/pull/24133
14538[lex]: https://github.com/rust-lang/rfcs/blob/master/text/0879-small-base-lexing.md
14539[lt]: https://github.com/rust-lang/rust/pull/24057
14540[meth]: https://github.com/rust-lang/rust/pull/24056
14541[pat]: https://github.com/rust-lang/rfcs/blob/master/text/0528-string-patterns.md
14542[po]: https://github.com/rust-lang/rust/pull/24270
14543[24517]: https://github.com/rust-lang/rust/pull/24517
14544[slp]: https://github.com/rust-lang/rust/pull/23949
14545[spl]: https://github.com/rust-lang/rfcs/blob/master/text/0979-align-splitn-with-other-languages.md
14546[sw]: https://github.com/rust-lang/rfcs/blob/master/text/1054-str-words.md
14547[th]: https://github.com/rust-lang/rfcs/blob/master/text/0909-move-thread-local-to-std-thread.md
14548[send-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0458-send-improvements.md
14549[moar-ufcs]: https://github.com/rust-lang/rust/pull/22172
14550[prim-inherent]: https://github.com/rust-lang/rust/pull/23104
14551[overflow]: https://github.com/rust-lang/rfcs/blob/master/text/0560-integer-overflow.md
14552[metadata-shrink]: https://github.com/rust-lang/rust/pull/22971
14553[self-sized]: https://github.com/rust-lang/rust/pull/22301
14554[assoc-where]: https://github.com/rust-lang/rust/pull/22512
14555[string-pattern]: https://github.com/rust-lang/rust/pull/22466
14556[oibit-final]: https://github.com/rust-lang/rust/pull/21689
14557[reflect]: https://github.com/rust-lang/rust/pull/23712
14558[conversion]: https://github.com/rust-lang/rfcs/pull/529
14559[num-traits]: https://github.com/rust-lang/rust/pull/23549
14560[index-value]: https://github.com/rust-lang/rust/pull/23601
14561[rfc769]: https://github.com/rust-lang/rfcs/pull/769
14562[ci-compare]: https://gist.github.com/brson/a30a77836fbec057cbee
14563[fn-inherit]: https://github.com/rust-lang/rust/pull/23282
14564[fn-blanket]: https://github.com/rust-lang/rust/pull/23895
14565[copy-clone]: https://github.com/rust-lang/rust/pull/23860
14566[path-normalize]: https://github.com/rust-lang/rust/pull/23229
14567
14568
14569Version 1.0.0-alpha.2 (2015-02-20)
14570=====================================
14571
14572* ~1300 changes, numerous bugfixes
14573
14574* Highlights
14575
14576 * The various I/O modules were [overhauled][io-rfc] to reduce
14577 unnecessary abstractions and provide better interoperation with
14578 the underlying platform. The old `io` module remains temporarily
14579 at `std::old_io`.
14580 * The standard library now [participates in feature gating][feat],
14581 so use of unstable libraries now requires a `#![feature(...)]`
14582 attribute. The impact of this change is [described on the
14583 forum][feat-forum]. [RFC][feat-rfc].
14584
14585* Language
14586
14587 * `for` loops [now operate on the `IntoIterator` trait][into],
14588 which eliminates the need to call `.iter()`, etc. to iterate
14589 over collections. There are some new subtleties to remember
14590 though regarding what sort of iterators various types yield, in
14591 particular that `for foo in bar { }` yields values from a move
14592 iterator, destroying the original collection. [RFC][into-rfc].
14593 * Objects now have [default lifetime bounds][obj], so you don't
14594 have to write `Box<Trait+'static>` when you don't care about
14595 storing references. [RFC][obj-rfc].
14596 * In types that implement `Drop`, [lifetimes must outlive the
14597 value][drop]. This will soon make it possible to safely
14598 implement `Drop` for types where `#[unsafe_destructor]` is now
14599 required. Read the [gorgeous RFC][drop-rfc] for details.
14600 * The fully qualified <T as Trait>::X syntax lets you set the Self
14601 type for a trait method or associated type. [RFC][ufcs-rfc].
14602 * References to types that implement `Deref<U>` now [automatically
14603 coerce to references][deref] to the dereferenced type `U`,
14604 e.g. `&T where T: Deref<U>` automatically coerces to `&U`. This
14605 should eliminate many unsightly uses of `&*`, as when converting
14606 from references to vectors into references to
14607 slices. [RFC][deref-rfc].
14608 * The explicit [closure kind syntax][close] (`|&:|`, `|&mut:|`,
14609 `|:|`) is obsolete and closure kind is inferred from context.
14610 * [`Self` is a keyword][Self].
14611
14612* Libraries
14613
14614 * The `Show` and `String` formatting traits [have been
14615 renamed][fmt] to `Debug` and `Display` to more clearly reflect
14616 their related purposes. Automatically getting a string
14617 conversion to use with `format!("{:?}", something_to_debug)` is
14618 now written `#[derive(Debug)]`.
14619 * Abstract [OS-specific string types][osstr], `std::ff::{OsString,
14620 OsStr}`, provide strings in platform-specific encodings for easier
14621 interop with system APIs. [RFC][osstr-rfc].
14622 * The `boxed::into_raw` and `Box::from_raw` functions [convert
14623 between `Box<T>` and `*mut T`][boxraw], a common pattern for
14624 creating raw pointers.
14625
14626* Tooling
14627
14628 * Certain long error messages of the form 'expected foo found bar'
14629 are now [split neatly across multiple
14630 lines][multiline]. Examples in the PR.
14631 * On Unix Rust can be [uninstalled][un] by running
14632 `/usr/local/lib/rustlib/uninstall.sh`.
14633 * The `#[rustc_on_unimplemented]` attribute, requiring the
14634 'on_unimplemented' feature, lets rustc [display custom error
14635 messages when a trait is expected to be implemented for a type
14636 but is not][onun].
14637
14638* Misc
14639
14640 * Rust is tested against a [LALR grammar][lalr], which parses
14641 almost all the Rust files that rustc does.
14642
14643[boxraw]: https://github.com/rust-lang/rust/pull/21318
14644[close]: https://github.com/rust-lang/rust/pull/21843
14645[deref]: https://github.com/rust-lang/rust/pull/21351
14646[deref-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0241-deref-conversions.md
14647[drop]: https://github.com/rust-lang/rust/pull/21972
14648[drop-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0769-sound-generic-drop.md
14649[feat]: https://github.com/rust-lang/rust/pull/21248
14650[feat-forum]: https://users.rust-lang.org/t/psa-important-info-about-rustcs-new-feature-staging/82/5
14651[feat-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0507-release-channels.md
14652[fmt]: https://github.com/rust-lang/rust/pull/21457
14653[into]: https://github.com/rust-lang/rust/pull/20790
14654[into-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0235-collections-conventions.md#intoiterator-and-iterable
14655[io-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0517-io-os-reform.md
14656[lalr]: https://github.com/rust-lang/rust/pull/21452
14657[multiline]: https://github.com/rust-lang/rust/pull/19870
14658[obj]: https://github.com/rust-lang/rust/pull/22230
14659[obj-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0599-default-object-bound.md
14660[onun]: https://github.com/rust-lang/rust/pull/20889
14661[osstr]: https://github.com/rust-lang/rust/pull/21488
14662[osstr-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0517-io-os-reform.md
14663[Self]: https://github.com/rust-lang/rust/pull/22158
14664[ufcs-rfc]: https://github.com/rust-lang/rfcs/blob/master/text/0132-ufcs.md
14665[un]: https://github.com/rust-lang/rust/pull/22256
14666
14667
14668Version 1.0.0-alpha (2015-01-09)
14669==================================
14670
14671 * ~2400 changes, numerous bugfixes
14672
14673 * Highlights
14674
14675 * The language itself is considered feature complete for 1.0,
14676 though there will be many usability improvements and bugfixes
14677 before the final release.
14678 * Nearly 50% of the public API surface of the standard library has
14679 been declared 'stable'. Those interfaces are unlikely to change
14680 before 1.0.
14681 * The long-running debate over integer types has been
14682 [settled][ints]: Rust will ship with types named `isize` and
14683 `usize`, rather than `int` and `uint`, for pointer-sized
14684 integers. Guidelines will be rolled out during the alpha cycle.
14685 * Most crates that are not `std` have been moved out of the Rust
14686 distribution into the Cargo ecosystem so they can evolve
14687 separately and don't need to be stabilized as quickly, including
14688 'time', 'getopts', 'num', 'regex', and 'term'.
14689 * Documentation continues to be expanded with more API coverage, more
14690 examples, and more in-depth explanations. The guides have been
14691 consolidated into [The Rust Programming Language][trpl].
14692 * "[Rust By Example][rbe]" is now maintained by the Rust team.
14693 * All official Rust binary installers now come with [Cargo], the
14694 Rust package manager.
14695
14696* Language
14697
14698 * Closures have been [completely redesigned][unboxed] to be
14699 implemented in terms of traits, can now be used as generic type
14700 bounds and thus monomorphized and inlined, or via an opaque
14701 pointer (boxed) as in the old system. The new system is often
14702 referred to as 'unboxed' closures.
14703 * Traits now support [associated types][assoc], allowing families
14704 of related types to be defined together and used generically in
14705 powerful ways.
14706 * Enum variants are [namespaced by their type names][enum].
14707 * [`where` clauses][where] provide a more versatile and attractive
14708 syntax for specifying generic bounds, though the previous syntax
14709 remains valid.
14710 * Rust again picks a [fallback][fb] (either i32 or f64) for uninferred
14711 numeric types.
14712 * Rust [no longer has a runtime][rt] of any description, and only
14713 supports OS threads, not green threads.
14714 * At long last, Rust has been overhauled for 'dynamically-sized
14715 types' ([DST]), which integrates 'fat pointers' (object types,
14716 arrays, and `str`) more deeply into the type system, making it
14717 more consistent.
14718 * Rust now has a general [range syntax][range], `i..j`, `i..`, and
14719 `..j` that produce range types and which, when combined with the
14720 `Index` operator and multidispatch, leads to a convenient slice
14721 notation, `[i..j]`.
14722 * The new range syntax revealed an ambiguity in the fixed-length
14723 array syntax, so now fixed length arrays [are written `[T;
14724 N]`][arrays].
14725 * The `Copy` trait is no longer implemented automatically. Unsafe
14726 pointers no longer implement `Sync` and `Send` so types
14727 containing them don't automatically either. `Sync` and `Send`
14728 are now 'unsafe traits' so one can "forcibly" implement them via
14729 `unsafe impl` if a type confirms to the requirements for them
14730 even though the internals do not (e.g. structs containing unsafe
14731 pointers like `Arc`). These changes are intended to prevent some
14732 footguns and are collectively known as [opt-in built-in
14733 traits][oibit] (though `Sync` and `Send` will soon become pure
14734 library types unknown to the compiler).
14735 * Operator traits now take their operands [by value][ops], and
14736 comparison traits can use multidispatch to compare one type
14737 against multiple other types, allowing e.g. `String` to be
14738 compared with `&str`.
14739 * `if let` and `while let` are no longer feature-gated.
14740 * Rust has adopted a more [uniform syntax for escaping unicode
14741 characters][unicode].
14742 * `macro_rules!` [has been declared stable][mac]. Though it is a
14743 flawed system it is sufficiently popular that it must be usable
14744 for 1.0. Effort has gone into [future-proofing][mac-future] it
14745 in ways that will allow other macro systems to be developed in
14746 parallel, and won't otherwise impact the evolution of the
14747 language.
14748 * The prelude has been [pared back significantly][prelude] such
14749 that it is the minimum necessary to support the most pervasive
14750 code patterns, and through [generalized where clauses][where]
14751 many of the prelude extension traits have been consolidated.
14752 * Rust's rudimentary reflection [has been removed][refl], as it
14753 incurred too much code generation for little benefit.
14754 * [Struct variants][structvars] are no longer feature-gated.
14755 * Trait bounds can be [polymorphic over lifetimes][hrtb]. Also
14756 known as 'higher-ranked trait bounds', this crucially allows
14757 unboxed closures to work.
14758 * Macros invocations surrounded by parens or square brackets and
14759 not terminated by a semicolon are [parsed as
14760 expressions][macros], which makes expressions like `vec![1i32,
14761 2, 3].len()` work as expected.
14762 * Trait objects now implement their traits automatically, and
14763 traits that can be coerced to objects now must be [object
14764 safe][objsafe].
14765 * Automatically deriving traits is now done with `#[derive(...)]`
14766 not `#[deriving(...)]` for [consistency with other naming
14767 conventions][derive].
14768 * Importing the containing module or enum at the same time as
14769 items or variants they contain is [now done with `self` instead
14770 of `mod`][self], as in use `foo::{self, bar}`
14771 * Glob imports are no longer feature-gated.
14772 * The `box` operator and `box` patterns have been feature-gated
14773 pending a redesign. For now unique boxes should be allocated
14774 like other containers, with `Box::new`.
14775
14776* Libraries
14777
14778 * A [series][coll1] of [efforts][coll2] to establish
14779 [conventions][coll3] for collections types has resulted in API
14780 improvements throughout the standard library.
14781 * New [APIs for error handling][err] provide ergonomic interop
14782 between error types, and [new conventions][err-conv] describe
14783 more clearly the recommended error handling strategies in Rust.
14784 * The `fail!` macro has been renamed to [`panic!`][panic] so that
14785 it is easier to discuss failure in the context of error handling
14786 without making clarifications as to whether you are referring to
14787 the 'fail' macro or failure more generally.
14788 * On Linux, `OsRng` prefers the new, more reliable `getrandom`
14789 syscall when available.
14790 * The 'serialize' crate has been renamed 'rustc-serialize' and
14791 moved out of the distribution to Cargo. Although it is widely
14792 used now, it is expected to be superseded in the near future.
14793 * The `Show` formatter, typically implemented with
14794 `#[derive(Show)]` is [now requested with the `{:?}`
14795 specifier][show] and is intended for use by all types, for uses
14796 such as `println!` debugging. The new `String` formatter must be
14797 implemented by hand, uses the `{}` specifier, and is intended
14798 for full-fidelity conversions of things that can logically be
14799 represented as strings.
14800
14801* Tooling
14802
14803 * [Flexible target specification][flex] allows rustc's code
14804 generation to be configured to support otherwise-unsupported
14805 platforms.
14806 * Rust comes with rust-gdb and rust-lldb scripts that launch their
14807 respective debuggers with Rust-appropriate pretty-printing.
14808 * The Windows installation of Rust is distributed with the
14809 MinGW components currently required to link binaries on that
14810 platform.
14811
14812* Misc
14813
14814 * Nullable enum optimizations have been extended to more types so
14815 that e.g. `Option<Vec<T>>` and `Option<String>` take up no more
14816 space than the inner types themselves.
14817 * Work has begun on supporting AArch64.
14818
14819[Cargo]: https://crates.io
14820[unboxed]: http://smallcultfollowing.com/babysteps/blog/2014/11/26/purging-proc/
14821[enum]: https://github.com/rust-lang/rfcs/blob/master/text/0390-enum-namespacing.md
14822[flex]: https://github.com/rust-lang/rfcs/blob/master/text/0131-target-specification.md
14823[err]: https://github.com/rust-lang/rfcs/blob/master/text/0201-error-chaining.md
14824[err-conv]: https://github.com/rust-lang/rfcs/blob/master/text/0236-error-conventions.md
14825[rt]: https://github.com/rust-lang/rfcs/blob/master/text/0230-remove-runtime.md
14826[mac]: https://github.com/rust-lang/rfcs/blob/master/text/0453-macro-reform.md
14827[mac-future]: https://github.com/rust-lang/rfcs/pull/550
14828[DST]: http://smallcultfollowing.com/babysteps/blog/2014/01/05/dst-take-5/
14829[coll1]: https://github.com/rust-lang/rfcs/blob/master/text/0235-collections-conventions.md
14830[coll2]: https://github.com/rust-lang/rfcs/blob/master/text/0509-collections-reform-part-2.md
14831[coll3]: https://github.com/rust-lang/rfcs/blob/master/text/0216-collection-views.md
14832[ops]: https://github.com/rust-lang/rfcs/blob/master/text/0439-cmp-ops-reform.md
14833[prelude]: https://github.com/rust-lang/rfcs/blob/master/text/0503-prelude-stabilization.md
14834[where]: https://github.com/rust-lang/rfcs/blob/master/text/0135-where.md
14835[refl]: https://github.com/rust-lang/rfcs/blob/master/text/0379-remove-reflection.md
14836[panic]: https://github.com/rust-lang/rfcs/blob/master/text/0221-panic.md
14837[structvars]: https://github.com/rust-lang/rfcs/blob/master/text/0418-struct-variants.md
14838[hrtb]: https://github.com/rust-lang/rfcs/blob/master/text/0387-higher-ranked-trait-bounds.md
14839[unicode]: https://github.com/rust-lang/rfcs/blob/master/text/0446-es6-unicode-escapes.md
14840[oibit]: https://github.com/rust-lang/rfcs/blob/master/text/0019-opt-in-builtin-traits.md
14841[macros]: https://github.com/rust-lang/rfcs/blob/master/text/0378-expr-macros.md
14842[range]: https://github.com/rust-lang/rfcs/blob/master/text/0439-cmp-ops-reform.md#indexing-and-slicing
14843[arrays]: https://github.com/rust-lang/rfcs/blob/master/text/0520-new-array-repeat-syntax.md
14844[show]: https://github.com/rust-lang/rfcs/blob/master/text/0504-show-stabilization.md
14845[derive]: https://github.com/rust-lang/rfcs/blob/master/text/0534-deriving2derive.md
14846[self]: https://github.com/rust-lang/rfcs/blob/master/text/0532-self-in-use.md
14847[fb]: https://github.com/rust-lang/rfcs/blob/master/text/0212-restore-int-fallback.md
14848[objsafe]: https://github.com/rust-lang/rfcs/blob/master/text/0255-object-safety.md
14849[assoc]: https://github.com/rust-lang/rfcs/blob/master/text/0195-associated-items.md
14850[ints]: https://github.com/rust-lang/rfcs/pull/544#issuecomment-68760871
14851[trpl]: https://doc.rust-lang.org/book/index.html
14852[rbe]: http://rustbyexample.com/
14853
14854
14855Version 0.12.0 (2014-10-09)
14856=============================
14857
14858 * ~1900 changes, numerous bugfixes
14859
14860 * Highlights
14861
14862 * The introductory documentation (now called The Rust Guide) has
14863 been completely rewritten, as have a number of supplementary
14864 guides.
14865 * Rust's package manager, Cargo, continues to improve and is
14866 sometimes considered to be quite awesome.
14867 * Many API's in `std` have been reviewed and updated for
14868 consistency with the in-development Rust coding
14869 guidelines. The standard library documentation tracks
14870 stabilization progress.
14871 * Minor libraries have been moved out-of-tree to the rust-lang org
14872 on GitHub: uuid, semver, glob, num, hexfloat, fourcc. They can
14873 be installed with Cargo.
14874 * Lifetime elision allows lifetime annotations to be left off of
14875 function declarations in many common scenarios.
14876 * Rust now works on 64-bit Windows.
14877
14878 * Language
14879 * Indexing can be overloaded with the `Index` and `IndexMut`
14880 traits.
14881 * The `if let` construct takes a branch only if the `let` pattern
14882 matches, currently behind the 'if_let' feature gate.
14883 * 'where clauses', a more flexible syntax for specifying trait
14884 bounds that is more aesthetic, have been added for traits and
14885 free functions. Where clauses will in the future make it
14886 possible to constrain associated types, which would be
14887 impossible with the existing syntax.
14888 * A new slicing syntax (e.g. `[0..4]`) has been introduced behind
14889 the 'slicing_syntax' feature gate, and can be overloaded with
14890 the `Slice` or `SliceMut` traits.
14891 * The syntax for matching of sub-slices has been changed to use a
14892 postfix `..` instead of prefix (.e.g. `[a, b, c..]`), for
14893 consistency with other uses of `..` and to future-proof
14894 potential additional uses of the syntax.
14895 * The syntax for matching inclusive ranges in patterns has changed
14896 from `0..3` to `0...4` to be consistent with the exclusive range
14897 syntax for slicing.
14898 * Matching of sub-slices in non-tail positions (e.g. `[a.., b,
14899 c]`) has been put behind the 'advanced_slice_patterns' feature
14900 gate and may be removed in the future.
14901 * Components of tuples and tuple structs can be extracted using
14902 the `value.0` syntax, currently behind the `tuple_indexing`
14903 feature gate.
14904 * The `#[crate_id]` attribute is no longer supported; versioning
14905 is handled by the package manager.
14906 * Renaming crate imports are now written `extern crate foo as bar`
14907 instead of `extern crate bar = foo`.
14908 * Renaming use statements are now written `use foo as bar` instead
14909 of `use bar = foo`.
14910 * `let` and `match` bindings and argument names in macros are now
14911 hygienic.
14912 * The new, more efficient, closure types ('unboxed closures') have
14913 been added under a feature gate, 'unboxed_closures'. These will
14914 soon replace the existing closure types, once higher-ranked
14915 trait lifetimes are added to the language.
14916 * `move` has been added as a keyword, for indicating closures
14917 that capture by value.
14918 * Mutation and assignment is no longer allowed in pattern guards.
14919 * Generic structs and enums can now have trait bounds.
14920 * The `Share` trait is now called `Sync` to free up the term
14921 'shared' to refer to 'shared reference' (the default reference
14922 type.
14923 * Dynamically-sized types have been mostly implemented,
14924 unifying the behavior of fat-pointer types with the rest of the
14925 type system.
14926 * As part of dynamically-sized types, the `Sized` trait has been
14927 introduced, which qualifying types implement by default, and
14928 which type parameters expect by default. To specify that a type
14929 parameter does not need to be sized, write `<Sized? T>`. Most
14930 types are `Sized`, notable exceptions being unsized arrays
14931 (`[T]`) and trait types.
14932 * Closures can return `!`, as in `|| -> !` or `proc() -> !`.
14933 * Lifetime bounds can now be applied to type parameters and object
14934 types.
14935 * The old, reference counted GC type, `Gc<T>` which was once
14936 denoted by the `@` sigil, has finally been removed. GC will be
14937 revisited in the future.
14938
14939 * Libraries
14940 * Library documentation has been improved for a number of modules.
14941 * Bit-vectors, collections::bitv has been modernized.
14942 * The url crate is deprecated in favor of
14943 http://github.com/servo/rust-url, which can be installed with
14944 Cargo.
14945 * Most I/O stream types can be cloned and subsequently closed from
14946 a different thread.
14947 * A `std::time::Duration` type has been added for use in I/O
14948 methods that rely on timers, as well as in the 'time' crate's
14949 `Timespec` arithmetic.
14950 * The runtime I/O abstraction layer that enabled the green thread
14951 scheduler to do non-thread-blocking I/O has been removed, along
14952 with the libuv-based implementation employed by the green thread
14953 scheduler. This will greatly simplify the future I/O work.
14954 * `collections::btree` has been rewritten to have a more
14955 idiomatic and efficient design.
14956
14957 * Tooling
14958 * rustdoc output now indicates the stability levels of API's.
14959 * The `--crate-name` flag can specify the name of the crate
14960 being compiled, like `#[crate_name]`.
14961 * The `-C metadata` specifies additional metadata to hash into
14962 symbol names, and `-C extra-filename` specifies additional
14963 information to put into the output filename, for use by the
14964 package manager for versioning.
14965 * debug info generation has continued to improve and should be
14966 more reliable under both gdb and lldb.
14967 * rustc has experimental support for compiling in parallel
14968 using the `-C codegen-units` flag.
14969 * rustc no longer encodes rpath information into binaries by
14970 default.
14971
14972 * Misc
14973 * Stack usage has been optimized with LLVM lifetime annotations.
14974 * Official Rust binaries on Linux are more compatible with older
14975 kernels and distributions, built on CentOS 5.10.
14976
14977
14978Version 0.11.0 (2014-07-02)
14979==========================
14980
14981 * ~1700 changes, numerous bugfixes
14982
14983 * Language
14984 * ~[T] has been removed from the language. This type is superseded by
14985 the Vec<T> type.
14986 * ~str has been removed from the language. This type is superseded by
14987 the String type.
14988 * ~T has been removed from the language. This type is superseded by the
14989 Box<T> type.
14990 * @T has been removed from the language. This type is superseded by the
14991 standard library's std::gc::Gc<T> type.
14992 * Struct fields are now all private by default.
14993 * Vector indices and shift amounts are both required to be a `uint`
14994 instead of any integral type.
14995 * Byte character, byte string, and raw byte string literals are now all
14996 supported by prefixing the normal literal with a `b`.
14997 * Multiple ABIs are no longer allowed in an ABI string
14998 * The syntax for lifetimes on closures/procedures has been tweaked
14999 slightly: `<'a>|A, B|: 'b + K -> T`
15000 * Floating point modulus has been removed from the language; however it
15001 is still provided by a library implementation.
15002 * Private enum variants are now disallowed.
15003 * The `priv` keyword has been removed from the language.
15004 * A closure can no longer be invoked through a &-pointer.
15005 * The `use foo, bar, baz;` syntax has been removed from the language.
15006 * The transmute intrinsic no longer works on type parameters.
15007 * Statics now allow blocks/items in their definition.
15008 * Trait bounds are separated from objects with + instead of : now.
15009 * Objects can no longer be read while they are mutably borrowed.
15010 * The address of a static is now marked as insignificant unless the
15011 #[inline(never)] attribute is placed it.
15012 * The #[unsafe_destructor] attribute is now behind a feature gate.
15013 * Struct literals are no longer allowed in ambiguous positions such as
15014 if, while, match, and for..in.
15015 * Declaration of lang items and intrinsics are now feature-gated by
15016 default.
15017 * Integral literals no longer default to `int`, and floating point
15018 literals no longer default to `f64`. Literals must be suffixed with an
15019 appropriate type if inference cannot determine the type of the
15020 literal.
15021 * The Box<T> type is no longer implicitly borrowed to &mut T.
15022 * Procedures are now required to not capture borrowed references.
15023
15024 * Libraries
15025 * The standard library is now a "facade" over a number of underlying
15026 libraries. This means that development on the standard library should
15027 be speedier due to smaller crates, as well as a clearer line between
15028 all dependencies.
15029 * A new library, libcore, lives under the standard library's facade
15030 which is Rust's "0-assumption" library, suitable for embedded and
15031 kernel development for example.
15032 * A regex crate has been added to the standard distribution. This crate
15033 includes statically compiled regular expressions.
15034 * The unwrap/unwrap_err methods on Result require a Show bound for
15035 better error messages.
15036 * The return types of the std::comm primitives have been centralized
15037 around the Result type.
15038 * A number of I/O primitives have gained the ability to time out their
15039 operations.
15040 * A number of I/O primitives have gained the ability to close their
15041 reading/writing halves to cancel pending operations.
15042 * Reverse iterator methods have been removed in favor of `rev()` on
15043 their forward-iteration counterparts.
15044 * A bitflags! macro has been added to enable easy interop with C and
15045 management of bit flags.
15046 * A debug_assert! macro is now provided which is disabled when
15047 `--cfg ndebug` is passed to the compiler.
15048 * A graphviz crate has been added for creating .dot files.
15049 * The std::cast module has been migrated into std::mem.
15050 * The std::local_data api has been migrated from freestanding functions
15051 to being based on methods.
15052 * The Pod trait has been renamed to Copy.
15053 * jemalloc has been added as the default allocator for types.
15054 * The API for allocating memory has been changed to use proper alignment
15055 and sized deallocation
15056 * Connecting a TcpStream or binding a TcpListener is now based on a
15057 string address and a u16 port. This allows connecting to a hostname as
15058 opposed to an IP.
15059 * The Reader trait now contains a core method, read_at_least(), which
15060 correctly handles many repeated 0-length reads.
15061 * The process-spawning API is now centered around a builder-style
15062 Command struct.
15063 * The :? printing qualifier has been moved from the standard library to
15064 an external libdebug crate.
15065 * Eq/Ord have been renamed to PartialEq/PartialOrd. TotalEq/TotalOrd
15066 have been renamed to Eq/Ord.
15067 * The select/plural methods have been removed from format!. The escapes
15068 for { and } have also changed from \{ and \} to {{ and }},
15069 respectively.
15070 * The TaskBuilder API has been re-worked to be a true builder, and
15071 extension traits for spawning native/green tasks have been added.
15072
15073 * Tooling
15074 * All breaking changes to the language or libraries now have their
15075 commit message annotated with `[breaking-change]` to allow for easy
15076 discovery of breaking changes.
15077 * The compiler will now try to suggest how to annotate lifetimes if a
15078 lifetime-related error occurs.
15079 * Debug info continues to be improved greatly with general bug fixes and
15080 better support for situations like link time optimization (LTO).
15081 * Usage of syntax extensions when cross-compiling has been fixed.
15082 * Functionality equivalent to GCC & Clang's -ffunction-sections,
15083 -fdata-sections and --gc-sections has been enabled by default
15084 * The compiler is now stricter about where it will load module files
15085 from when a module is declared via `mod foo;`.
15086 * The #[phase(syntax)] attribute has been renamed to #[phase(plugin)].
15087 Syntax extensions are now discovered via a "plugin registrar" type
15088 which will be extended in the future to other various plugins.
15089 * Lints have been restructured to allow for dynamically loadable lints.
15090 * A number of rustdoc improvements:
15091 * The HTML output has been visually redesigned.
15092 * Markdown is now powered by hoedown instead of sundown.
15093 * Searching heuristics have been greatly improved.
15094 * The search index has been reduced in size by a great amount.
15095 * Cross-crate documentation via `pub use` has been greatly improved.
15096 * Primitive types are now hyperlinked and documented.
15097 * Documentation has been moved from static.rust-lang.org/doc to
15098 doc.rust-lang.org
15099 * A new sandbox, play.rust-lang.org, is available for running and
15100 sharing rust code examples on-line.
15101 * Unused attributes are now more robustly warned about.
15102 * The dead_code lint now warns about unused struct fields.
15103 * Cross-compiling to iOS is now supported.
15104 * Cross-compiling to mipsel is now supported.
15105 * Stability attributes are now inherited by default and no longer apply
15106 to intra-crate usage, only inter-crate usage.
15107 * Error message related to non-exhaustive match expressions have been
15108 greatly improved.
15109
15110
15111Version 0.10 (2014-04-03)
15112=========================
15113
15114 * ~1500 changes, numerous bugfixes
15115
15116 * Language
15117 * A new RFC process is now in place for modifying the language.
15118 * Patterns with `@`-pointers have been removed from the language.
15119 * Patterns with unique vectors (`~[T]`) have been removed from the
15120 language.
15121 * Patterns with unique strings (`~str`) have been removed from the
15122 language.
15123 * `@str` has been removed from the language.
15124 * `@[T]` has been removed from the language.
15125 * `@self` has been removed from the language.
15126 * `@Trait` has been removed from the language.
15127 * Headers on `~` allocations which contain `@` boxes inside the type for
15128 reference counting have been removed.
15129 * The semantics around the lifetimes of temporary expressions have changed,
15130 see #3511 and #11585 for more information.
15131 * Cross-crate syntax extensions are now possible, but feature gated. See
15132 #11151 for more information. This includes both `macro_rules!` macros as
15133 well as syntax extensions such as `format!`.
15134 * New lint modes have been added, and older ones have been turned on to be
15135 warn-by-default.
15136 * Unnecessary parentheses
15137 * Uppercase statics
15138 * Camel Case types
15139 * Uppercase variables
15140 * Publicly visible private types
15141 * `#[deriving]` with raw pointers
15142 * Unsafe functions can no longer be coerced to closures.
15143 * Various obscure macros such as `log_syntax!` are now behind feature gates.
15144 * The `#[simd]` attribute is now behind a feature gate.
15145 * Visibility is no longer allowed on `extern crate` statements, and
15146 unnecessary visibility (`priv`) is no longer allowed on `use` statements.
15147 * Trailing commas are now allowed in argument lists and tuple patterns.
15148 * The `do` keyword has been removed, it is now a reserved keyword.
15149 * Default type parameters have been implemented, but are feature gated.
15150 * Borrowed variables through captures in closures are now considered soundly.
15151 * `extern mod` is now `extern crate`
15152 * The `Freeze` trait has been removed.
15153 * The `Share` trait has been added for types that can be shared among
15154 threads.
15155 * Labels in macros are now hygienic.
15156 * Expression/statement macro invocations can be delimited with `{}` now.
15157 * Treatment of types allowed in `static mut` locations has been tweaked.
15158 * The `*` and `.` operators are now overloadable through the `Deref` and
15159 `DerefMut` traits.
15160 * `~Trait` and `proc` no longer have `Send` bounds by default.
15161 * Partial type hints are now supported with the `_` type marker.
15162 * An `Unsafe` type was introduced for interior mutability. It is now
15163 considered undefined to transmute from `&T` to `&mut T` without using the
15164 `Unsafe` type.
15165 * The #[linkage] attribute was implemented for extern statics/functions.
15166 * The inner attribute syntax has changed from `#[foo];` to `#![foo]`.
15167 * `Pod` was renamed to `Copy`.
15168
15169 * Libraries
15170 * The `libextra` library has been removed. It has now been decomposed into
15171 component libraries with smaller and more focused nuggets of
15172 functionality. The full list of libraries can be found on the
15173 documentation index page.
15174 * std: `std::condition` has been removed. All I/O errors are now propagated
15175 through the `Result` type. In order to assist with error handling, a
15176 `try!` macro for unwrapping errors with an early return and a lint for
15177 unused results has been added. See #12039 for more information.
15178 * std: The `vec` module has been renamed to `slice`.
15179 * std: A new vector type, `Vec<T>`, has been added in preparation for DST.
15180 This will become the only growable vector in the future.
15181 * std: `std::io` now has more public re-exports. Types such as `BufferedReader`
15182 are now found at `std::io::BufferedReader` instead of
15183 `std::io::buffered::BufferedReader`.
15184 * std: `print` and `println` are no longer in the prelude, the `print!` and
15185 `println!` macros are intended to be used instead.
15186 * std: `Rc` now has a `Weak` pointer for breaking cycles, and it no longer
15187 attempts to statically prevent cycles.
15188 * std: The standard distribution is adopting the policy of pushing failure
15189 to the user rather than failing in libraries. Many functions (such as
15190 `slice::last()`) now return `Option<T>` instead of `T` + failing.
15191 * std: `fmt::Default` has been renamed to `fmt::Show`, and it now has a new
15192 deriving mode: `#[deriving(Show)]`.
15193 * std: `ToStr` is now implemented for all types implementing `Show`.
15194 * std: The formatting trait methods now take `&self` instead of `&T`
15195 * std: The `invert()` method on iterators has been renamed to `rev()`
15196 * std: `std::num` has seen a reduction in the genericity of its traits,
15197 consolidating functionality into a few core traits.
15198 * std: Backtraces are now printed on task failure if the environment
15199 variable `RUST_BACKTRACE` is present.
15200 * std: Naming conventions for iterators have been standardized. More details
15201 can be found on the wiki's style guide.
15202 * std: `eof()` has been removed from the `Reader` trait. Specific types may
15203 still implement the function.
15204 * std: Networking types are now cloneable to allow simultaneous reads/writes.
15205 * std: `assert_approx_eq!` has been removed
15206 * std: The `e` and `E` formatting specifiers for floats have been added to
15207 print them in exponential notation.
15208 * std: The `Times` trait has been removed
15209 * std: Indications of variance and opting out of builtin bounds is done
15210 through marker types in `std::kinds::marker` now
15211 * std: `hash` has been rewritten, `IterBytes` has been removed, and
15212 `#[deriving(Hash)]` is now possible.
15213 * std: `SharedChan` has been removed, `Sender` is now cloneable.
15214 * std: `Chan` and `Port` were renamed to `Sender` and `Receiver`.
15215 * std: `Chan::new` is now `channel()`.
15216 * std: A new synchronous channel type has been implemented.
15217 * std: A `select!` macro is now provided for selecting over `Receiver`s.
15218 * std: `hashmap` and `trie` have been moved to `libcollections`
15219 * std: `run` has been rolled into `io::process`
15220 * std: `assert_eq!` now uses `{}` instead of `{:?}`
15221 * std: The equality and comparison traits have seen some reorganization.
15222 * std: `rand` has moved to `librand`.
15223 * std: `to_{lower,upper}case` has been implemented for `char`.
15224 * std: Logging has been moved to `liblog`.
15225 * collections: `HashMap` has been rewritten for higher performance and less
15226 memory usage.
15227 * native: The default runtime is now `libnative`. If `libgreen` is desired,
15228 it can be booted manually. The runtime guide has more information and
15229 examples.
15230 * native: All I/O functionality except signals has been implemented.
15231 * green: Task spawning with `libgreen` has been optimized with stack caching
15232 and various trimming of code.
15233 * green: Tasks spawned by `libgreen` now have an unmapped guard page.
15234 * sync: The `extra::sync` module has been updated to modern rust (and moved
15235 to the `sync` library), tweaking and improving various interfaces while
15236 dropping redundant functionality.
15237 * sync: A new `Barrier` type has been added to the `sync` library.
15238 * sync: An efficient mutex for native and green tasks has been implemented.
15239 * serialize: The `base64` module has seen some improvement. It treats
15240 newlines better, has non-string error values, and has seen general
15241 cleanup.
15242 * fourcc: A `fourcc!` macro was introduced
15243 * hexfloat: A `hexfloat!` macro was implemented for specifying floats via a
15244 hexadecimal literal.
15245
15246 * Tooling
15247 * `rustpkg` has been deprecated and removed from the main repository. Its
15248 replacement, `cargo`, is under development.
15249 * Nightly builds of rust are now available
15250 * The memory usage of rustc has been improved many times throughout this
15251 release cycle.
15252 * The build process supports disabling rpath support for the rustc binary
15253 itself.
15254 * Code generation has improved in some cases, giving more information to the
15255 LLVM optimization passes to enable more extensive optimizations.
15256 * Debuginfo compatibility with lldb on OSX has been restored.
15257 * The master branch is now gated on an android bot, making building for
15258 android much more reliable.
15259 * Output flags have been centralized into one `--emit` flag.
15260 * Crate type flags have been centralized into one `--crate-type` flag.
15261 * Codegen flags have been consolidated behind a `-C` flag.
15262 * Linking against outdated crates now has improved error messages.
15263 * Error messages with lifetimes will often suggest how to annotate the
15264 function to fix the error.
15265 * Many more types are documented in the standard library, and new guides
15266 were written.
15267 * Many `rustdoc` improvements:
15268 * code blocks are syntax highlighted.
15269 * render standalone markdown files.
15270 * the --test flag tests all code blocks by default.
15271 * exported macros are displayed.
15272 * re-exported types have their documentation inlined at the location of the
15273 first re-export.
15274 * search works across crates that have been rendered to the same output
15275 directory.
15276
15277
15278Version 0.9 (2014-01-09)
15279==========================
15280
15281 * ~1800 changes, numerous bugfixes
15282
15283 * Language
15284 * The `float` type has been removed. Use `f32` or `f64` instead.
15285 * A new facility for enabling experimental features (feature gating) has
15286 been added, using the crate-level `#[feature(foo)]` attribute.
15287 * Managed boxes (@) are now behind a feature gate
15288 (`#[feature(managed_boxes)]`) in preparation for future removal. Use the
15289 standard library's `Gc` or `Rc` types instead.
15290 * `@mut` has been removed. Use `std::cell::{Cell, RefCell}` instead.
15291 * Jumping back to the top of a loop is now done with `continue` instead of
15292 `loop`.
15293 * Strings can no longer be mutated through index assignment.
15294 * Raw strings can be created via the basic `r"foo"` syntax or with matched
15295 hash delimiters, as in `r###"foo"###`.
15296 * `~fn` is now written `proc (args) -> retval { ... }` and may only be
15297 called once.
15298 * The `&fn` type is now written `|args| -> ret` to match the literal form.
15299 * `@fn`s have been removed.
15300 * `do` only works with procs in order to make it obvious what the cost
15301 of `do` is.
15302 * Single-element tuple-like structs can no longer be dereferenced to
15303 obtain the inner value. A more comprehensive solution for overloading
15304 the dereference operator will be provided in the future.
15305 * The `#[link(...)]` attribute has been replaced with
15306 `#[crate_id = "name#vers"]`.
15307 * Empty `impl`s must be terminated with empty braces and may not be
15308 terminated with a semicolon.
15309 * Keywords are no longer allowed as lifetime names; the `self` lifetime
15310 no longer has any special meaning.
15311 * The old `fmt!` string formatting macro has been removed.
15312 * `printf!` and `printfln!` (old-style formatting) removed in favor of
15313 `print!` and `println!`.
15314 * `mut` works in patterns now, as in `let (mut x, y) = (1, 2);`.
15315 * The `extern mod foo (name = "bar")` syntax has been removed. Use
15316 `extern mod foo = "bar"` instead.
15317 * New reserved keywords: `alignof`, `offsetof`, `sizeof`.
15318 * Macros can have attributes.
15319 * Macros can expand to items with attributes.
15320 * Macros can expand to multiple items.
15321 * The `asm!` macro is feature-gated (`#[feature(asm)]`).
15322 * Comments may be nested.
15323 * Values automatically coerce to trait objects they implement, without
15324 an explicit `as`.
15325 * Enum discriminants are no longer an entire word but as small as needed to
15326 contain all the variants. The `repr` attribute can be used to override
15327 the discriminant size, as in `#[repr(int)]` for integer-sized, and
15328 `#[repr(C)]` to match C enums.
15329 * Non-string literals are not allowed in attributes (they never worked).
15330 * The FFI now supports variadic functions.
15331 * Octal numeric literals, as in `0o7777`.
15332 * The `concat!` syntax extension performs compile-time string concatenation.
15333 * The `#[fixed_stack_segment]` and `#[rust_stack]` attributes have been
15334 removed as Rust no longer uses segmented stacks.
15335 * Non-ascii identifiers are feature-gated (`#[feature(non_ascii_idents)]`).
15336 * Ignoring all fields of an enum variant or tuple-struct is done with `..`,
15337 not `*`; ignoring remaining fields of a struct is also done with `..`,
15338 not `_`; ignoring a slice of a vector is done with `..`, not `.._`.
15339 * `rustc` supports the "win64" calling convention via `extern "win64"`.
15340 * `rustc` supports the "system" calling convention, which defaults to the
15341 preferred convention for the target platform, "stdcall" on 32-bit Windows,
15342 "C" elsewhere.
15343 * The `type_overflow` lint (default: warn) checks literals for overflow.
15344 * The `unsafe_block` lint (default: allow) checks for usage of `unsafe`.
15345 * The `attribute_usage` lint (default: warn) warns about unknown
15346 attributes.
15347 * The `unknown_features` lint (default: warn) warns about unknown
15348 feature gates.
15349 * The `dead_code` lint (default: warn) checks for dead code.
15350 * Rust libraries can be linked statically to one another
15351 * `#[link_args]` is behind the `link_args` feature gate.
15352 * Native libraries are now linked with `#[link(name = "foo")]`
15353 * Native libraries can be statically linked to a rust crate
15354 (`#[link(name = "foo", kind = "static")]`).
15355 * Native OS X frameworks are now officially supported
15356 (`#[link(name = "foo", kind = "framework")]`).
15357 * The `#[thread_local]` attribute creates thread-local (not task-local)
15358 variables. Currently behind the `thread_local` feature gate.
15359 * The `return` keyword may be used in closures.
15360 * Types that can be copied via a memcpy implement the `Pod` kind.
15361 * The `cfg` attribute can now be used on struct fields and enum variants.
15362
15363 * Libraries
15364 * std: The `option` and `result` API's have been overhauled to make them
15365 simpler, more consistent, and more composable.
15366 * std: The entire `std::io` module has been replaced with one that is
15367 more comprehensive and that properly interfaces with the underlying
15368 scheduler. File, TCP, UDP, Unix sockets, pipes, and timers are all
15369 implemented.
15370 * std: `io::util` contains a number of useful implementations of
15371 `Reader` and `Writer`, including `NullReader`, `NullWriter`,
15372 `ZeroReader`, `TeeReader`.
15373 * std: The reference counted pointer type `extra::rc` moved into std.
15374 * std: The `Gc` type in the `gc` module will replace `@` (it is currently
15375 just a wrapper around it).
15376 * std: The `Either` type has been removed.
15377 * std: `fmt::Default` can be implemented for any type to provide default
15378 formatting to the `format!` macro, as in `format!("{}", myfoo)`.
15379 * std: The `rand` API continues to be tweaked.
15380 * std: The `rust_begin_unwind` function, useful for inserting breakpoints
15381 on failure in gdb, is now named `rust_fail`.
15382 * std: The `each_key` and `each_value` methods on `HashMap` have been
15383 replaced by the `keys` and `values` iterators.
15384 * std: Functions dealing with type size and alignment have moved from the
15385 `sys` module to the `mem` module.
15386 * std: The `path` module was written and API changed.
15387 * std: `str::from_utf8` has been changed to cast instead of allocate.
15388 * std: `starts_with` and `ends_with` methods added to vectors via the
15389 `ImmutableEqVector` trait, which is in the prelude.
15390 * std: Vectors can be indexed with the `get_opt` method, which returns `None`
15391 if the index is out of bounds.
15392 * std: Task failure no longer propagates between tasks, as the model was
15393 complex, expensive, and incompatible with thread-based tasks.
15394 * std: The `Any` type can be used for dynamic typing.
15395 * std: `~Any` can be passed to the `fail!` macro and retrieved via
15396 `task::try`.
15397 * std: Methods that produce iterators generally do not have an `_iter`
15398 suffix now.
15399 * std: `cell::Cell` and `cell::RefCell` can be used to introduce mutability
15400 roots (mutable fields, etc.). Use instead of e.g. `@mut`.
15401 * std: `util::ignore` renamed to `prelude::drop`.
15402 * std: Slices have `sort` and `sort_by` methods via the `MutableVector`
15403 trait.
15404 * std: `vec::raw` has seen a lot of cleanup and API changes.
15405 * std: The standard library no longer includes any C++ code, and very
15406 minimal C, eliminating the dependency on libstdc++.
15407 * std: Runtime scheduling and I/O functionality has been factored out into
15408 extensible interfaces and is now implemented by two different crates:
15409 libnative, for native threading and I/O; and libgreen, for green threading
15410 and I/O. This paves the way for using the standard library in more limited
15411 embedded environments.
15412 * std: The `comm` module has been rewritten to be much faster, have a
15413 simpler, more consistent API, and to work for both native and green
15414 threading.
15415 * std: All libuv dependencies have been moved into the rustuv crate.
15416 * native: New implementations of runtime scheduling on top of OS threads.
15417 * native: New native implementations of TCP, UDP, file I/O, process spawning,
15418 and other I/O.
15419 * green: The green thread scheduler and message passing types are almost
15420 entirely lock-free.
15421 * extra: The `flatpipes` module had bitrotted and was removed.
15422 * extra: All crypto functions have been removed and Rust now has a policy of
15423 not reimplementing crypto in the standard library. In the future crypto
15424 will be provided by external crates with bindings to established libraries.
15425 * extra: `c_vec` has been modernized.
15426 * extra: The `sort` module has been removed. Use the `sort` method on
15427 mutable slices.
15428
15429 * Tooling
15430 * The `rust` and `rusti` commands have been removed, due to lack of
15431 maintenance.
15432 * `rustdoc` was completely rewritten.
15433 * `rustdoc` can test code examples in documentation.
15434 * `rustpkg` can test packages with the argument, 'test'.
15435 * `rustpkg` supports arbitrary dependencies, including C libraries.
15436 * `rustc`'s support for generating debug info is improved again.
15437 * `rustc` has better error reporting for unbalanced delimiters.
15438 * `rustc`'s JIT support was removed due to bitrot.
15439 * Executables and static libraries can be built with LTO (-Z lto)
15440 * `rustc` adds a `--dep-info` flag for communicating dependencies to
15441 build tools.
15442
15443
15444Version 0.8 (2013-09-26)
15445============================
15446
15447 * ~2200 changes, numerous bugfixes
15448
15449 * Language
15450 * The `for` loop syntax has changed to work with the `Iterator` trait.
15451 * At long last, unwinding works on Windows.
15452 * Default methods are ready for use.
15453 * Many trait inheritance bugs fixed.
15454 * Owned and borrowed trait objects work more reliably.
15455 * `copy` is no longer a keyword. It has been replaced by the `Clone` trait.
15456 * rustc can omit emission of code for the `debug!` macro if it is passed
15457 `--cfg ndebug`
15458 * mod.rs is now "blessed". When loading `mod foo;`, rustc will now look
15459 for foo.rs, then foo/mod.rs, and will generate an error when both are
15460 present.
15461 * Strings no longer contain trailing nulls. The new `std::c_str` module
15462 provides new mechanisms for converting to C strings.
15463 * The type of foreign functions is now `extern "C" fn` instead of `*u8'.
15464 * The FFI has been overhauled such that foreign functions are called directly,
15465 instead of through a stack-switching wrapper.
15466 * Calling a foreign function must be done through a Rust function with the
15467 `#[fixed_stack_segment]` attribute.
15468 * The `externfn!` macro can be used to declare both a foreign function and
15469 a `#[fixed_stack_segment]` wrapper at once.
15470 * `pub` and `priv` modifiers on `extern` blocks are no longer parsed.
15471 * `unsafe` is no longer allowed on extern fns - they are all unsafe.
15472 * `priv` is disallowed everywhere except for struct fields and enum variants.
15473 * `&T` (besides `&'static T`) is no longer allowed in `@T`.
15474 * `ref` bindings in irrefutable patterns work correctly now.
15475 * `char` is now prevented from containing invalid code points.
15476 * Casting to `bool` is no longer allowed.
15477 * `\0` is now accepted as an escape in chars and strings.
15478 * `yield` is a reserved keyword.
15479 * `typeof` is a reserved keyword.
15480 * Crates may be imported by URL with `extern mod foo = "url";`.
15481 * Explicit enum discriminants may be given as uints as in `enum E { V = 0u }`
15482 * Static vectors can be initialized with repeating elements,
15483 e.g. `static foo: [u8, .. 100]: [0, .. 100];`.
15484 * Static structs can be initialized with functional record update,
15485 e.g. `static foo: Foo = Foo { a: 5, .. bar };`.
15486 * `cfg!` can be used to conditionally execute code based on the crate
15487 configuration, similarly to `#[cfg(...)]`.
15488 * The `unnecessary_qualification` lint detects unneeded module
15489 prefixes (default: allow).
15490 * Arithmetic operations have been implemented on the SIMD types in
15491 `std::unstable::simd`.
15492 * Exchange allocation headers were removed, reducing memory usage.
15493 * `format!` implements a completely new, extensible, and higher-performance
15494 string formatting system. It will replace `fmt!`.
15495 * `print!` and `println!` write formatted strings (using the `format!`
15496 extension) to stdout.
15497 * `write!` and `writeln!` write formatted strings (using the `format!`
15498 extension) to the new Writers in `std::rt::io`.
15499 * The library section in which a function or static is placed may
15500 be specified with `#[link_section = "..."]`.
15501 * The `proto!` syntax extension for defining bounded message protocols
15502 was removed.
15503 * `macro_rules!` is hygienic for `let` declarations.
15504 * The `#[export_name]` attribute specifies the name of a symbol.
15505 * `unreachable!` can be used to indicate unreachable code, and fails
15506 if executed.
15507
15508 * Libraries
15509 * std: Transitioned to the new runtime, written in Rust.
15510 * std: Added an experimental I/O library, `rt::io`, based on the new
15511 runtime.
15512 * std: A new generic `range` function was added to the prelude, replacing
15513 `uint::range` and friends.
15514 * std: `range_rev` no longer exists. Since range is an iterator it can be
15515 reversed with `range(lo, hi).invert()`.
15516 * std: The `chain` method on option renamed to `and_then`; `unwrap_or_default`
15517 renamed to `unwrap_or`.
15518 * std: The `iterator` module was renamed to `iter`.
15519 * std: Integral types now support the `checked_add`, `checked_sub`, and
15520 `checked_mul` operations for detecting overflow.
15521 * std: Many methods in `str`, `vec`, `option, `result` were renamed for
15522 consistency.
15523 * std: Methods are standardizing on conventions for casting methods:
15524 `to_foo` for copying, `into_foo` for moving, `as_foo` for temporary
15525 and cheap casts.
15526 * std: The `CString` type in `c_str` provides new ways to convert to and
15527 from C strings.
15528 * std: `DoubleEndedIterator` can yield elements in two directions.
15529 * std: The `mut_split` method on vectors partitions an `&mut [T]` into
15530 two splices.
15531 * std: `str::from_bytes` renamed to `str::from_utf8`.
15532 * std: `pop_opt` and `shift_opt` methods added to vectors.
15533 * std: The task-local data interface no longer uses @, and keys are
15534 no longer function pointers.
15535 * std: The `swap_unwrap` method of `Option` renamed to `take_unwrap`.
15536 * std: Added `SharedPort` to `comm`.
15537 * std: `Eq` has a default method for `ne`; only `eq` is required
15538 in implementations.
15539 * std: `Ord` has default methods for `le`, `gt` and `ge`; only `lt`
15540 is required in implementations.
15541 * std: `is_utf8` performance is improved, impacting many string functions.
15542 * std: `os::MemoryMap` provides cross-platform mmap.
15543 * std: `ptr::offset` is now unsafe, but also more optimized. Offsets that
15544 are not 'in-bounds' are considered undefined.
15545 * std: Many freestanding functions in `vec` removed in favor of methods.
15546 * std: Many freestanding functions on scalar types removed in favor of
15547 methods.
15548 * std: Many options to task builders were removed since they don't make
15549 sense in the new scheduler design.
15550 * std: More containers implement `FromIterator` so can be created by the
15551 `collect` method.
15552 * std: More complete atomic types in `unstable::atomics`.
15553 * std: `comm::PortSet` removed.
15554 * std: Mutating methods in the `Set` and `Map` traits have been moved into
15555 the `MutableSet` and `MutableMap` traits. `Container::is_empty`,
15556 `Map::contains_key`, `MutableMap::insert`, and `MutableMap::remove` have
15557 default implementations.
15558 * std: Various `from_str` functions were removed in favor of a generic
15559 `from_str` which is available in the prelude.
15560 * std: `util::unreachable` removed in favor of the `unreachable!` macro.
15561 * extra: `dlist`, the doubly-linked list was modernized.
15562 * extra: Added a `hex` module with `ToHex` and `FromHex` traits.
15563 * extra: Added `glob` module, replacing `std::os::glob`.
15564 * extra: `rope` was removed.
15565 * extra: `deque` was renamed to `ringbuf`. `RingBuf` implements `Deque`.
15566 * extra: `net`, and `timer` were removed. The experimental replacements
15567 are `std::rt::io::net` and `std::rt::io::timer`.
15568 * extra: Iterators implemented for `SmallIntMap`.
15569 * extra: Iterators implemented for `Bitv` and `BitvSet`.
15570 * extra: `SmallIntSet` removed. Use `BitvSet`.
15571 * extra: Performance of JSON parsing greatly improved.
15572 * extra: `semver` updated to SemVer 2.0.0.
15573 * extra: `term` handles more terminals correctly.
15574 * extra: `dbg` module removed.
15575 * extra: `par` module removed.
15576 * extra: `future` was cleaned up, with some method renames.
15577 * extra: Most free functions in `getopts` were converted to methods.
15578
15579 * Other
15580 * rustc's debug info generation (`-Z debug-info`) is greatly improved.
15581 * rustc accepts `--target-cpu` to compile to a specific CPU architecture,
15582 similarly to gcc's `--march` flag.
15583 * rustc's performance compiling small crates is much better.
15584 * rustpkg has received many improvements.
15585 * rustpkg supports git tags as package IDs.
15586 * rustpkg builds into target-specific directories so it can be used for
15587 cross-compiling.
15588 * The number of concurrent test tasks is controlled by the environment
15589 variable RUST_TEST_TASKS.
15590 * The test harness can now report metrics for benchmarks.
15591 * All tools have man pages.
15592 * Programs compiled with `--test` now support the `-h` and `--help` flags.
15593 * The runtime uses jemalloc for allocations.
15594 * Segmented stacks are temporarily disabled as part of the transition to
15595 the new runtime. Stack overflows are possible!
15596 * A new documentation backend, rustdoc_ng, is available for use. It is
15597 still invoked through the normal `rustdoc` command.
15598
15599
15600Version 0.7 (2013-07-03)
15601=======================
15602
15603 * ~2000 changes, numerous bugfixes
15604
15605 * Language
15606 * `impl`s no longer accept a visibility qualifier. Put them on methods
15607 instead.
15608 * The borrow checker has been rewritten with flow-sensitivity, fixing
15609 many bugs and inconveniences.
15610 * The `self` parameter no longer implicitly means `&'self self`,
15611 and can be explicitly marked with a lifetime.
15612 * Overloadable compound operators (`+=`, etc.) have been temporarily
15613 removed due to bugs.
15614 * The `for` loop protocol now requires `for`-iterators to return `bool`
15615 so they compose better.
15616 * The `Durable` trait is replaced with the `'static` bounds.
15617 * Trait default methods work more often.
15618 * Structs with the `#[packed]` attribute have byte alignment and
15619 no padding between fields.
15620 * Type parameters bound by `Copy` must now be copied explicitly with
15621 the `copy` keyword.
15622 * It is now illegal to move out of a dereferenced unsafe pointer.
15623 * `Option<~T>` is now represented as a nullable pointer.
15624 * `@mut` does dynamic borrow checks correctly.
15625 * The `main` function is only detected at the topmost level of the crate.
15626 The `#[main]` attribute is still valid anywhere.
15627 * Struct fields may no longer be mutable. Use inherited mutability.
15628 * The `#[no_send]` attribute makes a type that would otherwise be
15629 `Send`, not.
15630 * The `#[no_freeze]` attribute makes a type that would otherwise be
15631 `Freeze`, not.
15632 * Unbounded recursion will abort the process after reaching the limit
15633 specified by the `RUST_MAX_STACK` environment variable (default: 1GB).
15634 * The `vecs_implicitly_copyable` lint mode has been removed. Vectors
15635 are never implicitly copyable.
15636 * `#[static_assert]` makes compile-time assertions about static bools.
15637 * At long last, 'argument modes' no longer exist.
15638 * The rarely used `use mod` statement no longer exists.
15639
15640 * Syntax extensions
15641 * `fail!` and `assert!` accept `~str`, `&'static str` or `fmt!`-style
15642 argument list.
15643 * `Encodable`, `Decodable`, `Ord`, `TotalOrd`, `TotalEq`, `DeepClone`,
15644 `Rand`, `Zero` and `ToStr` can all be automatically derived with
15645 `#[deriving(...)]`.
15646 * The `bytes!` macro returns a vector of bytes for string, u8, char,
15647 and unsuffixed integer literals.
15648
15649 * Libraries
15650 * The `core` crate was renamed to `std`.
15651 * The `std` crate was renamed to `extra`.
15652 * More and improved documentation.
15653 * std: `iterator` module for external iterator objects.
15654 * Many old-style (internal, higher-order function) iterators replaced by
15655 implementations of `Iterator`.
15656 * std: Many old internal vector and string iterators,
15657 incl. `any`, `all`. removed.
15658 * std: The `finalize` method of `Drop` renamed to `drop`.
15659 * std: The `drop` method now takes `&mut self` instead of `&self`.
15660 * std: The prelude no longer re-exports any modules, only types and traits.
15661 * std: Prelude additions: `print`, `println`, `FromStr`, `ApproxEq`, `Equiv`,
15662 `Iterator`, `IteratorUtil`, many numeric traits, many tuple traits.
15663 * std: New numeric traits: `Fractional`, `Real`, `RealExt`, `Integer`, `Ratio`,
15664 `Algebraic`, `Trigonometric`, `Exponential`, `Primitive`.
15665 * std: Tuple traits and accessors defined for up to 12-tuples, e.g.
15666 `(0, 1, 2).n2()` or `(0, 1, 2).n2_ref()`.
15667 * std: Many types implement `Clone`.
15668 * std: `path` type renamed to `Path`.
15669 * std: `mut` module and `Mut` type removed.
15670 * std: Many standalone functions removed in favor of methods and iterators
15671 in `vec`, `str`. In the future methods will also work as functions.
15672 * std: `reinterpret_cast` removed. Use `transmute`.
15673 * std: ascii string handling in `std::ascii`.
15674 * std: `Rand` is implemented for ~/@.
15675 * std: `run` module for spawning processes overhauled.
15676 * std: Various atomic types added to `unstable::atomic`.
15677 * std: Various types implement `Zero`.
15678 * std: `LinearMap` and `LinearSet` renamed to `HashMap` and `HashSet`.
15679 * std: Borrowed pointer functions moved from `ptr` to `borrow`.
15680 * std: Added `os::mkdir_recursive`.
15681 * std: Added `os::glob` function performs filesystems globs.
15682 * std: `FuzzyEq` renamed to `ApproxEq`.
15683 * std: `Map` now defines `pop` and `swap` methods.
15684 * std: `Cell` constructors converted to static methods.
15685 * extra: `rc` module adds the reference counted pointers, `Rc` and `RcMut`.
15686 * extra: `flate` module moved from `std` to `extra`.
15687 * extra: `fileinput` module for iterating over a series of files.
15688 * extra: `Complex` number type and `complex` module.
15689 * extra: `Rational` number type and `rational` module.
15690 * extra: `BigInt`, `BigUint` implement numeric and comparison traits.
15691 * extra: `term` uses terminfo now, is more correct.
15692 * extra: `arc` functions converted to methods.
15693 * extra: Implementation of fixed output size variations of SHA-2.
15694
15695 * Tooling
15696 * `unused_variables` lint mode for unused variables (default: warn).
15697 * `unused_unsafe` lint mode for detecting unnecessary `unsafe` blocks
15698 (default: warn).
15699 * `unused_mut` lint mode for identifying unused `mut` qualifiers
15700 (default: warn).
15701 * `dead_assignment` lint mode for unread variables (default: warn).
15702 * `unnecessary_allocation` lint mode detects some heap allocations that are
15703 immediately borrowed so could be written without allocating (default: warn).
15704 * `missing_doc` lint mode (default: allow).
15705 * `unreachable_code` lint mode (default: warn).
15706 * The `rusti` command has been rewritten and a number of bugs addressed.
15707 * rustc outputs in color on more terminals.
15708 * rustc accepts a `--link-args` flag to pass arguments to the linker.
15709 * rustc accepts a `-Z print-link-args` flag for debugging linkage.
15710 * Compiling with `-g` will make the binary record information about
15711 dynamic borrowcheck failures for debugging.
15712 * rustdoc has a nicer stylesheet.
15713 * Various improvements to rustdoc.
15714 * Improvements to rustpkg (see the detailed release notes).
15715
15716
15717Version 0.6 (2013-04-03)
15718========================
15719
15720 * ~2100 changes, numerous bugfixes
15721
15722 * Syntax changes
15723 * The self type parameter in traits is now spelled `Self`
15724 * The `self` parameter in trait and impl methods must now be explicitly
15725 named (for example: `fn f(&self) { }`). Implicit self is deprecated.
15726 * Static methods no longer require the `static` keyword and instead
15727 are distinguished by the lack of a `self` parameter
15728 * Replaced the `Durable` trait with the `'static` lifetime
15729 * The old closure type syntax with the trailing sigil has been
15730 removed in favor of the more consistent leading sigil
15731 * `super` is a keyword, and may be prefixed to paths
15732 * Trait bounds are separated with `+` instead of whitespace
15733 * Traits are implemented with `impl Trait for Type`
15734 instead of `impl Type: Trait`
15735 * Lifetime syntax is now `&'l foo` instead of `&l/foo`
15736 * The `export` keyword has finally been removed
15737 * The `move` keyword has been removed (see "Semantic changes")
15738 * The interior mutability qualifier on vectors, `[mut T]`, has been
15739 removed. Use `&mut [T]`, etc.
15740 * `mut` is no longer valid in `~mut T`. Use inherited mutability
15741 * `fail` is no longer a keyword. Use `fail!()`
15742 * `assert` is no longer a keyword. Use `assert!()`
15743 * `log` is no longer a keyword. use `debug!`, etc.
15744 * 1-tuples may be represented as `(T,)`
15745 * Struct fields may no longer be `mut`. Use inherited mutability,
15746 `@mut T`, `core::mut` or `core::cell`
15747 * `extern mod { ... }` is no longer valid syntax for foreign
15748 function modules. Use extern blocks: `extern { ... }`
15749 * Newtype enums removed. Use tuple-structs.
15750 * Trait implementations no longer support visibility modifiers
15751 * Pattern matching over vectors improved and expanded
15752 * `const` renamed to `static` to correspond to lifetime name,
15753 and make room for future `static mut` unsafe mutable globals.
15754 * Replaced `#[deriving_eq]` with `#[deriving(Eq)]`, etc.
15755 * `Clone` implementations can be automatically generated with
15756 `#[deriving(Clone)]`
15757 * Casts to traits must use a pointer sigil, e.g. `@foo as @Bar`
15758 instead of `foo as Bar`.
15759 * Fixed length vector types are now written as `[int, .. 3]`
15760 instead of `[int * 3]`.
15761 * Fixed length vector types can express the length as a constant
15762 expression. (ex: `[int, .. GL_BUFFER_SIZE - 2]`)
15763
15764 * Semantic changes
15765 * Types with owned pointers or custom destructors move by default,
15766 eliminating the `move` keyword
15767 * All foreign functions are considered unsafe
15768 * &mut is now unaliasable
15769 * Writes to borrowed @mut pointers are prevented dynamically
15770 * () has size 0
15771 * The name of the main function can be customized using #[main]
15772 * The default type of an inferred closure is &fn instead of @fn
15773 * `use` statements may no longer be "chained" - they cannot import
15774 identifiers imported by previous `use` statements
15775 * `use` statements are crate relative, importing from the "top"
15776 of the crate by default. Paths may be prefixed with `super::`
15777 or `self::` to change the search behavior.
15778 * Method visibility is inherited from the implementation declaration
15779 * Structural records have been removed
15780 * Many more types can be used in static items, including enums
15781 'static-lifetime pointers and vectors
15782 * Pattern matching over vectors improved and expanded
15783 * Typechecking of closure types has been overhauled to
15784 improve inference and eliminate unsoundness
15785 * Macros leave scope at the end of modules, unless that module is
15786 tagged with #[macro_escape]
15787
15788 * Libraries
15789 * Added big integers to `std::bigint`
15790 * Removed `core::oldcomm` module
15791 * Added pipe-based `core::comm` module
15792 * Numeric traits have been reorganized under `core::num`
15793 * `vec::slice` finally returns a slice
15794 * `debug!` and friends don't require a format string, e.g. `debug!(Foo)`
15795 * Containers reorganized around traits in `core::container`
15796 * `core::dvec` removed, `~[T]` is a drop-in replacement
15797 * `core::send_map` renamed to `core::hashmap`
15798 * `std::map` removed; replaced with `core::hashmap`
15799 * `std::treemap` reimplemented as an owned balanced tree
15800 * `std::deque` and `std::smallintmap` reimplemented as owned containers
15801 * `core::trie` added as a fast ordered map for integer keys
15802 * Set types added to `core::hashmap`, `core::trie` and `std::treemap`
15803 * `Ord` split into `Ord` and `TotalOrd`. `Ord` is still used to
15804 overload the comparison operators, whereas `TotalOrd` is used
15805 by certain container types
15806
15807 * Other
15808 * Replaced the 'cargo' package manager with 'rustpkg'
15809 * Added all-purpose 'rust' tool
15810 * `rustc --test` now supports benchmarks with the `#[bench]` attribute
15811 * rustc now *attempts* to offer spelling suggestions
15812 * Improved support for ARM and Android
15813 * Preliminary MIPS backend
15814 * Improved foreign function ABI implementation for x86, x86_64
15815 * Various memory usage improvements
15816 * Rust code may be embedded in foreign code under limited circumstances
15817 * Inline assembler supported by new asm!() syntax extension.
15818
15819
15820Version 0.5 (2012-12-21)
15821===========================
15822
15823 * ~900 changes, numerous bugfixes
15824
15825 * Syntax changes
15826 * Removed `<-` move operator
15827 * Completed the transition from the `#fmt` extension syntax to `fmt!`
15828 * Removed old fixed length vector syntax - `[T]/N`
15829 * New token-based quasi-quoters, `quote_tokens!`, `quote_expr!`, etc.
15830 * Macros may now expand to items and statements
15831 * `a.b()` is always parsed as a method call, never as a field projection
15832 * `Eq` and `IterBytes` implementations can be automatically generated
15833 with `#[deriving_eq]` and `#[deriving_iter_bytes]` respectively
15834 * Removed the special crate language for `.rc` files
15835 * Function arguments may consist of any irrefutable pattern
15836
15837 * Semantic changes
15838 * `&` and `~` pointers may point to objects
15839 * Tuple structs - `struct Foo(Bar, Baz)`. Will replace newtype enums.
15840 * Enum variants may be structs
15841 * Destructors can be added to all nominal types with the Drop trait
15842 * Structs and nullary enum variants may be constants
15843 * Values that cannot be implicitly copied are now automatically moved
15844 without writing `move` explicitly
15845 * `&T` may now be coerced to `*T`
15846 * Coercions happen in `let` statements as well as function calls
15847 * `use` statements now take crate-relative paths
15848 * The module and type namespaces have been merged so that static
15849 method names can be resolved under the trait in which they are
15850 declared
15851
15852 * Improved support for language features
15853 * Trait inheritance works in many scenarios
15854 * More support for explicit self arguments in methods - `self`, `&self`
15855 `@self`, and `~self` all generally work as expected
15856 * Static methods work in more situations
15857 * Experimental: Traits may declare default methods for the implementations
15858 to use
15859
15860 * Libraries
15861 * New condition handling system in `core::condition`
15862 * Timsort added to `std::sort`
15863 * New priority queue, `std::priority_queue`
15864 * Pipes for serializable types, `std::flatpipes'
15865 * Serialization overhauled to be trait-based
15866 * Expanded `getopts` definitions
15867 * Moved futures to `std`
15868 * More functions are pure now
15869 * `core::comm` renamed to `oldcomm`. Still deprecated
15870 * `rustdoc` and `cargo` are libraries now
15871
15872 * Misc
15873 * Added a preliminary REPL, `rusti`
15874 * License changed from MIT to dual MIT/APL2
15875
15876
15877Version 0.4 (2012-10-15)
15878==========================
15879
15880 * ~2000 changes, numerous bugfixes
15881
15882 * Syntax
15883 * All keywords are now strict and may not be used as identifiers anywhere
15884 * Keyword removal: 'again', 'import', 'check', 'new', 'owned', 'send',
15885 'of', 'with', 'to', 'class'.
15886 * Classes are replaced with simpler structs
15887 * Explicit method self types
15888 * `ret` became `return` and `alt` became `match`
15889 * `import` is now `use`; `use is now `extern mod`
15890 * `extern mod { ... }` is now `extern { ... }`
15891 * `use mod` is the recommended way to import modules
15892 * `pub` and `priv` replace deprecated export lists
15893 * The syntax of `match` pattern arms now uses fat arrow (=>)
15894 * `main` no longer accepts an args vector; use `os::args` instead
15895
15896 * Semantics
15897 * Trait implementations are now coherent, ala Haskell typeclasses
15898 * Trait methods may be static
15899 * Argument modes are deprecated
15900 * Borrowed pointers are much more mature and recommended for use
15901 * Strings and vectors in the static region are stored in constant memory
15902 * Typestate was removed
15903 * Resolution rewritten to be more reliable
15904 * Support for 'dual-mode' data structures (freezing and thawing)
15905
15906 * Libraries
15907 * Most binary operators can now be overloaded via the traits in
15908 `core::ops'
15909 * `std::net::url` for representing URLs
15910 * Sendable hash maps in `core::send_map`
15911 * `core::task' gained a (currently unsafe) task-local storage API
15912
15913 * Concurrency
15914 * An efficient new intertask communication primitive called the pipe,
15915 along with a number of higher-level channel types, in `core::pipes`
15916 * `std::arc`, an atomically reference counted, immutable, shared memory
15917 type
15918 * `std::sync`, various exotic synchronization tools based on arcs and pipes
15919 * Futures are now based on pipes and sendable
15920 * More robust linked task failure
15921 * Improved task builder API
15922
15923 * Other
15924 * Improved error reporting
15925 * Preliminary JIT support
15926 * Preliminary work on precise GC
15927 * Extensive architectural improvements to rustc
15928 * Begun a transition away from buggy C++-based reflection (shape) code to
15929 Rust-based (visitor) code
15930 * All hash functions and tables converted to secure, randomized SipHash
15931
15932
15933Version 0.3 (2012-07-12)
15934========================
15935
15936 * ~1900 changes, numerous bugfixes
15937
15938 * New coding conveniences
15939 * Integer-literal suffix inference
15940 * Per-item control over warnings, errors
15941 * #[cfg(windows)] and #[cfg(unix)] attributes
15942 * Documentation comments
15943 * More compact closure syntax
15944 * 'do' expressions for treating higher-order functions as
15945 control structures
15946 * *-patterns (wildcard extended to all constructor fields)
15947
15948 * Semantic cleanup
15949 * Name resolution pass and exhaustiveness checker rewritten
15950 * Region pointers and borrow checking supersede alias
15951 analysis
15952 * Init-ness checking is now provided by a region-based liveness
15953 pass instead of the typestate pass; same for last-use analysis
15954 * Extensive work on region pointers
15955
15956 * Experimental new language features
15957 * Slices and fixed-size, interior-allocated vectors
15958 * #!-comments for lang versioning, shell execution
15959 * Destructors and iface implementation for classes;
15960 type-parameterized classes and class methods
15961 * 'const' type kind for types that can be used to implement
15962 shared-memory concurrency patterns
15963
15964 * Type reflection
15965
15966 * Removal of various obsolete features
15967 * Keywords: 'be', 'prove', 'syntax', 'note', 'mutable', 'bind',
15968 'crust', 'native' (now 'extern'), 'cont' (now 'again')
15969
15970 * Constructs: do-while loops ('do' repurposed), fn binding,
15971 resources (replaced by destructors)
15972
15973 * Compiler reorganization
15974 * Syntax-layer of compiler split into separate crate
15975 * Clang (from LLVM project) integrated into build
15976 * Typechecker split into sub-modules
15977
15978 * New library code
15979 * New time functions
15980 * Extension methods for many built-in types
15981 * Arc: atomic-refcount read-only / exclusive-use shared cells
15982 * Par: parallel map and search routines
15983 * Extensive work on libuv interface
15984 * Much vector code moved to libraries
15985 * Syntax extensions: #line, #col, #file, #mod, #stringify,
15986 #include, #include_str, #include_bin
15987
15988 * Tool improvements
15989 * Cargo automatically resolves dependencies
15990
15991
15992Version 0.2 (2012-03-29)
15993=========================
15994
15995 * >1500 changes, numerous bugfixes
15996
15997 * New docs and doc tooling
15998
15999 * New port: FreeBSD x86_64
16000
16001 * Compilation model enhancements
16002 * Generics now specialized, multiply instantiated
16003 * Functions now inlined across separate crates
16004
16005 * Scheduling, stack and threading fixes
16006 * Noticeably improved message-passing performance
16007 * Explicit schedulers
16008 * Callbacks from C
16009 * Helgrind clean
16010
16011 * Experimental new language features
16012 * Operator overloading
16013 * Region pointers
16014 * Classes
16015
16016 * Various language extensions
16017 * C-callback function types: 'crust fn ...'
16018 * Infinite-loop construct: 'loop { ... }'
16019 * Shorten 'mutable' to 'mut'
16020 * Required mutable-local qualifier: 'let mut ...'
16021 * Basic glob-exporting: 'export foo::*;'
16022 * Alt now exhaustive, 'alt check' for runtime-checked
16023 * Block-function form of 'for' loop, with 'break' and 'ret'.
16024
16025 * New library code
16026 * AST quasi-quote syntax extension
16027 * Revived libuv interface
16028 * New modules: core::{future, iter}, std::arena
16029 * Merged per-platform std::{os*, fs*} to core::{libc, os}
16030 * Extensive cleanup, regularization in libstd, libcore
16031
16032
16033Version 0.1 (2012-01-20)
16034===============================
16035
16036 * Most language features work, including:
16037 * Unique pointers, unique closures, move semantics
16038 * Interface-constrained generics
16039 * Static interface dispatch
16040 * Stack growth
16041 * Multithread task scheduling
16042 * Typestate predicates
16043 * Failure unwinding, destructors
16044 * Pattern matching and destructuring assignment
16045 * Lightweight block-lambda syntax
16046 * Preliminary macro-by-example
16047
16048 * Compiler works with the following configurations:
16049 * Linux: x86 and x86_64 hosts and targets
16050 * macOS: x86 and x86_64 hosts and targets
16051 * Windows: x86 hosts and targets
16052
16053 * Cross compilation / multi-target configuration supported.
16054
16055 * Preliminary API-documentation and package-management tools included.
16056
16057Known issues:
16058
16059 * Documentation is incomplete.
16060
16061 * Performance is below intended target.
16062
16063 * Standard library APIs are subject to extensive change, reorganization.
16064
16065 * Language-level versioning is not yet operational - future code will
16066 break unexpectedly.