You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Dynamically-sized-type coercions allow smart pointer types like Rc to contain types without a fixed size, arrays and trait objects, finally enabling use of Rc<[T]> and completing the implementation of DST.
Parallel codegen is now working again, which can substantially speed up large builds in debug mode; It also gets another ~33% speedup when bootstrapping on a 4 core machine (using 8 jobs). It's not enabled by default, but will be "in the near future". It can be activated with the -C codegen-units=N flag to rustc.
Benchmark compilations are showing a 30% improvement in bootstrapping over 1.1.
Breaking Changes
The to_uppercase and to_lowercase methods on char now do unicode case mapping, which is a previously-planned change in behavior and considered a bugfix.
mem::align_of now specifies the minimum alignment for T, which is usually the alignment programs are interested in, and the same value reported by clang's alignof. mem::min_align_of is deprecated. This is not known to break real code.
Associated type defaults are now behind the associated_type_defaults feature gate. In 1.1 associated type defaults did not work, but could be mentioned syntactically. As such this breakage has minimal impact.
Language
Patterns with ref mut now correctly invoke DerefMut when matching against dereferenceable values.
Libraries
The Extend trait, which grows a collection from an iterator, is implemented over iterators of references, for String, Vec, LinkedList, VecDeque, EnumSet, BinaryHeap, VecMap, BTreeSet and BTreeMap. RFC.
The iter::once function returns an iterator that yields a single element, and iter::empty returns an iterator that yields no elements.
The matches and rmatches methods on str return iterators over substring matches.
The {:#?} formatting specifier displays the alternate, pretty-printed form of the Debug formatter. This feature was actually introduced prior to 1.0 with little fanfare.
str has new to_uppercase and to_lowercase methods that convert case, following Unicode case mapping.
It is now easier to handle poisoned locks. The PoisonError type, returned by failing lock operations, exposes into_inner, get_ref, and get_mut, which all give access to the inner lock guard, and allow the poisoned lock to continue to operate. The is_poisoned method of RwLock and Mutex can poll for a poisoned lock without attempting to take the lock.
On Unix the FromRawFd trait is implemented for Stdio, and AsRawFd for ChildStdin, ChildStdout, ChildStderr. On Windows the FromRawHandle trait is implemented for Stdio, and AsRawHandle for ChildStdin, ChildStdout, ChildStderr.
io::ErrorKind has a new variant, InvalidData, which indicates malformed input.
Misc
rustc employs smarter heuristics for guessing at typos.