Recent Releases
1.99.0
2026-10-01
1.99.0
2026-10-01
Merged PRs:
- Tracking issue for release notes of #162820: [beta] Backports for compiler-builtins (1d ago)
- Tracking issue for release notes of #159222: semicolon_in_expressions_from_macros: Lint on non-local macros too (14d ago)
- core: implement FusedIterator for StepBy (34d ago)
- Enable
static_position_independent_executableson all gnu targets (35d ago) - Tracking issue for release notes of #158447: Shallow resolve ty and const vars to their root vars, attempt 2 (35d ago)
- +29 more
1.98.1
2026-09-03
1.98.0
2026-08-20
1.98.0
2026-08-20
- Allow shortening lifetime of
&mutwhen unsize-coercing, even in an invariant position. For example, you can now coerce aCell<&'long mut i32>to aCell<&'short mut dyn Send>. Such shortenings were already previously allowed when coercing a&mutto a&, or coercing a&to a&. - Add deny-by-default
invalid_runtime_symbol_definitionslint and warn-by-defaultsuspicious_runtime_symbol_definitionslint - The lints currently specifically targets
coreruntime symbols likememcmp,memset,strlen, ... and is planned to be expanded in the next few releases. - Add warn-by-default
c_void_returnslint to checkcore::ffi::c_voidas a return type
- Change
Location<'_>lifetime to'staticinPanic[Hook]Info - Document panic in
RangeInclusive::from(legacy::RangeInclusive) - Document that
ManuallyDrop'sBoxinteraction has been fixed - Stabilize LoongArch CRC Intrinsics
- The
derivemacro is available at{core,std}::derive. This was previously unintentionally stabilized in 1.96, but is now explicitly accepted as a stabilized API. - Please note that the MSRV for
{core,std}::derivewill be 1.96, and not 1.98. str::substr_range[T]::subslice_rangecore::fmt::NumBuffer<{integer}>::format_intoSend/Sync for std::process::CommandArgs{fN}::algebraic_add{fN}::algebraic_sub{fN}::algebraic_mul{fN}::algebraic_div{fN}::algebraic_remNonZero<{integer}>::from_str_radixString::from_utf16leString::from_utf16le_lossyString::from_utf16beString::from_utf16be_lossy[T]::strip_circumfixstr::strip_circumfixAtomic::from_mut Atomic::get_mut_slice Atomic::from_mut_slice std::range::legacy
- If fully elided, lifetime bounds of trait object types may now resolve differently or even get rejected in very specific niche scenarios
- Error in more cases of ambiguous imports
- Switch the destructors implementation for thread locals on Windows to use Fiber Local Storage (FLS)
- Convert some cases of the
ambiguous_glob_importslint into a hard error - Where-bounds of the form
Type = TypeandType == Typeare no longer syntactically allowed - Ensure Send/Sync is not implemented for std::env::Vars{,Os}
- Fix that in some attributes, arguments were not properly rejected
repr(transparent)is now more strict about which fields have "trivial" layout and hence can be ignored:repr(C)types, types with private fields, and#[non_exhaustive]types are no longer considered "trivial"- Correctly check whether types have equal size in
transmute()when somereprattributes are involved. - More characters are escaped when printing strings and chars
- Implement fast path for
derive(PartialOrd)when derivingOrd - Add temporary scope to
assert_eqandassert_ne - Closed a hole in the pattern matching structural equality check, preventing cases where a match of a constant would be allowed, despite disagreeing with a manually written
PartialEqimplementation, when aderive(PartialEq)implementation for that type also exists. - On Emscripten the WASM exception handling ABI is now unconditionally used The
-Zemscripten-wasm-eh=falseflag to switch back to JS exceptions has been removed. - The UNSAFE_CODE lint is now consistently emitted for all unsafe attributes
- Solaris: remove
File::lockimplementation, it has the wrong semantics (return "unsupported" instead) - Windows-gnu targets now specify baseline tools versions
- rustfmt now discovers module files that are defined in
cfg_select!
1.97.1
2026-07-16
1.97.0
2026-07-09
1.97.0
2026-07-09
- Consider
ResultandControlFlowto be equivalent toTfor must use lint - Add allow-by-default
dead_code_pub_in_binarylint for unused pub items in binary crates - Stabilize the
div32,lam-bh,lamcas,ld-seq-saandscqtarget features - Stabilize
cfg(target_has_atomic_primitive_alignment) - Allow trailing
selfin imports in more cases
Default for RepeatNCopy for ffi::FromBytesUntilNulErrorSend for std::fs::Fileon UEFI<{integer}>::isolate_highest_one<{integer}>::isolate_lowest_one<{integer}>::highest_one<{integer}>::lowest_one<{integer}>::bit_widthNonZero<{integer}>::isolate_highest_oneNonZero<{integer}>::isolate_lowest_oneNonZero<{integer}>::highest_oneNonZero<{integer}>::lowest_oneNonZero<{integer}>::bit_widthchar::is_control
- Stabilize
build.warningsconfig. This controls how lint warnings from local packages are treated. Useful for enforcing a warning-free build in CI, replacing-Dwarnings. docs - Stabilize
resolver.lockfile-pathconfig. This allows specifying the path to the lockfile to use when resolving dependencies. Useful when working with read-only source directories. docs - cargo-clean: Error when
--target-dirdoesn't look like a Cargo target directory. This prevents accidental deletion of non-target directories. - Add
-mshorthand for--manifest-path - Remove
curldependency fromcrates-iocrate
- Emit a future-compatibility warning when relying on
f32: From<{float}>to constrain{float} - Rust will use the v0 symbol mangling scheme by default. This may cause some tools (such as debuggers or profilers, especially with old versions) to fail to demangle symbols emitted by Rust. It may also cause the formatting of text in backtraces to change.
- Prevent deref coercions in
pin!, in order to prevent unsoundness. The most likely case where this might impact users is: writingpin!(x)wherexhas type&mut Twill now always correctly produce a value of typePin<&mut &mut T>, instead of sometimes allowing a coercion that produces a value of typePin<&mut T>. This coercion was previously incorrectly allowed since Rust 1.88.0. - Deprecate
std::charconstants and functions - Warn on linker output by default
- Remove hidden
f64methods which have been deprecated since 1.0 - report the
varargs_without_patternlint in deps - Forbid passing generic arguments to module path segments even if the module reexports a generic enum variant
- Error on invalid macho
link_sectionspecifier - The encoding of certain
enums have changed. This is not a breaking change, as it only applies toenums without layout guarantees, but is noted here as we've seen people impacted from having made assumptions about the layout algorithm. - Error on
#[export_name = "..."]where the name is empty - Syntactically reject tuple index shorthands in struct patterns
- validate
#[link_name = "..."]&#[link(name = "...")]parameters - On Windows, after calling
shutdownon a socket to shut down the write side, attempting to write to the socket will now produce aBrokenPipeerror rather thanOther. MapWSAESHUTDOWNtoio::ErrorKind::BrokenPipe
1.96.1
2026-06-30
1.96.0
2026-05-28
1.96.0
2026-05-28
- Allow passing
exprmetavariable tocfg - Always coerce never types in tuple expressions
- Avoid incorrect inference guidance of function arguments in rare cases
- Support s390x vector registers in inline assembly
- Allow using constants of type
ManuallyDropas patterns (fixing a regression introduced in 1.94.0)
- Support iterating over ranges of
NonZerointegers - refactor 'valid for read/write' definition: exclude null; add that as an exception on individual methods instead
- Fix SGX delayed host lookup via ToSocketAddr
assert_matches!debug_assert_matches!Fromfor AssertUnwindSafe Fromfor LazyCell Fromfor LazyLock core::range::RangeToInclusivecore::range::RangeToInclusiveItercore::range::RangeFromcore::range::RangeFromItercore::range::Rangecore::range::RangeIter
- Allow a dependency to specify both a git repository and an alternate registry. Just like with crates.io, the git repository will be used locally, but the registry version will be used when published.
- Added
target.'cfg(..)'.rustdocflagssupport in configuration. - Fixed CVE-2026-5222 and CVE-2026-5223.
- Fix layout of
#[repr(Int)]enums in some edge cases involving fields of uninhabited zero-sized types - Prevent unsize-coercing into
PinwhereFoodoesn't implementDeref. Some such coercions were previously allowed, but produce a type with no useful public API. - rustc: Stop passing
--allow-undefinedon wasm targets - Gate the accidentally stabilized
#![reexport_test_harness_main]attribute - Error on return-position-impl-trait-in-traits whose types are too private
- Report the
uninhabited_staticlint in dependencies and make it deny-by-default - Distributed builds now contain non-split debuginfo for windows-gnu
- Check const generic arguments are correctly typed in more positions
- Remove
-Csoft-float - Importing structs with
::{self [as name]}, e.g.,struct S {}; use S::{self as Other};, is now no longer permitted because{self}imports require a module parent. - For
export_name,link_name, andlink_sectionattributes, if multiple of the same attribute is present, the first one now takes precedence. - Update the minimum external LLVM to 21
- On
avrtargets, C'sdoubletype is 32-bit by default, so changec_doubletof32onavrtargets to match. This is a breaking change, but necessary to makec_doublematch C's double. BTreeMap::append()was optimized, which may now cause panics for types with incorrectOrdimpls
- Deprecation notes are now rendered like any other documentation. Previously they used the css
white-space: pre-wrap;property and stripped anyelements from the rendered html, however this caused issues and unintuitive behavior. The new behavior should be more predictable, however some multi-line deprecation notes will now be rendered as as single lines. If this is undesirable, you can use the standard markdown method of forcing a linebreak, which is two spaces followed by a newline ("\n"). - Don't emit rustdoc
missing_doc_code_exampleslint on impl items - Separate methods and associated functions in sidebar
- JSON targets:
aarch64softfloat targets now have to haverustc_abiset to"softfloat" - target specs: stricter checks for LLVM ABI values, and correlate that with
cfg(target_abi)
1.95.0
2026-04-16
1.95.0
2026-04-16
- Stabilize
if letguards on match arms irrefutable_let_patternslint no longer lints on let chains- Support importing path-segment keywords with renaming
- Stabilize inline assembly for PowerPC and PowerPC64
- const-eval: be more consistent in the behavior of padding during typed copies
- Const blocks are no longer evaluated to determine if expressions involving fallible operations can implicitly be constant-promoted.. Expressions whose ability to implicitly be promoted would depend on the result of a const block are no longer implicitly promoted.
- Make operational semantics of pattern matching independent of crate and module
thread::scope: document how join interacts with TLS destructors- Speed up
str::containson aarch64 targets withneontarget feature enabled by default MaybeUninit<[T; N]>: From<[MaybeUninit; N]> MaybeUninit<[T; N]>: AsRef<[MaybeUninit; N]> MaybeUninit<[T; N]>: AsRef<[MaybeUninit]> MaybeUninit<[T; N]>: AsMut<[MaybeUninit; N]> MaybeUninit<[T; N]>: AsMut<[MaybeUninit]> [MaybeUninit; N]: From > Cell<[T; N]>: AsRef<[Cell; N]> Cell<[T; N]>: AsRef<[Cell]> Cell<[T]>: AsRef<[Cell]> bool: TryFrom<{integer}>AtomicPtr::updateAtomicPtr::try_updateAtomicBool::updateAtomicBool::try_updateAtomicIn::updateAtomicIn::try_updateAtomicUn::updateAtomicUn::try_updatecfg_select!mod core::rangecore::range::RangeInclusivecore::range::RangeInclusiveItercore::hint::cold_path<*const T>::as_ref_unchecked<*mut T>::as_ref_unchecked<*mut T>::as_mut_uncheckedVec::push_mutVec::insert_mutVecDeque::push_front_mutVecDeque::push_back_mutVecDeque::insert_mutLinkedList::push_front_mutLinkedList::push_back_mutLayout::dangling_ptrLayout::repeatLayout::repeat_packedLayout::extend_packedfmt::from_fnControlFlow::is_breakControlFlow::is_continue
- Array coercions may now result in less inference constraints than before
- Importing
$cratewithout renaming, i.e.use $crate::{self};, is now no longer permitted due to stricter error checking forselfimports. - const-eval: be more consistent in the behavior of padding during typed copies.
- A future-incompatibility warning lint
ambiguous_glob_imported_traitsis now reported when using an ambiguously glob imported trait - Check lifetime bounds of types mentioning only type parameters
- Report more visibility-related ambiguous import errors
- Deprecate
Eq::assert_receiver_is_total_eqand emit future compatibility warnings on manual impls - powerpc64: Use the ELF ABI version set in target spec instead of guessing (fixes the ELF ABI used by the OpenBSD target)
- Matching on a
#[non_exhaustive]enum now reads the discriminant, even if the enum has only one variant. This can cause closures to capture values that they previously wouldn't. mut refandmut ref mutpatterns, part of the unstable Match Ergonomics 2024 RFC, were accidentally allowed on stable within struct pattern field shorthand. These patterns are now correctly feature-gated as unstable in this position.- Add future-compatibility warning for derive helper attributes which conflict with built-in attributes
- JSON target specs have been destabilized and now require
-Z unstable-optionsto use. Previously, they could not be used without the standard library, which has no stable build mechanism. In preparation for thebuild-stdproject adding that support, JSON target specs are being proactively gated to ensure they remain unstable even ifbuild-stdis stabilized. Cargo now includes the-Z json-target-specCLI flag to automatically pass-Z unstable-optionsto the compiler when needed. See #150151, #151534, and rust-lang/cargo#16557. - The arguments of
#[feature]attributes on invalid targets are now checked
- Promote
powerpc64-unknown-linux-muslto Tier 2 with host tools - Promote
aarch64-apple-tvosto Tier 2 - Promote
aarch64-apple-tvos-simto Tier 2 - Promote
aarch64-apple-watchosto Tier 2 - Promote
aarch64-apple-watchos-simto Tier 2 - Promote
aarch64-apple-visionosto Tier 2 - Promote
aarch64-apple-visionos-simto Tier 2 - In search results, rank unstable items lower
- Add new "hide deprecated items" setting in rustdoc
- Update to LLVM 22
Need Help? We've Got Answers
Explore our most commonly asked questions.
Data is updated by a GitHub Action. As long as GitHub stays up, it's scheduled every hour.
Contribute on GitHub
version.rs is open source. Check the repo to see how data is fetched and the site is built.