aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir/src/ty
diff options
context:
space:
mode:
authorFlorian Diebold <[email protected]>2019-02-16 21:06:23 +0000
committerFlorian Diebold <[email protected]>2019-02-16 22:06:41 +0000
commit65bd9bc3a800e09f52a315cf98e86c120c366c2c (patch)
tree954a439a7c83898c36a0f2516e4a91c37c03c7dc /crates/ra_hir/src/ty
parent2af067b391bf37950cf1d3f1af863d931b385af5 (diff)
Handle impl generics in method calls
Diffstat (limited to 'crates/ra_hir/src/ty')
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_generic_chain.snap54
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_impl_generics.snap40
2 files changed, 47 insertions, 47 deletions
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_generic_chain.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_generic_chain.snap
index 626f31252..d1ce87b0a 100644
--- a/crates/ra_hir/src/ty/snapshots/tests__infer_generic_chain.snap
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_generic_chain.snap
@@ -1,36 +1,36 @@
1--- 1---
2created: "2019-01-27T14:52:29.938713255+00:00" 2created: "2019-02-16T20:53:59.655361804Z"
3creator: [email protected] 3creator: [email protected]
4expression: "&result"
5source: crates/ra_hir/src/ty/tests.rs 4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6--- 6---
7[53; 57) 'self': A<[unknown]> 7[53; 57) 'self': A<T2>
8[65; 87) '{ ... }': [unknown] 8[65; 87) '{ ... }': T2
9[75; 79) 'self': A<[unknown]> 9[75; 79) 'self': A<T2>
10[75; 81) 'self.x': [unknown] 10[75; 81) 'self.x': T2
11[99; 100) 't': T 11[99; 100) 't': T
12[110; 115) '{ t }': T 12[110; 115) '{ t }': T
13[112; 113) 't': T 13[112; 113) 't': T
14[135; 261) '{ ....x() }': i128 14[135; 261) '{ ....x() }': i128
15[146; 147) 'x': i32 15[146; 147) 'x': i128
16[150; 151) '1': i32 16[150; 151) '1': i128
17[162; 163) 'y': i32 17[162; 163) 'y': i128
18[166; 168) 'id': fn id<i32>(T) -> T 18[166; 168) 'id': fn id<i128>(T) -> T
19[166; 171) 'id(x)': i32 19[166; 171) 'id(x)': i128
20[169; 170) 'x': i32 20[169; 170) 'x': i128
21[182; 183) 'a': A<i32> 21[182; 183) 'a': A<i128>
22[186; 200) 'A { x: id(y) }': A<i32> 22[186; 200) 'A { x: id(y) }': A<i128>
23[193; 195) 'id': fn id<i32>(T) -> T 23[193; 195) 'id': fn id<i128>(T) -> T
24[193; 198) 'id(y)': i32 24[193; 198) 'id(y)': i128
25[196; 197) 'y': i32 25[196; 197) 'y': i128
26[211; 212) 'z': i32 26[211; 212) 'z': i128
27[215; 217) 'id': fn id<i32>(T) -> T 27[215; 217) 'id': fn id<i128>(T) -> T
28[215; 222) 'id(a.x)': i32 28[215; 222) 'id(a.x)': i128
29[218; 219) 'a': A<i32> 29[218; 219) 'a': A<i128>
30[218; 221) 'a.x': i32 30[218; 221) 'a.x': i128
31[233; 234) 'b': A<i32> 31[233; 234) 'b': A<i128>
32[237; 247) 'A { x: z }': A<i32> 32[237; 247) 'A { x: z }': A<i128>
33[244; 245) 'z': i32 33[244; 245) 'z': i128
34[254; 255) 'b': A<i32> 34[254; 255) 'b': A<i128>
35[254; 259) 'b.x()': i128 35[254; 259) 'b.x()': i128
36 36
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_impl_generics.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_impl_generics.snap
index 99df39fc2..eabbe52fd 100644
--- a/crates/ra_hir/src/ty/snapshots/tests__infer_impl_generics.snap
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_impl_generics.snap
@@ -1,25 +1,25 @@
1--- 1---
2created: "2019-02-16T19:27:11.573533475Z" 2created: "2019-02-16T20:53:59.657979128Z"
3creator: [email protected] 3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs 4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result" 5expression: "&result"
6--- 6---
7[74; 78) 'self': A<[unknown], [unknown]> 7[74; 78) 'self': A<X, Y>
8[85; 107) '{ ... }': [unknown] 8[85; 107) '{ ... }': X
9[95; 99) 'self': A<[unknown], [unknown]> 9[95; 99) 'self': A<X, Y>
10[95; 101) 'self.x': [unknown] 10[95; 101) 'self.x': X
11[117; 121) 'self': A<[unknown], [unknown]> 11[117; 121) 'self': A<X, Y>
12[128; 150) '{ ... }': [unknown] 12[128; 150) '{ ... }': Y
13[138; 142) 'self': A<[unknown], [unknown]> 13[138; 142) 'self': A<X, Y>
14[138; 144) 'self.y': [unknown] 14[138; 144) 'self.y': Y
15[163; 167) 'self': A<[unknown], [unknown]> 15[163; 167) 'self': A<X, Y>
16[169; 170) 't': T 16[169; 170) 't': T
17[188; 223) '{ ... }': ([unknown], [unknown], T) 17[188; 223) '{ ... }': (X, Y, T)
18[198; 217) '(self.....y, t)': ([unknown], [unknown], T) 18[198; 217) '(self.....y, t)': (X, Y, T)
19[199; 203) 'self': A<[unknown], [unknown]> 19[199; 203) 'self': A<X, Y>
20[199; 205) 'self.x': [unknown] 20[199; 205) 'self.x': X
21[207; 211) 'self': A<[unknown], [unknown]> 21[207; 211) 'self': A<X, Y>
22[207; 213) 'self.y': [unknown] 22[207; 213) 'self.y': Y
23[215; 216) 't': T 23[215; 216) 't': T
24[245; 342) '{ ...(1); }': () 24[245; 342) '{ ...(1); }': ()
25[255; 256) 'a': A<u64, i64> 25[255; 256) 'a': A<u64, i64>
@@ -27,13 +27,13 @@ expression: "&result"
27[266; 270) '1u64': u64 27[266; 270) '1u64': u64
28[275; 279) '1i64': i64 28[275; 279) '1i64': i64
29[287; 288) 'a': A<u64, i64> 29[287; 288) 'a': A<u64, i64>
30[287; 292) 'a.x()': [unknown] 30[287; 292) 'a.x()': u64
31[298; 299) 'a': A<u64, i64> 31[298; 299) 'a': A<u64, i64>
32[298; 303) 'a.y()': [unknown] 32[298; 303) 'a.y()': i64
33[309; 310) 'a': A<u64, i64> 33[309; 310) 'a': A<u64, i64>
34[309; 319) 'a.z(1i128)': ([unknown], [unknown], i128) 34[309; 319) 'a.z(1i128)': (u64, i64, i128)
35[313; 318) '1i128': i128 35[313; 318) '1i128': i128
36[325; 326) 'a': A<u64, i64> 36[325; 326) 'a': A<u64, i64>
37[325; 339) 'a.z::<u128>(1)': ([unknown], [unknown], i32) 37[325; 339) 'a.z::<u128>(1)': (u64, i64, i32)
38[337; 338) '1': i32 38[337; 338) '1': i32
39 39