Add version = "Two" to rustfmt.toml

Ignore UI tests since this change makes rustfmt less friendly with UI
test comments.
This commit is contained in:
Cameron Steffen
2021-03-01 11:53:33 -06:00
parent 5ae1e17e81
commit ada8c72f3f
52 changed files with 232 additions and 510 deletions

View File

@@ -1563,12 +1563,12 @@ pub fn is_trait_impl_item(cx: &LateContext<'_>, hir_id: HirId) -> bool {
/// ```
pub fn fn_has_unsatisfiable_preds(cx: &LateContext<'_>, did: DefId) -> bool {
use rustc_trait_selection::traits;
let predicates =
cx.tcx
.predicates_of(did)
.predicates
.iter()
.filter_map(|(p, _)| if p.is_global() { Some(*p) } else { None });
let predicates = cx
.tcx
.predicates_of(did)
.predicates
.iter()
.filter_map(|(p, _)| if p.is_global() { Some(*p) } else { None });
traits::impossible_predicates(
cx.tcx,
traits::elaborate_predicates(cx.tcx, predicates)