Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
80 commits
Select commit Hold shift + click to select a range
73e35ee
Fix incorrect trailing comma suggested in no_accessible_fields
chenyukang Jan 18, 2026
0f786b9
ValTreeKind::Branch use List
spirali Feb 13, 2026
c5a6131
fix: use `ExprIsRead::Yes` for binary operator operands
Albab-Hasan Feb 16, 2026
85de83b
fix: use check_infer_with_mismatches in binop_lhs_never_place_diverge…
Albab-Hasan Feb 16, 2026
05cd01b
fix: verify NeverToAny adjustment in binop_lhs_never_place_diverges test
Albab-Hasan Feb 16, 2026
115bfdb
Suppress invalid suggestions in destructuring assignment
arferreira Feb 17, 2026
46ddd48
Changes after code review
spirali Feb 15, 2026
515d055
Update compiler/rustc_borrowck/src/diagnostics/move_errors.rs
arferreira Feb 18, 2026
c1b0b32
fix: verify NeverToAny adjustment on binop lhs never place
Albab-Hasan Feb 18, 2026
f4dcfa2
fix: offer block `.let` in ref-expr in match arm
A4-Tacks Feb 17, 2026
5ea0716
feat: offer destructure_struct_binding on self param
A4-Tacks Feb 20, 2026
14b3a40
Test updated
spirali Feb 23, 2026
05ab6d1
internal: Configure codecov
Wilfred Feb 17, 2026
cde693c
fix: Improve newline for make `match`, `if`, `while` etc
A4-Tacks Feb 27, 2026
f19a73c
build(deps-dev): bump minimatch from 3.1.2 to 3.1.5 in /editors/code
dependabot[bot] Feb 28, 2026
aa53530
fix: Fix wrong confiditon in `Visibility::min`
Veykril Feb 28, 2026
89573c1
Merge pull request #21725 from Veykril/push-skvpqzkooolm
Veykril Feb 28, 2026
a4c683f
fix: use compound assignment in binop_lhs_never_place_diverges test
Albab-Hasan Feb 28, 2026
ad7acd5
Merge pull request #21654 from Albab-Hasan/fix/binop-rhs-never-coercion
ChayimFriedman2 Feb 28, 2026
c9763e7
triagebot: roll rustfmt reviewers for in-tree rustfmt
jieyouxu Feb 28, 2026
747aa5b
Fix: use `FnAbi::Rust` for tuple struct/enum constructors and align `…
Albab-Hasan Mar 1, 2026
a9e35bc
Merge pull request #21722 from rust-lang/dependabot/npm_and_yarn/edit…
lnicola Mar 1, 2026
21674fe
fix: Fix wrong descend range for add_missing_match_arms
A4-Tacks Mar 1, 2026
7a81a8e
Prepare for merging from rust-lang/rust
invalid-email-address Mar 2, 2026
cbbd454
Merge ref 'e7d90c695a39' from rust-lang/rust
invalid-email-address Mar 2, 2026
1d89279
Format code
invalid-email-address Mar 2, 2026
debbabe
Merge pull request #21731 from rust-lang/rustc-pull
lnicola Mar 2, 2026
7bd3c42
internal: Define rules for LLMs
Wilfred Mar 2, 2026
02e1aea
Merge pull request #21728 from A4-Tacks/add-match-arms-descend-range
ChayimFriedman2 Mar 4, 2026
a64732c
Merge pull request #21726 from Albab-Hasan/fix/next-solver-is-rust
ChayimFriedman2 Mar 4, 2026
91c193d
Merge pull request #21719 from A4-Tacks/make-block-newline
ChayimFriedman2 Mar 4, 2026
4dc4e42
Merge pull request #21687 from A4-Tacks/destruct-self-param
ChayimFriedman2 Mar 4, 2026
2c69534
Release a new smol-str minor version with borsh fix
ChayimFriedman2 Mar 4, 2026
8454a15
Merge pull request #21743 from ChayimFriedman2/bump-smol-str
ChayimFriedman2 Mar 4, 2026
6b13e5e
Fix a bug in associated type lowering
ChayimFriedman2 Mar 4, 2026
560ec97
Merge pull request #21671 from A4-Tacks/postfix-tree-climbing
ChayimFriedman2 Mar 4, 2026
0f1a1ad
Only complain about uncanonicalized issue links
lnicola Mar 4, 2026
2129e09
Merge pull request #21746 from lnicola/triagebot-issue-links
lnicola Mar 4, 2026
312a764
Merge pull request #21745 from ChayimFriedman2/assoc-type-fixup
Veykril Mar 4, 2026
83bedb3
Allow never coercions in struct update syntax
ChayimFriedman2 Mar 4, 2026
b1eedb6
Merge pull request #21747 from ChayimFriedman2/never-upd-syn
ShoyuVanilla Mar 4, 2026
bd8c9f3
Do not use PostAnalysis TypingMode for IDE method resolution
ChayimFriedman2 Mar 4, 2026
8bfd981
When going to def on `?` on `Result` that goes through `From`, go to …
ChayimFriedman2 Mar 4, 2026
61fbc07
Merge pull request #21750 from ChayimFriedman2/method-res-typingmode
ShoyuVanilla Mar 5, 2026
e502782
Prepare for merging from rust-lang/rust
invalid-email-address Mar 5, 2026
3ef39ff
Merge ref 'f8704be04fe1' from rust-lang/rust
invalid-email-address Mar 5, 2026
43b6fa2
Merge pull request #21753 from rust-lang/rustc-pull
lnicola Mar 5, 2026
4343bc7
Add `has_pending` methods to `Incoming` and `Outgoing` in `lsp_server`
oeb25 Mar 5, 2026
d63bb88
Merge pull request #21752 from ChayimFriedman2/question-mark-conversion
Veykril Mar 5, 2026
a5c4f69
Merge pull request #21755 from oeb25/lsp-server-has-pending
Veykril Mar 5, 2026
1bd871f
Merge pull request #21732 from Wilfred/add_claude_rules
Veykril Mar 5, 2026
92845ed
Merge pull request #21660 from Wilfred/configure_codecov
Veykril Mar 5, 2026
07a3da1
Consider try blocks as block-like for overflowed expr
ia0 Mar 5, 2026
2093158
refactor: move `check_align` to `parse_alignment`
JayanAXHF Mar 5, 2026
f8998e9
as_slice removed
spirali Mar 5, 2026
06f959c
fix clippy on master
Shourya742 Mar 6, 2026
f2abae6
Merge pull request #21760 from Shourya742/2026-03-06-fix-clippy
ShoyuVanilla Mar 6, 2026
006929f
Tweak pre-release check for beta
lnicola Mar 6, 2026
80af448
Merge pull request #21763 from lnicola/lockfile-beta
lnicola Mar 6, 2026
a62c671
bootstrap.py: fix typo "parallle"
DanielEScherzer Mar 6, 2026
6a950e7
add wasm64 to sync::Once and thread_parking atomics cfg guard
Trivo25 Feb 27, 2026
cb66c85
Preserve parentheses around Fn trait bounds in pretty printer
aytey Mar 6, 2026
0fd3ac4
libcore float tests: replace macro shadowing by const-compatible macro
RalfJung Mar 6, 2026
1190845
Do not emit ConstEvaluatable goals if type-const
JohnTitor Feb 3, 2026
ca2178d
add UI regression test for offset_of! recovery
TaKO8Ki Mar 6, 2026
ed12fe8
fix ICE in offset_of! error recovery
TaKO8Ki Mar 6, 2026
e62f17c
use try_from_target_usize instead of try_from_uint
TaKO8Ki Mar 6, 2026
92e29c1
Rollup merge of #153466 - lnicola:sync-from-ra, r=lnicola
JonathanBrouwer Mar 6, 2026
f5b21aa
Rollup merge of #151280 - chenyukang:yukang-fix-149787, r=estebank
JonathanBrouwer Mar 6, 2026
5f070f9
Rollup merge of #152593 - spirali:valtreekind-list, r=lcnr
JonathanBrouwer Mar 6, 2026
4dc48ac
Rollup merge of #153174 - Trivo25:fix-wasm64-sync-cfg, r=joboet
JonathanBrouwer Mar 6, 2026
a55f002
Rollup merge of #153485 - RalfJung:float-macros-const, r=tgross35
JonathanBrouwer Mar 6, 2026
798ceb2
Rollup merge of #153495 - TaKO8Ki:fix-153236-offset-of-recovery, r=pe…
JonathanBrouwer Mar 6, 2026
14ef470
Rollup merge of #152040 - JohnTitor:issue-151631, r=BoxyUwU
JonathanBrouwer Mar 6, 2026
404b208
Rollup merge of #152741 - arferreira:fix-invalid-suggestions-destruct…
JonathanBrouwer Mar 6, 2026
fb6afe7
Rollup merge of #153189 - JayanAXHF:refactor/check_attrs_reftor_1, r=…
JonathanBrouwer Mar 6, 2026
f899a62
Rollup merge of #153230 - jieyouxu:rustfmt-reviewers-for-rustfmt, r=y…
JonathanBrouwer Mar 6, 2026
a24bf90
Rollup merge of #153445 - ia0:overflow_try, r=ytmimi
JonathanBrouwer Mar 6, 2026
6d8ed5e
Rollup merge of #153476 - DanielEScherzer:patch-2, r=bjorn3
JonathanBrouwer Mar 6, 2026
5d3972a
Rollup merge of #153483 - aytey:dyn_paren_impl_fn_return, r=fmease
JonathanBrouwer Mar 6, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion compiler/rustc_ast_pretty/src/pprust/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1415,6 +1415,9 @@ impl<'a> State<'a> {
}

fn print_poly_trait_ref(&mut self, t: &ast::PolyTraitRef) {
if let ast::Parens::Yes = t.parens {
self.popen();
}
self.print_formal_generic_params(&t.bound_generic_params);

let ast::TraitBoundModifiers { constness, asyncness, polarity } = t.modifiers;
Expand All @@ -1437,7 +1440,10 @@ impl<'a> State<'a> {
}
}

self.print_trait_ref(&t.trait_ref)
self.print_trait_ref(&t.trait_ref);
if let ast::Parens::Yes = t.parens {
self.pclose();
}
}

fn print_stmt(&mut self, st: &ast::Stmt) {
Expand Down
50 changes: 31 additions & 19 deletions compiler/rustc_attr_parsing/src/attributes/repr.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use rustc_abi::Align;
use rustc_abi::{Align, Size};
use rustc_ast::{IntTy, LitIntType, LitKind, UintTy};
use rustc_hir::attrs::{IntType, ReprAttr};

Expand Down Expand Up @@ -229,7 +229,7 @@ fn parse_repr_align<S: Stage>(
return None;
};

match parse_alignment(&lit.kind) {
match parse_alignment(&lit.kind, cx) {
Ok(literal) => Some(match align_kind {
AlignKind::Packed => ReprAttr::ReprPacked(literal),
AlignKind::Align => ReprAttr::ReprAlign(literal),
Expand All @@ -248,23 +248,35 @@ fn parse_repr_align<S: Stage>(
}
}

fn parse_alignment(node: &LitKind) -> Result<Align, &'static str> {
if let LitKind::Int(literal, LitIntType::Unsuffixed) = node {
// `Align::from_bytes` accepts 0 as an input, check is_power_of_two() first
if literal.get().is_power_of_two() {
// Only possible error is larger than 2^29
literal
.get()
.try_into()
.ok()
.and_then(|v| Align::from_bytes(v).ok())
.ok_or("larger than 2^29")
} else {
Err("not a power of two")
}
} else {
Err("not an unsuffixed integer")
fn parse_alignment<S: Stage>(
node: &LitKind,
cx: &AcceptContext<'_, '_, S>,
) -> Result<Align, String> {
let LitKind::Int(literal, LitIntType::Unsuffixed) = node else {
return Err("not an unsuffixed integer".to_string());
};

// `Align::from_bytes` accepts 0 as a valid input,
// so we check if its a power of two first
if !literal.get().is_power_of_two() {
return Err("not a power of two".to_string());
}
// lit must be < 2^29
let align = literal
.get()
.try_into()
.ok()
.and_then(|a| Align::from_bytes(a).ok())
.ok_or("larger than 2^29".to_string())?;

// alignment must not be larger than the pointer width (`isize::MAX`)
let max = Size::from_bits(cx.sess.target.pointer_width).signed_int_max() as u64;
if align.bytes() > max {
return Err(format!(
"alignment larger than `isize::MAX` bytes ({max} for the current target)"
));
}
Ok(align)
}

/// Parse #[align(N)].
Expand Down Expand Up @@ -294,7 +306,7 @@ impl RustcAlignParser {
return;
};

match parse_alignment(&lit.kind) {
match parse_alignment(&lit.kind, cx) {
Ok(literal) => self.0 = Ord::max(self.0, Some((literal, cx.attr_span))),
Err(message) => {
cx.emit_err(session_diagnostics::InvalidAlignmentValue {
Expand Down
6 changes: 3 additions & 3 deletions compiler/rustc_attr_parsing/src/session_diagnostics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -227,12 +227,12 @@ pub(crate) struct InvalidReprAlignNeedArg {

#[derive(Diagnostic)]
#[diag("invalid `repr({$repr_arg})` attribute: {$error_part}", code = E0589)]
pub(crate) struct InvalidReprGeneric<'a> {
pub(crate) struct InvalidReprGeneric {
#[primary_span]
pub span: Span,

pub repr_arg: String,
pub error_part: &'a str,
pub error_part: String,
}

#[derive(Diagnostic)]
Expand Down Expand Up @@ -479,7 +479,7 @@ pub(crate) struct InvalidTarget {
pub(crate) struct InvalidAlignmentValue {
#[primary_span]
pub span: Span,
pub error_part: &'static str,
pub error_part: String,
}

#[derive(Diagnostic)]
Expand Down
71 changes: 53 additions & 18 deletions compiler/rustc_borrowck/src/diagnostics/move_errors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use rustc_middle::mir::*;
use rustc_middle::ty::{self, Ty, TyCtxt};
use rustc_mir_dataflow::move_paths::{LookupResult, MovePathIndex};
use rustc_span::def_id::DefId;
use rustc_span::{BytePos, ExpnKind, MacroKind, Span};
use rustc_span::{BytePos, ExpnKind, MacroKind, Span, sym};
use rustc_trait_selection::error_reporting::traits::FindExprBySpan;
use rustc_trait_selection::infer::InferCtxtExt;
use tracing::debug;
Expand Down Expand Up @@ -700,14 +700,14 @@ impl<'infcx, 'tcx> MirBorrowckCtxt<'_, 'infcx, 'tcx> {
binds_to.sort();
binds_to.dedup();

self.add_move_error_details(err, &binds_to);
self.add_move_error_details(err, &binds_to, &[]);
}
}
GroupedMoveError::MovesFromValue { mut binds_to, .. } => {
binds_to.sort();
binds_to.dedup();
self.add_move_error_suggestions(err, &binds_to);
self.add_move_error_details(err, &binds_to);
let desugar_spans = self.add_move_error_suggestions(err, &binds_to);
self.add_move_error_details(err, &binds_to, &desugar_spans);
}
// No binding. Nothing to suggest.
GroupedMoveError::OtherIllegalMove { ref original_path, use_spans, .. } => {
Expand Down Expand Up @@ -823,7 +823,7 @@ impl<'infcx, 'tcx> MirBorrowckCtxt<'_, 'infcx, 'tcx> {
}
}

fn add_move_error_suggestions(&self, err: &mut Diag<'_>, binds_to: &[Local]) {
fn add_move_error_suggestions(&self, err: &mut Diag<'_>, binds_to: &[Local]) -> Vec<Span> {
/// A HIR visitor to associate each binding with a `&` or `&mut` that could be removed to
/// make it bind by reference instead (if possible)
struct BindingFinder<'tcx> {
Expand All @@ -843,6 +843,8 @@ impl<'infcx, 'tcx> MirBorrowckCtxt<'_, 'infcx, 'tcx> {
ref_pat_for_binding: Vec<(Span, Option<&'tcx hir::Pat<'tcx>>)>,
/// Output: ref patterns that can't be removed straightforwardly
cannot_remove: FxHashSet<HirId>,
/// Output: binding spans from destructuring assignment desugaring
desugar_binding_spans: Vec<Span>,
}
impl<'tcx> Visitor<'tcx> for BindingFinder<'tcx> {
type NestedFilter = rustc_middle::hir::nested_filter::OnlyBodies;
Expand Down Expand Up @@ -883,16 +885,38 @@ impl<'infcx, 'tcx> MirBorrowckCtxt<'_, 'infcx, 'tcx> {
}

if let hir::PatKind::Binding(_, _, ident, _) = p.kind {
// the spans in `binding_spans` encompass both the ident and binding mode
if let Some(&bind_sp) =
self.binding_spans.iter().find(|bind_sp| bind_sp.contains(ident.span))
{
self.ref_pat_for_binding.push((bind_sp, self.ref_pat));
// Skip synthetic bindings from destructuring assignment desugaring
// These have name `lhs` and their parent is a `LetStmt` with
// `LocalSource::AssignDesugar`
let dominated_by_desugar_assign = ident.name == sym::lhs
&& self.tcx.hir_parent_iter(p.hir_id).any(|(_, node)| {
matches!(
node,
hir::Node::LetStmt(&hir::LetStmt {
source: hir::LocalSource::AssignDesugar,
..
})
)
});

if dominated_by_desugar_assign {
if let Some(&bind_sp) =
self.binding_spans.iter().find(|bind_sp| bind_sp.contains(ident.span))
{
self.desugar_binding_spans.push(bind_sp);
}
} else {
// we've encountered a binding that we're not reporting a move error for.
// we don't want to change its type, so don't remove the surrounding `&`.
if let Some(ref_pat) = self.ref_pat {
self.cannot_remove.insert(ref_pat.hir_id);
// the spans in `binding_spans` encompass both the ident and binding mode
if let Some(&bind_sp) =
self.binding_spans.iter().find(|bind_sp| bind_sp.contains(ident.span))
{
self.ref_pat_for_binding.push((bind_sp, self.ref_pat));
} else {
// we've encountered a binding that we're not reporting a move error for.
// we don't want to change its type, so don't remove the surrounding `&`.
if let Some(ref_pat) = self.ref_pat {
self.cannot_remove.insert(ref_pat.hir_id);
}
}
}
}
Expand All @@ -913,10 +937,10 @@ impl<'infcx, 'tcx> MirBorrowckCtxt<'_, 'infcx, 'tcx> {
binding_spans.push(bind_to.source_info.span);
}
}
let Some(pat_span) = pat_span else { return };
let Some(pat_span) = pat_span else { return Vec::new() };

let tcx = self.infcx.tcx;
let Some(body) = tcx.hir_maybe_body_owned_by(self.mir_def_id()) else { return };
let Some(body) = tcx.hir_maybe_body_owned_by(self.mir_def_id()) else { return Vec::new() };
let typeck_results = self.infcx.tcx.typeck(self.mir_def_id());
let mut finder = BindingFinder {
typeck_results,
Expand All @@ -928,6 +952,7 @@ impl<'infcx, 'tcx> MirBorrowckCtxt<'_, 'infcx, 'tcx> {
has_adjustments: false,
ref_pat_for_binding: Vec::new(),
cannot_remove: FxHashSet::default(),
desugar_binding_spans: Vec::new(),
};
finder.visit_body(body);

Expand All @@ -952,9 +977,15 @@ impl<'infcx, 'tcx> MirBorrowckCtxt<'_, 'infcx, 'tcx> {
for (span, msg, suggestion) in suggestions {
err.span_suggestion_verbose(span, msg, suggestion, Applicability::MachineApplicable);
}
finder.desugar_binding_spans
}

fn add_move_error_details(&self, err: &mut Diag<'_>, binds_to: &[Local]) {
fn add_move_error_details(
&self,
err: &mut Diag<'_>,
binds_to: &[Local],
desugar_spans: &[Span],
) {
for (j, local) in binds_to.iter().enumerate() {
let bind_to = &self.body.local_decls[*local];
let binding_span = bind_to.source_info.span;
Expand All @@ -968,7 +999,11 @@ impl<'infcx, 'tcx> MirBorrowckCtxt<'_, 'infcx, 'tcx> {
if binds_to.len() == 1 {
let place_desc = self.local_name(*local).map(|sym| format!("`{sym}`"));

if let Some(expr) = self.find_expr(binding_span) {
if !desugar_spans.contains(&binding_span)
&& let Some(expr) = self.find_expr(binding_span)
{
// The binding_span doesn't correspond to a let binding desugaring
// and is an expression where calling `.clone()` would be valid.
let local_place: PlaceRef<'tcx> = (*local).into();
self.suggest_cloning(err, local_place, bind_to.ty, expr, None);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1557,7 +1557,7 @@ fn s_nan() -> Float {
name: exp,
attrs: {
Expand All @@ -28,7 +28,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1578,7 +1578,7 @@ fn s_nan() -> Float {
name: exp2,
attrs: {
Expand All @@ -37,7 +37,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1598,7 +1598,7 @@ fn s_nan() -> Float {
name: ln,
attrs: {
Expand All @@ -46,7 +46,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1620,7 +1620,7 @@ fn s_nan() -> Float {
name: log,
attrs: {
Expand All @@ -55,7 +55,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1645,7 +1645,7 @@ fn s_nan() -> Float {
name: log2,
attrs: {
Expand All @@ -64,7 +64,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1668,7 +1668,7 @@ fn s_nan() -> Float {
name: log10,
attrs: {
Expand All @@ -73,7 +73,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1692,7 +1692,7 @@ fn s_nan() -> Float {
name: asinh,
attrs: {
Expand All @@ -82,7 +82,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1725,7 +1725,7 @@ fn s_nan() -> Float {
name: acosh,
attrs: {
Expand All @@ -91,7 +91,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1753,7 +1753,7 @@ fn s_nan() -> Float {
name: atanh,
attrs: {
Expand All @@ -100,7 +100,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1779,7 +1779,7 @@ fn s_nan() -> Float {
name: gamma,
attrs: {
Expand All @@ -109,7 +109,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -1814,7 +1814,7 @@ fn s_nan() -> Float {
name: ln_gamma,
attrs: {
Expand All @@ -118,7 +118,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
@@ -2027,7 +2027,7 @@ fn s_nan() -> Float {
attrs: {
// FIXME(f16_f128): add math tests when available
Expand All @@ -127,7 +127,7 @@ index c61961f8584..d7b4fa20322 100644
+ f16: #[cfg(false)], // FIXME(rust-lang/rustc_codegen_cranelift#1622)
f128: #[cfg(all(not(miri), target_has_reliable_f128_math))],
},
test<Float> {
test {
--
2.50.1

2 changes: 1 addition & 1 deletion compiler/rustc_const_eval/src/const_eval/valtrees.rs
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,7 @@ fn valtree_into_mplace<'tcx>(
Some(variant_idx),
)
}
_ => (place.clone(), branches, None),
_ => (place.clone(), branches.as_slice(), None),
};
debug!(?place_adjusted, ?branches);

Expand Down
Loading
Loading