|
| 1 | +Version 1.43.0 (2020-04-23) |
| 2 | +========================== |
| 3 | + |
| 4 | +Language |
| 5 | +-------- |
| 6 | +- [Fixed using binary operations with `&{number}` (e.g. `&1.0`) not having |
| 7 | + the correctly inferred type.][68129] |
| 8 | + |
| 9 | +**Syntax only changes** |
| 10 | +- [Allow `type Foo: Ord` syntactically.][69361] |
| 11 | +- [Unify item parsing & filter illegal item kinds.][69366] |
| 12 | +- [Fuse associated and extern items up to defaultness.][69194] |
| 13 | +- [Permit attributes on `if` expressions.][69201] |
| 14 | +- [Syntactically allow `self` in all `fn` contexts.][68764] |
| 15 | +- [Merge `fn` syntax + cleanup item parsing.][68728] |
| 16 | + |
| 17 | +These are still rejected *semantically*, so you will likely receive an error but |
| 18 | +these changes can be seen and parsed by procedural macros and |
| 19 | +conditional compilation. |
| 20 | + |
| 21 | + |
| 22 | +Compiler |
| 23 | +-------- |
| 24 | +- [You can now pass multiple lint flags to rustc to override the previous |
| 25 | + flags.][67885] For example; `rustc -D unused -A unused-variables` denies |
| 26 | + everything in the `unused` lint group unused except `unused-variables` which |
| 27 | + is explicitly allowed. Passing `rustc -A unused-variables -D unused` denies |
| 28 | + everything in the `unused` lint group **including** `unused-variables` since |
| 29 | + the allow flag is specified before the deny flag (and therefore overridden). |
| 30 | +- [rustc will now prefer your system MinGW libraries over its bundled libraries |
| 31 | + if they are available on `windows-gnu`.][67429] |
| 32 | +- [rustc now buffers errors/warnings printed in JSON.][69227] |
| 33 | + |
| 34 | +Libraries |
| 35 | +--------- |
| 36 | +- [`Arc<[T; N]>`, `Box<[T; N]>`, and `Rc<[T; N]>`, now implement |
| 37 | + `TryFrom<Arc<[T]>>`,`TryFrom<Box<[T]>>`, and `TryFrom<Rc<[T]>>` |
| 38 | + respectively.][69538] Where `N` is `0..=32`. |
| 39 | +- [All `to_be_bytes`, `to_le_bytes`, `to_ne_bytes`, `from_be_bytes`, |
| 40 | + `from_le_bytes`, and `from_ne_bytes` methods for integers are |
| 41 | + now `const`.][69373] |
| 42 | +- [You can now use associated constants on floats and integers directly, rather |
| 43 | + than having to import the module.][68952] e.g. You can now write `u32::MAX` or |
| 44 | + `f32::NAN` no imports. |
| 45 | +- [`u8::is_ascii` is now `const`.][68984] |
| 46 | +- [`String` now implements `AsMut<str>`.][68742] |
| 47 | +- [Added the `primitive` module to `std` and `core`.][67637] This module |
| 48 | + reexports Rust's primitive types. This is mainly useful for use in macros |
| 49 | + where you want avoid these types being shadowed. |
| 50 | +- [The some of the trait bounds on `HashMap` and `HashSet`.][67642] |
| 51 | +- [`string::FromUtf8Error` now implements `Clone + Eq`.][68738] |
| 52 | + |
| 53 | +Stabilized APIs |
| 54 | +--------------- |
| 55 | +- [`Once::is_completed`] |
| 56 | +- [`f32::LOG10_2`] |
| 57 | +- [`f32::LOG2_10`] |
| 58 | +- [`f64::LOG10_2`] |
| 59 | +- [`f64::LOG2_10`] |
| 60 | +- [`iter::once_with`] |
| 61 | + |
| 62 | +Misc |
| 63 | +---- |
| 64 | +- [Certain checks in the `const_err` lint were deemed unrelated to const |
| 65 | + evaluation][69185], and have been moved to the `unconditional_panic` and |
| 66 | + `arithmetic_overflow` lints. |
| 67 | + |
| 68 | +Internal Only |
| 69 | +------------- |
| 70 | +These changes provide no direct user facing benefits, but represent significant |
| 71 | +improvements to the internals and overall performance of `rustc` and |
| 72 | +related tools. |
| 73 | + |
| 74 | +- [All components are now built with `opt-level=3` instead of `2`.][67878] |
| 75 | +- [Improved how rustc generates drop code.][67332] |
| 76 | +- [Improved performance from `#[inline]`-ing certain hot functions.][69256] |
| 77 | +- [traits: preallocate 2 Vecs of known initial size][69022] |
| 78 | +- [Avoid exponential behaviour when relating types][68772] |
| 79 | +- [Skip `Drop` terminators for enum variants without drop glue][68943] |
| 80 | +- [Improve performance of coherence checks][68966] |
| 81 | +- [Deduplicate types in the generator witness][68672] |
| 82 | +- [Invert control in struct_lint_level.][68725] |
| 83 | + |
| 84 | +[67332]: https://github.com/rust-lang/rust/pull/67332/ |
| 85 | +[67429]: https://github.com/rust-lang/rust/pull/67429/ |
| 86 | +[67637]: https://github.com/rust-lang/rust/pull/67637/ |
| 87 | +[67642]: https://github.com/rust-lang/rust/pull/67642/ |
| 88 | +[67878]: https://github.com/rust-lang/rust/pull/67878/ |
| 89 | +[67885]: https://github.com/rust-lang/rust/pull/67885/ |
| 90 | +[68129]: https://github.com/rust-lang/rust/pull/68129/ |
| 91 | +[68672]: https://github.com/rust-lang/rust/pull/68672/ |
| 92 | +[68725]: https://github.com/rust-lang/rust/pull/68725/ |
| 93 | +[68728]: https://github.com/rust-lang/rust/pull/68728/ |
| 94 | +[68738]: https://github.com/rust-lang/rust/pull/68738/ |
| 95 | +[68742]: https://github.com/rust-lang/rust/pull/68742/ |
| 96 | +[68764]: https://github.com/rust-lang/rust/pull/68764/ |
| 97 | +[68772]: https://github.com/rust-lang/rust/pull/68772/ |
| 98 | +[68943]: https://github.com/rust-lang/rust/pull/68943/ |
| 99 | +[68952]: https://github.com/rust-lang/rust/pull/68952/ |
| 100 | +[68966]: https://github.com/rust-lang/rust/pull/68966/ |
| 101 | +[68984]: https://github.com/rust-lang/rust/pull/68984/ |
| 102 | +[69022]: https://github.com/rust-lang/rust/pull/69022/ |
| 103 | +[69185]: https://github.com/rust-lang/rust/pull/69185/ |
| 104 | +[69194]: https://github.com/rust-lang/rust/pull/69194/ |
| 105 | +[69201]: https://github.com/rust-lang/rust/pull/69201/ |
| 106 | +[69227]: https://github.com/rust-lang/rust/pull/69227/ |
| 107 | +[69256]: https://github.com/rust-lang/rust/pull/69256/ |
| 108 | +[69361]: https://github.com/rust-lang/rust/pull/69361/ |
| 109 | +[69366]: https://github.com/rust-lang/rust/pull/69366/ |
| 110 | +[69373]: https://github.com/rust-lang/rust/pull/69373/ |
| 111 | +[69538]: https://github.com/rust-lang/rust/pull/69538/ |
| 112 | +[`Once::is_completed`]: https://doc.rust-lang.org/std/sync/struct.Once.html#method.is_completed |
| 113 | +[`f32::LOG10_2`]: https://doc.rust-lang.org/std/f32/consts/constant.LOG10_2.html |
| 114 | +[`f32::LOG2_10`]: https://doc.rust-lang.org/std/f32/consts/constant.LOG2_10.html |
| 115 | +[`f64::LOG10_2`]: https://doc.rust-lang.org/std/f64/consts/constant.LOG10_2.html |
| 116 | +[`f64::LOG2_10`]: https://doc.rust-lang.org/std/f64/consts/constant.LOG2_10.html |
| 117 | +[`iter::once_with`]: https://doc.rust-lang.org/std/iter/fn.once_with.html |
| 118 | + |
| 119 | + |
1 | 120 | Version 1.42.0 (2020-03-12)
|
2 | 121 | ==========================
|
3 | 122 |
|
|
0 commit comments