Skip to content

Commit 4a8279a

Browse files
committed
Fix another test
1 parent dbc14f9 commit 4a8279a

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

crates/ra_hir_ty/src/infer/path.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -177,13 +177,9 @@ impl<'a, D: HirDatabase> InferenceContext<'a, D> {
177177
AssocItemId::ConstId(c) => ValueNs::ConstId(c),
178178
AssocItemId::TypeAliasId(_) => unreachable!(),
179179
};
180-
let substs = Substs::build_for_def(self.db, item)
181-
.use_parent_substs(&trait_ref.substs)
182-
.fill_with_params()
183-
.build();
184180

185181
self.write_assoc_resolution(id, item);
186-
Some((def, Some(substs)))
182+
Some((def, Some(trait_ref.substs)))
187183
}
188184

189185
fn resolve_ty_assoc_item(

crates/ra_hir_ty/src/tests/method_resolution.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -651,10 +651,10 @@ fn test() {
651651
@r###"
652652
[107; 211) '{ ...>(); }': ()
653653
[117; 118) 'a': (S<u64>, i64, u8)
654-
[121; 150) '<S as ...::<u8>': fn make<S<u64>, i64, u8>() -> (Self, T, U)
654+
[121; 150) '<S as ...::<u8>': fn make<S<u64>, i64, u8>() -> (S<u64>, i64, u8)
655655
[121; 152) '<S as ...<u8>()': (S<u64>, i64, u8)
656656
[162; 163) 'b': (S<u64>, i64, u8)
657-
[182; 206) 'Trait:...::<u8>': fn make<S<u64>, i64, u8>() -> (Self, T, U)
657+
[182; 206) 'Trait:...::<u8>': fn make<S<u64>, i64, u8>() -> (S<u64>, i64, u8)
658658
[182; 208) 'Trait:...<u8>()': (S<u64>, i64, u8)
659659
"###
660660
);

0 commit comments

Comments
 (0)