Commit d6fa6212 authored by Aaron Power's avatar Aaron Power

Updated for 1.34.0

parent eab3eb38
Version v1.34.0 (2019-04-11)
- [You can now use `#[deprecation = "reason"]`][58166] as a shorthand for
`#[deprecation(note = "reason")]`. This was previously allowed as a syntax bug
but had no effect.
- [You can now accept token streams in `#[attr()]`,`#[attr[]]`, and
`#[attr{}]` procedural macros.][57367]
- [You can now write `extern crate self as foo;`][57407] to import the your
crate's root into the extern prelude.
- [You can now target `riscv64imac-unknown-none-elf` and
- [You can now enable linker plugin LTO optimisations with
`-C linker-plugin-lto`.][58057] This allows rustc to compile your Rust code
into LLVM bitcode allowing LLVM to perform LTO optimisations across C/C++ FFI
- [You can now target `powerpc64-unknown-freebsd`.][57809]
- [The trait bounds have been removed on some of `HashMap<K, V, S>`'s and
`HashSet<T, S>`'s basic methods.][58370] Most notably you no longer require
the `Hash` trait to create an iterator.
- [Relax Ord trait bounds have been removed on some of `BinaryHeap<T>`'s basic
methods.][58421] Most notably you no longer require the `Ord` trait to create
an iterator.
- [The methods `overflowing_neg` and `wrapping_neg` are now `const` functions
for all numeric types.][58044]
- [Indexing a `str` is now generic over all types that
implement `SliceIndex<str>`.][57604]
- [`str::trim`, `str::trim_matches`, `str::trim_{start, end}`, and
`str::trim_{start, end}_matches` are now `#[must_use]`][57106] and will
produce a warning if their returning type is unused.
- [The methods `checked_pow`, `saturating_pow`, `wrapping_pow`, and
`overflowing_pow` are now available for all numeric types.][57873] These are
equivalvent to methods such as `wrapping_add` for the `pow` operation.
Stabilized APIs
#### std & core
* [`Any::type_id`]
* [`Error::type_id`]
* [`atomic::AtomicI16`]
* [`atomic::AtomicI32`]
* [`atomic::AtomicI64`]
* [`atomic::AtomicI8`]
* [`atomic::AtomicU16`]
* [`atomic::AtomicU32`]
* [`atomic::AtomicU64`]
* [`atomic::AtomicU8`]
* [`convert::Infallible`]
* [`convert::TryFrom`]
* [`convert::TryInto`]
* [`iter::FromFn`]
* [`iter::Successors`]
* [`iter::from_fn`]
* [`iter::successors`]
* [`num::NonZeroI128`]
* [`num::NonZeroI16`]
* [`num::NonZeroI32`]
* [`num::NonZeroI64`]
* [`num::NonZeroI8`]
* [`num::NonZeroIsize`]
* [`slice::sort_by_cached_key`]
* [`str::escape_debug`]
* [`str::escape_default`]
* [`str::escape_unicode`]
* [`str::split_ascii_whitespace`]
#### std
* [`Instant::checked_add`]
* [`Instant::checked_sub`]
* [`SystemTime::checked_add`]
* [`SystemTime::checked_sub`]
- [You can now use alternatives registries to][cargo/6654]
- [You can now use the `?` operator in your documentation tests without manually
adding `fn main() -> Result<(), _> {}`.][56470]
Compatibility Notes
- [`Command::before_exec` is now deprecated in favor of the
unsafe method `Command::pre_exec`.][58059]
- [Use of `ATOMIC_{BOOL, ISIZE, USIZE}_INIT` is now deprecated.][57425] As you
can now use `const` functions in `static` variables.
Version 1.33.0 (2019-02-28)
......@@ -99,6 +249,8 @@ Stabilized APIs
- [You can now publish crates which require a feature flag to compile with
`cargo publish --features` or `cargo publish --all-features`.][cargo/6453]
- [Cargo should now rebuild a crate if a file was modified during the initial
......@@ -135,6 +287,7 @@ Compatibility Notes
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment