1
Fork 0

Auto merge of #80843 - Mark-Simulacrum:fmt-bump, r=petrochenkov

Bump rustfmt version
This commit is contained in:
bors 2021-02-02 14:52:53 +00:00
commit b81f5811f9
30 changed files with 224 additions and 164 deletions

View file

@ -496,14 +496,15 @@ impl<'o, 'tcx> dyn AstConv<'tcx> + 'o {
) -> bool {
let explicit = !seg.infer_args;
let impl_trait = generics.params.iter().any(|param| {
matches!(param.kind, ty::GenericParamDefKind::Type {
synthetic:
Some(
hir::SyntheticTyParamKind::ImplTrait
| hir::SyntheticTyParamKind::FromAttr,
matches!(
param.kind,
ty::GenericParamDefKind::Type {
synthetic: Some(
hir::SyntheticTyParamKind::ImplTrait | hir::SyntheticTyParamKind::FromAttr,
),
..
})
..
}
)
});
if explicit && impl_trait {

View file

@ -274,10 +274,13 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
}
let autoborrow_mut = adj.iter().any(|adj| {
matches!(adj, &Adjustment {
kind: Adjust::Borrow(AutoBorrow::Ref(_, AutoBorrowMutability::Mut { .. })),
..
})
matches!(
adj,
&Adjustment {
kind: Adjust::Borrow(AutoBorrow::Ref(_, AutoBorrowMutability::Mut { .. })),
..
}
)
});
match self.typeck_results.borrow_mut().adjustments_mut().entry(expr.hir_id) {