Version 1.14.0 (2016-12-22)
Language
..
matches multiple tuple fields in enum variants, structs and tuples. RFC 1492.- Safe
fn
items can be coerced tounsafe fn
pointers use *
anduse ::*
both glob-import from the crate root- It's now possible to call a
Vec<Box<Fn()>>
without explicit dereferencing
Compiler
- Mark enums with non-zero discriminant as non-zero
- Lower-case
static mut
names are linted like other statics and consts - Fix ICE on some macros in const integer positions
(e.g.
[u8; m!()]
) - Improve error message and snippet for "did you mean
x
" - Add a panic-strategy field to the target specification
- Include LLVM version in
--version --verbose
Compile-time Optimizations
- Improve macro expansion performance
- Shrink
Expr_::ExprInlineAsm
- Replace all uses of SHA-256 with BLAKE2b
- Reduce the number of bytes hashed by
IchHasher
- Avoid more allocations when compiling html5ever
- Use
SmallVector
inCombineFields::instantiate
- Avoid some allocations in the macro parser
- Use a faster deflate setting
- Add
ArrayVec
andAccumulateVec
to reduce heap allocations during interning of slices - Optimize
write_metadata
- Don't process obligation forest cycles when stalled
- Avoid many
CrateConfig
clones - Optimize
Substs::super_fold_with
- Optimize
ObligationForest
'sNodeState
handling - Speed up
plug_leaks
Libraries
println!()
, with no arguments, prints newline. Previously, an empty string was required to achieve the same.Wrapping
impls standard binary and unary operators, as well as theSum
andProduct
iterators- Implement
From<Cow<str>> for String
andFrom<Cow<[T]>> for Vec<T>
- Improve
fold
performance forchain
,cloned
,map
, andVecDeque
iterators - Improve
SipHasher
performance on small values - Add Iterator trait TrustedLen to enable better FromIterator / Extend
- Expand
.zip()
specialization to.map()
and.cloned()
ReadDir
implementsDebug
- Implement
RefUnwindSafe
for atomic types - Specialize
Vec::extend
toVec::extend_from_slice
- Avoid allocations in
Decoder::read_str
io::Error
implementsFrom<io::ErrorKind>
- Impl
Debug
for raw pointers to unsized data - Don't reuse
HashMap
random seeds - The internal memory layout of
HashMap
is more cache-friendly, for significant improvements in some operations HashMap
uses less memory on 32-bit architectures- Impl
Add<{str, Cow<str>}>
forCow<str>
Cargo
- Expose rustc cfg values to build scripts
- Allow cargo to work with read-only
CARGO_HOME
- Fix passing --features when testing multiple packages
- Use a single profile set per workspace
- Load
replace
sections from lock files - Ignore
panic
configuration for test/bench profiles
Tooling
- rustup is the recommended Rust installation method
- This release includes host (rustc) builds for Linux on MIPS, PowerPC, and
S390x. These are tier 2 platforms and may have major defects. Follow the
instructions on the website to install, or add the targets to an existing
installation with
rustup target add
. The new target triples are:mips-unknown-linux-gnu
mipsel-unknown-linux-gnu
mips64-unknown-linux-gnuabi64
mips64el-unknown-linux-gnuabi64
powerpc-unknown-linux-gnu
powerpc64-unknown-linux-gnu
powerpc64le-unknown-linux-gnu
s390x-unknown-linux-gnu
- This release includes target (std) builds for ARM Linux running MUSL
libc. These are tier 2 platforms and may have major defects. Add the
following triples to an existing rustup installation with
rustup target add
:arm-unknown-linux-musleabi
arm-unknown-linux-musleabihf
armv7-unknown-linux-musleabihf
- This release includes experimental support for WebAssembly, via
the
wasm32-unknown-emscripten
target. This target is known to have major defects. Please test, report, and fix. - rustup no longer installs documentation by default. Run
rustup component add rust-docs
to install. - Fix line stepping in debugger
- Enable line number debuginfo in releases
Misc
- Disable jemalloc on aarch64/powerpc/mips
- Add support for Fuchsia OS
- Detect local-rebuild by only MAJOR.MINOR version
Compatibility Notes
- A number of forward-compatibility lints used by the compiler
to gradually introduce language changes have been converted
to deny by default:
- "use of inaccessible extern crate erroneously allowed"
- "type parameter default erroneously allowed in invalid location"
- "detects super or self keywords at the beginning of global path"
- "two overlapping inherent impls define an item with the same name were erroneously allowed"
- "floating-point constants cannot be used in patterns"
- "constants of struct or enum type can only be used in a pattern if
the struct or enum has
#[derive(PartialEq, Eq)]
" - "lifetimes or labels named
'_
were erroneously allowed"
- Prohibit patterns in trait methods without bodies
- The atomic
Ordering
enum may not be matched exhaustively - Future-proofing
#[no_link]
breaks some obscure cases - The
$crate
macro variable is accepted in fewer locations - Impls specifying extra region requirements beyond the trait they implement are rejected
- Enums may not be unsized. Unsized enums are intended to work but never have. For now they are forbidden.
- Enforce the shadowing restrictions from RFC 1560 for today's macros