From 30bc3b93bec06256350b66869f2885ee71c3bedd Mon Sep 17 00:00:00 2001 From: Evgenii P Date: Sat, 3 Aug 2019 01:16:20 +0700 Subject: rustfmt --- crates/ra_hir/src/ty/method_resolution.rs | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'crates/ra_hir/src/ty') diff --git a/crates/ra_hir/src/ty/method_resolution.rs b/crates/ra_hir/src/ty/method_resolution.rs index 2e2f88138..8731d6ba4 100644 --- a/crates/ra_hir/src/ty/method_resolution.rs +++ b/crates/ra_hir/src/ty/method_resolution.rs @@ -15,7 +15,7 @@ use crate::{ resolve::Resolver, traits::TraitItem, ty::primitive::{FloatBitness, UncertainFloatTy, UncertainIntTy}, - ty::{Ty, TypeCtor, traits::Solution}, + ty::{traits::Solution, Ty, TypeCtor}, Crate, Function, HirDatabase, Module, Name, Trait, }; @@ -255,14 +255,20 @@ fn iterate_inherent_methods( None } -pub(crate) fn implements_trait(ty: &Canonical, db: &impl HirDatabase, resolver: &Resolver, krate: Crate, trait_: Trait) -> bool { +pub(crate) fn implements_trait( + ty: &Canonical, + db: &impl HirDatabase, + resolver: &Resolver, + krate: Crate, + trait_: Trait, +) -> bool { let env = lower::trait_env(db, resolver); let goal = generic_implements_goal(db, env.clone(), trait_, ty.clone()); let solution = db.trait_solve(krate, goal); if let Some(solution) = solution { if let Solution::Unique(_) = solution { - return true + return true; } } -- cgit v1.2.3