Version 1.11.0 (2016-08-18)
Language
- Support nested
cfg_attr
attributes - Allow statement-generating braced macro invocations at the end of blocks
- Macros can be expanded inside of trait definitions
#[macro_use]
works properly when it is itself expanded from a macro
Stabilized APIs
BinaryHeap::append
BTreeMap::append
BTreeMap::split_off
BTreeSet::append
BTreeSet::split_off
f32::to_degrees
(in libcore - previously stabilized in libstd)f32::to_radians
(in libcore - previously stabilized in libstd)f64::to_degrees
(in libcore - previously stabilized in libstd)f64::to_radians
(in libcore - previously stabilized in libstd)Iterator::sum
Iterator::product
Cell::get_mut
RefCell::get_mut
Libraries
- The
thread_local!
macro supports multiple definitions in a single invocation, and can apply attributes Cow
implementsDefault
Wrapping
implements binary, octal, lower-hex and upper-hexDisplay
formatting- The range types implement
Hash
lookup_host
ignores unknown address typesassert_eq!
accepts a custom error message, likeassert!
does- The main thread is now called "main" instead of "<main>"
Cargo
- Disallow specifying features of transitive deps
- Add color support for Windows consoles
- Fix
harness = false
on[lib]
sections - Don't panic when
links
contains a '.' - Build scripts can emit warnings,
and
-vv
prints warnings for all crates. - Ignore file locks on OS X NFS mounts
- Don't warn about
package.metadata
keys. This provides room for expansion by arbitrary tools. - Add support for cdylib crate types
- Prevent publishing crates when files are dirty
- Don't fetch all crates on clean
- Propagate --color option to rustc
- Fix
cargo doc --open
on Windows - Improve autocompletion
- Configure colors of stderr as well as stdout
Performance
- Caching projections speeds up type check dramatically for some workloads
- The default
HashMap
hasher is SipHash 1-3 instead of SipHash 2-4 This hasher is faster, but is believed to provide sufficient protection from collision attacks. - Comparison of
Ipv4Addr
is 10x faster
Rustdoc
- Fix empty implementation section on some module pages
- Fix inlined renamed re-exports in import lists
- Fix search result layout for enum variants and struct fields
- Fix issues with source links to external crates
- Fix redirect pages for renamed re-exports
Tooling
- rustc is better at finding the MSVC toolchain
- When emitting debug info, rustc emits frame pointers for closures, shims and glue, as it does for all other functions
- rust-lldb warns about unsupported versions of LLDB
- Many more errors have been given error codes and extended explanations
- API documentation continues to be improved, with many new examples
Misc
- rustc no longer hangs when dependencies recursively re-export submodules
- rustc requires LLVM 3.7+
- The 'How Safe and Unsafe Interact' chapter of The Rustonomicon was rewritten
- rustc support 16-bit pointer sizes. No targets use this yet, but it works toward AVR support.
Compatibility Notes
const
s andstatic
s may not have unsized types- The new follow-set rules that place restrictions on
macro_rules!
in order to ensure syntax forward-compatibility have been enabled This was an amendment to RFC 550, and has been a warning since 1.10. cfg
attribute process has been refactored to fix various bugs. This causes breakage in some corner cases.