Rust versions / 1.63
Rust release · Aug 11, 2022
Rust 1.63: what's new, what was stabilized
Short answerRust 1.63 was released on Aug 11, 2022: 46 newly stable APIs (array::from_fn, Box::into_pin, BinaryHeap::try_reserve, BinaryHeap::try_reserve_exact, ...); 2 compatibility notes that can affect existing code.
← Rust 1.62All versionsRust 1.64 →
46 APIs stabilized
array::from_fn, Box::into_pin, BinaryHeap::try_reserve, BinaryHeap::try_reserve_exact, OsString::try_reserve, OsString::try_reserve_exact, PathBuf::try_reserve, PathBuf::try_reserve_exact, Path::try_exists, Ref::filter_map, RefMut::filter_map, NonNull::<[T]>::len, ToOwned::clone_into, Ipv6Addr::to_ipv4_mapped, unix::io::AsFd, unix::io::BorrowedFd<'fd>, unix::io::OwnedFd, windows::io::AsHandle, windows::io::BorrowedHandle<'handle>, windows::io::OwnedHandle, windows::io::HandleOrInvalid, windows::io::HandleOrNull, windows::io::InvalidHandleError, windows::io::NullHandleError, windows::io::AsSocket, windows::io::BorrowedSocket<'handle>, windows::io::OwnedSocket, thread::scope, thread::Scope, thread::ScopedJoinHandle, array::from_ref, slice::from_ref, intrinsics::copy, intrinsics::copy_nonoverlapping, <*const T>::copy_to, <*const T>::copy_to_nonoverlapping, <*mut T>::copy_to, <*mut T>::copy_to_nonoverlapping, <*mut T>::copy_from, <*mut T>::copy_from_nonoverlapping, str::from_utf8, Utf8Error::error_len, Utf8Error::valid_up_to, Condvar::new, Mutex::new, RwLock::new
Can it break my build?
The release lists these compatibility notes. Most only affect rare code, but read them before you raise your toolchain in CI:
- [
#[link]attributes are now checked more strictly,][96885] which may introduce - [Rounding is now used when converting a float to a
Duration.][96051] The converted
Use it
rustup update stable # get the newest release
rustup install 1.63 # or exactly this one
rustup override set 1.63 # pin a project to itTo require at least this version from users of your crate, set rust-version = "1.63" under [package] in Cargo.toml. Cargo then refuses to build it on older compilers with a clear message, and with resolver 3 (the default on the 2024 edition, Rust 1.85+) it also prefers dependency versions that support it.
Full release notes
Language
- [Remove migrate borrowck mode for pre-NLL errors.][95565]
- [Modify MIR building to drop repeat expressions with length zero.][95953]
- [Remove label/lifetime shadowing warnings.][96296]
- [Allow explicit generic arguments in the presence of
impl Traitargs.][96868] - [Make
cenum_impl_drop_castwarnings deny-by-default.][97652] - [Prevent unwinding when
-C panic=abortis used regardless of declared ABI.][96959] - [lub: don't bail out due to empty binders.][97867]
Compiler
- [Stabilize the
bundlenative library modifier,][95818] also removing the deprecatedstatic-nobundlelinking kind. - [Add Apple WatchOS compile targets\*.][95243]
- [Add a Windows application manifest to rustc-main.][96737]
\* Refer to Rust's [platform support page][platform-support-doc] for more information on Rust's tiered platform support.
Libraries
- [Implement
Copy,Clone,PartialEqandEqforcore::fmt::Alignment.][94530] - [Extend
ptr::nullandnull_mutto all thin (including extern) types.][94954] - [
impl Read and Write for VecDeque<u8>.][95632] - [STD support for the Nintendo 3DS.][95897]
- [Use rounding in float to Duration conversion methods.][96051]
- [Make write/print macros eagerly drop temporaries.][96455]
- [Implement internal traits that enable
[OsStr]::join.][96881] - [Implement
Hashforcore::alloc::Layout.][97034] - [Add capacity documentation for
OsString.][97202] - [Put a bound on collection misbehavior.][97316]
- [Make
std::mem::needs_dropaccept?Sized.][97675] - [
impl Termination for Infallibleand then make theResultimpls ofTerminationmore generic.][97803] - [Document Rust's stance on
/proc/self/mem.][97837]
Stabilized APIs
- [
array::from_fn] - [
Box::into_pin] - [
BinaryHeap::try_reserve] - [
BinaryHeap::try_reserve_exact] - [
OsString::try_reserve] - [
OsString::try_reserve_exact] - [
PathBuf::try_reserve] - [
PathBuf::try_reserve_exact] - [
Path::try_exists] - [
Ref::filter_map] - [
RefMut::filter_map] - [
NonNull::<[T]>::len][NonNull::<slice>::len] - [
ToOwned::clone_into] - [
Ipv6Addr::to_ipv4_mapped] - [
unix::io::AsFd] - [
unix::io::BorrowedFd<'fd>] - [
unix::io::OwnedFd] - [
windows::io::AsHandle] - [
windows::io::BorrowedHandle<'handle>] - [
windows::io::OwnedHandle] - [
windows::io::HandleOrInvalid] - [
windows::io::HandleOrNull] - [
windows::io::InvalidHandleError] - [
windows::io::NullHandleError] - [
windows::io::AsSocket] - [
windows::io::BorrowedSocket<'handle>] - [
windows::io::OwnedSocket] - [
thread::scope] - [
thread::Scope] - [
thread::ScopedJoinHandle]
These APIs are now usable in const contexts:
- [
array::from_ref] - [
slice::from_ref] - [
intrinsics::copy] - [
intrinsics::copy_nonoverlapping] - [
<*const T>::copy_to] - [
<*const T>::copy_to_nonoverlapping] - [
<*mut T>::copy_to] - [
<*mut T>::copy_to_nonoverlapping] - [
<*mut T>::copy_from] - [
<*mut T>::copy_from_nonoverlapping] - [
str::from_utf8] - [
Utf8Error::error_len] - [
Utf8Error::valid_up_to] - [
Condvar::new] - [
Mutex::new] - [
RwLock::new]
Cargo
- [Stabilize the
--config pathcommand-line argument.][cargo/10755] - [Expose rust-version in the environment as
CARGO_PKG_RUST_VERSION.][cargo/10713]
Compatibility Notes
- [
#[link]attributes are now checked more strictly,][96885] which may introduce errors for invalid attribute arguments that were previously ignored. - [Rounding is now used when converting a float to a
Duration.][96051] The converted duration can differ slightly from what it was.
Internal Changes
These changes provide no direct user facing benefits, but represent significant improvements to the internals and overall performance of rustc and related tools.
Release notes from the Rust project's RELEASES.md (MIT or Apache-2.0); summaries above are ours.
Up next
Next releaseRust 1.64Released Sep 22, 2022.Read it next →Also worth your time
Did this answer your question?