Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit aae86cc

Browse files
committed
Rename hook.
1 parent 2e907aa commit aae86cc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clippy_utils/src/consts.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -710,7 +710,7 @@ fn field_of_struct<'tcx>(
710710
field: &Ident,
711711
) -> Option<mir::Const<'tcx>> {
712712
if let mir::Const::Val(result, ty) = result
713-
&& let Some(dc) = lcx.tcx.try_destructure_mir_constant_for_diagnostics(result, ty)
713+
&& let Some(dc) = lcx.tcx.try_destructure_mir_constant_for_user_output(result, ty)
714714
&& let Some(dc_variant) = dc.variant
715715
&& let Some(variant) = adt_def.variants().get(dc_variant)
716716
&& let Some(field_idx) = variant.fields.iter().position(|el| el.name == field.name)

0 commit comments

Comments
 (0)