Skip to content

Commit dcb4837

Browse files
committed
WellFormed -> Holds
1 parent 408fa14 commit dcb4837

File tree

2 files changed

+27
-1
lines changed

2 files changed

+27
-1
lines changed

crates/hir-ty/src/method_resolution.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -615,7 +615,7 @@ fn find_matching_impl(
615615
let wh_goals =
616616
crate::chalk_db::convert_where_clauses(db, impl_.into(), &substs)
617617
.into_iter()
618-
.map(|b| b.into_well_formed_goal(Interner).cast(Interner));
618+
.map(|b| b.cast(Interner));
619619

620620
let goal = crate::Goal::all(Interner, wh_goals);
621621

crates/ide/src/goto_definition.rs

+26
Original file line numberDiff line numberDiff line change
@@ -1445,6 +1445,32 @@ fn f() {
14451445
"#,
14461446
);
14471447
}
1448+
#[test]
1449+
fn wc_case_is_ok() {
1450+
check(
1451+
r#"
1452+
trait G {
1453+
fn g(&self);
1454+
}
1455+
trait BParent{}
1456+
trait Bound: BParent{}
1457+
struct Gen<T>(T);
1458+
impl <T> G for Gen<T>
1459+
where T : Bound
1460+
{
1461+
fn g(&self){
1462+
//^
1463+
}
1464+
}
1465+
struct A;
1466+
impl Bound for A{}
1467+
fn f() {
1468+
let gen = Gen::<A>(A);
1469+
gen.g$0();
1470+
}
1471+
"#,
1472+
);
1473+
}
14481474

14491475
#[test]
14501476
fn method_call_defaulted() {

0 commit comments

Comments
 (0)