Eat dogfood

This commit is contained in:
Cameron Steffen
2021-03-30 14:59:59 -05:00
parent 5f887d09b8
commit 827d6aaad4
43 changed files with 471 additions and 534 deletions

View File

@@ -130,8 +130,8 @@ impl<'a, 'tcx> Visitor<'tcx> for NumericFallbackVisitor<'a, 'tcx> {
},
ExprKind::Struct(_, fields, base) => {
let ty = self.cx.typeck_results().expr_ty(expr);
if_chain! {
let ty = self.cx.typeck_results().expr_ty(expr);
if let Some(adt_def) = ty.ty_adt_def();
if adt_def.is_struct();
if let Some(variant) = adt_def.variants.iter().next();