Version | Change log |
Rust 1.82.0 Oct 17, 2024 |
Language: Don't make statement nonterminals match pattern nonterminals Patterns matching empty types can now be omitted in common cases Enforce supertrait outlives obligations when using trait impls addr_of(_mut)! macros and the newly stabilized &raw (const|mut) are now safe to use with all static items size_of_val_raw: for length 0 this is safe to call Reorder trait bound modifiers after for<...> binder in trait bounds Stabilize opaque type precise capturing (RFC 3617) Stabilize &raw const and &raw mut operators (RFC 2582) Stabilize unsafe extern blocks (RFC 3484) Stabilize nested field access in offset_of! Do not require T to be live when dropping [T; 0] Stabilize const operands in inline assembly Stabilize floating-point arithmetic in const fn Stabilize explicit opt-in to unsafe attributes Document NaN bit patterns guarantees Compiler: Promote riscv64gc-unknown-linux-musl to tier 2 Promote Mac Catalyst targets aarch64-apple-ios-macabi and x86_64-apple-ios-macabi to Tier 2, and ship them with rustup Add tier 3 NuttX based targets for RISC-V and ARM Add tier 3 powerpc-unknown-linux-muslspe target Improved diagnostics to explain why a pattern is unreachable The compiler now triggers the unreachable code warning properly for async functions that don't return/are -> ! Promote aarch64-apple-darwin to Tier 1 Add Trusty OS target aarch64-unknown-trusty and armv7-unknown-trusty as tier 3 targets Promote wasm32-wasip2 to Tier 2. Libraries: Generalize {Rc,Arc}::make_mut() to Path, OsStr, and CStr. Stabilized APIs: std::thread::Builder::spawn_unchecked std::str::CharIndices::offset std::option::Option::is_none_or [T]::is_sorted [T]::is_sorted_by [T]::is_sorted_by_key Iterator::is_sorted Iterator::is_sorted_by Iterator::is_sorted_by_key std::future::Ready::into_inner std::iter::repeat_n impl<T: Clone> DoubleEndedIterator for Take<Repeat<T>> impl<T: Clone> ExactSizeIterator for Take<Repeat<T>> impl<T: Clone> ExactSizeIterator |
Rust 1.81.0 Sep 5, 2024 |
Fix miscompilation in the jump threading MIR optimization when comparing floats Revert changes to the dead_code lint from 1.80.0 |
Rust 1.80.1 Aug 8, 2024 |
Language: Document maximum allocation size Allow zero-byte offsets and ZST read/writes on arbitrary pointers Support C23's variadics without a named parameter Stabilize exclusive_range_pattern feature Guarantee layout and ABI of Result in some scenarios Compiler: Update cc crate to v1.0.97 allowing additional spectre mitigations on MSVC targets Allow field reordering on types marked repr(packed(1)) Add a lint against never type fallback affecting unsafe code Disallow cast with trailing braced macro in let-else Expand for_loops_over_fallibles lint to lint on fallibles behind references. self-contained linker: retry linking without -fuse-ld=lld on CCs that don't support it Do not parse CVarArgs (...) as a type in trait bounds Improvements to LLDB formatting #124458 #124500 For the wasm32-wasip2 target default to PIC and do not use -fuse-ld=lld Add x86_64-unknown-linux-none as a tier 3 target Lint on foo.into_iter() resolving to &Box<[T]>: IntoIterator Libraries: Add size_of and size_of_val and align_of and align_of_val to the prelude Abort a process when FD ownership is violated io::Write::write_fmt: panic if the formatter fails when the stream does not fail Panic if PathBuf::set_extension would add a path separator Add assert_unsafe_precondition to unchecked_{add,sub,neg,mul,shl,shr} methods Update c_char on AIX to use the correct type offset_of! no longer returns a temporary Handle sigma in str.to_lowercase correctly Raise DEFAULT_MIN_STACK_SIZE to at least 64KiB Stabilized APIs: impl Default for Rc<CStr> impl Default for Rc<str> impl Default for Rc<[T]> impl Default for Arc<str> impl Default for Arc<CStr> impl Default for Arc<[T]> impl IntoIterator for Box<[T]> impl FromIterator<String> for Box<str> impl FromIterator<char> for Box<str> LazyCell LazyLock Duration::div_duration_f32 Duration::div_duration_f64 Option::take_if Seek::seek_relative BinaryHeap::as_slice NonNull::offset NonNull::byte_of |
Rust 1.79.0 Jul 19, 2024 |
Language: Stabilize inline const {} expressions. Prevent opaque types being instantiated twice with different regions within the same function. Stabilize WebAssembly target features that are in phase 4 and 5. Add the redundant_lifetimes lint to detect lifetimes which are semantically redundant. Stabilize the unnameable_types lint for public types that can't be named. Enable debuginfo in macros, and stabilize -C collapse-macro-debuginfo and #[collapse_debuginfo]. Propagate temporary lifetime extension into if and match expressions. Restrict promotion of const fn calls. Warn against refining impls of crate-private traits with refining_impl_trait lint. Stabilize associated type bounds (RFC 2289). Stabilize importing main from other modules or crates. Check return types of function types for well-formedness Rework impl Trait lifetime inference Change inductive trait solver cycles to be ambiguous Compiler: Define -C strip to only affect binaries, not artifacts like .pdb. Stabilize -Crelro-level for controlling runtime link hardening. Stabilize checking of cfg names and values at compile-time with --check-cfg. Note that this only stabilizes the compiler part, the Cargo part is still unstable in this release. Add aarch64-apple-visionos and aarch64-apple-visionos-sim tier 3 targets. Add riscv32ima-unknown-none-elf tier 3 target. Promote several Windows targets to tier 2: aarch64-pc-windows-gnullvm, i686-pc-windows-gnullvm, and x86_64-pc-windows-gnullvm. Refer to Rust's platform support page for more information on Rust's tiered platform support. Libraries: Implement FromIterator for (impl Default + Extend, impl Default + Extend). Implement {Div,Rem}Assign<NonZero<X>> on X. Document overrides of clone_from() in core/std. Link MSVC default lib in core. Caution against using transmute between pointers and integers. Enable frame pointers for the standard library. Stabilized APIs: {integer}::unchecked_add {integer}::unchecked_mul {integer}::unchecked_sub <[T]>: |
Rust 1.77.2 Apr 10, 2024 | |
Rust 1.77.1 Mar 29, 2024 | |
Rust 1.77.0 Mar 21, 2024 | |
Rust 1.76.0 Feb 13, 2024 | |
Rust 1.75.0 Dec 29, 2023 | |
Rust 1.73.0 Oct 6, 2023 |