aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir/src/ty/snapshots
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_hir/src/ty/snapshots')
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_associated_type_bound.snap10
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_call_trait_method_on_generic_param_1.snap11
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_call_trait_method_on_generic_param_2.snap11
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_from_bound_1.snap17
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_from_bound_2.snap18
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_project_associated_type.snap12
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_trait_assoc_method.snap17
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_generic_1.snap11
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_generic_2.snap13
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_scoped.snap15
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_simple.snap14
-rw-r--r--crates/ra_hir/src/ty/snapshots/tests__infer_with_multiple_trait_impls.snap19
12 files changed, 168 insertions, 0 deletions
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_associated_type_bound.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_associated_type_bound.snap
new file mode 100644
index 000000000..4dbde99f9
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_associated_type_bound.snap
@@ -0,0 +1,10 @@
1---
2created: "2019-03-02T13:52:02.767222917Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[67; 100) '{ ...own; }': ()
8[77; 78) 'y': [unknown]
9[90; 97) 'unknown': [unknown]
10
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_call_trait_method_on_generic_param_1.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_call_trait_method_on_generic_param_1.snap
new file mode 100644
index 000000000..c56e6ba42
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_call_trait_method_on_generic_param_1.snap
@@ -0,0 +1,11 @@
1---
2created: "2019-03-02T13:49:53.509955706Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[59; 60) 't': T
8[65; 84) '{ ...d(); }': ()
9[71; 72) 't': T
10[71; 81) 't.method()': [unknown]
11
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_call_trait_method_on_generic_param_2.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_call_trait_method_on_generic_param_2.snap
new file mode 100644
index 000000000..7791a57da
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_call_trait_method_on_generic_param_2.snap
@@ -0,0 +1,11 @@
1---
2created: "2019-03-02T13:49:53.477633667Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[66; 67) 't': T
8[72; 91) '{ ...d(); }': ()
9[78; 79) 't': T
10[78; 88) 't.method()': [unknown]
11
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_from_bound_1.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_from_bound_1.snap
new file mode 100644
index 000000000..c8d8e9806
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_from_bound_1.snap
@@ -0,0 +1,17 @@
1---
2created: "2019-03-02T13:49:53.558635265Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[86; 87) 't': T
8[92; 94) '{}': ()
9[105; 144) '{ ...(s); }': ()
10[115; 116) 's': S<[unknown]>
11[119; 120) 'S': S<[unknown]>(T) -> S<T>
12[119; 129) 'S(unknown)': S<[unknown]>
13[121; 128) 'unknown': [unknown]
14[135; 138) 'foo': fn foo<S<[unknown]>>(T) -> ()
15[135; 141) 'foo(s)': ()
16[139; 140) 's': S<[unknown]>
17
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_from_bound_2.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_from_bound_2.snap
new file mode 100644
index 000000000..37def29c3
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_from_bound_2.snap
@@ -0,0 +1,18 @@
1---
2created: "2019-03-02T13:49:53.572131028Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[87; 88) 't': T
8[98; 100) '{}': ()
9[111; 163) '{ ...(s); }': ()
10[121; 122) 's': S<[unknown]>
11[125; 126) 'S': S<[unknown]>(T) -> S<T>
12[125; 135) 'S(unknown)': S<[unknown]>
13[127; 134) 'unknown': [unknown]
14[145; 146) 'x': u32
15[154; 157) 'foo': fn foo<u32, S<[unknown]>>(T) -> U
16[154; 160) 'foo(s)': u32
17[158; 159) 's': S<[unknown]>
18
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_project_associated_type.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_project_associated_type.snap
new file mode 100644
index 000000000..6d5331799
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_project_associated_type.snap
@@ -0,0 +1,12 @@
1---
2created: "2019-03-02T13:49:53.680954394Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[108; 181) '{ ...ter; }': ()
8[118; 119) 'x': i32
9[145; 146) '1': i32
10[156; 157) 'y': [unknown]
11[169; 178) 'no_matter': [unknown]
12
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_trait_assoc_method.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_assoc_method.snap
new file mode 100644
index 000000000..c09e1cf44
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_assoc_method.snap
@@ -0,0 +1,17 @@
1---
2created: "2019-03-02T13:49:53.756157395Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[87; 193) '{ ...t(); }': ()
8[97; 99) 's1': S
9[105; 121) 'Defaul...efault': [unknown]
10[105; 123) 'Defaul...ault()': S
11[133; 135) 's2': [unknown]
12[138; 148) 'S::default': [unknown]
13[138; 150) 'S::default()': [unknown]
14[160; 162) 's3': [unknown]
15[165; 188) '<S as ...efault': [unknown]
16[165; 190) '<S as ...ault()': [unknown]
17
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_generic_1.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_generic_1.snap
new file mode 100644
index 000000000..a71dbaf00
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_generic_1.snap
@@ -0,0 +1,11 @@
1---
2created: "2019-03-02T13:49:53.771466423Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[33; 37) 'self': &[unknown]
8[92; 111) '{ ...d(); }': ()
9[98; 99) 'S': S
10[98; 108) 'S.method()': [unknown]
11
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_generic_2.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_generic_2.snap
new file mode 100644
index 000000000..4b28cb32a
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_generic_2.snap
@@ -0,0 +1,13 @@
1---
2created: "2019-03-02T13:49:53.765202736Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[33; 37) 'self': &[unknown]
8[102; 127) '{ ...d(); }': ()
9[108; 109) 'S': S<u32>(T) -> S<T>
10[108; 115) 'S(1u32)': S<u32>
11[108; 124) 'S(1u32...thod()': [unknown]
12[110; 114) '1u32': u32
13
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_scoped.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_scoped.snap
new file mode 100644
index 000000000..f2cce656d
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_scoped.snap
@@ -0,0 +1,15 @@
1---
2created: "2019-03-02T15:41:07.568155273Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[63; 67) 'self': &[unknown]
8[169; 173) 'self': &[unknown]
9[300; 337) '{ ... }': ()
10[310; 311) 'S': S
11[310; 320) 'S.method()': [unknown]
12[416; 454) '{ ... }': ()
13[426; 427) 'S': S
14[426; 436) 'S.method()': [unknown]
15
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_simple.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_simple.snap
new file mode 100644
index 000000000..22e83722d
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_trait_method_simple.snap
@@ -0,0 +1,14 @@
1---
2created: "2019-03-02T15:41:07.562949721Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[31; 35) 'self': &[unknown]
8[110; 114) 'self': &[unknown]
9[170; 228) '{ ...i128 }': ()
10[176; 178) 'S1': S1
11[176; 187) 'S1.method()': [unknown]
12[203; 205) 'S2': S2
13[203; 214) 'S2.method()': [unknown]
14
diff --git a/crates/ra_hir/src/ty/snapshots/tests__infer_with_multiple_trait_impls.snap b/crates/ra_hir/src/ty/snapshots/tests__infer_with_multiple_trait_impls.snap
new file mode 100644
index 000000000..82c8bae58
--- /dev/null
+++ b/crates/ra_hir/src/ty/snapshots/tests__infer_with_multiple_trait_impls.snap
@@ -0,0 +1,19 @@
1---
2created: "2019-03-02T13:49:53.860659428Z"
3creator: [email protected]
4source: crates/ra_hir/src/ty/tests.rs
5expression: "&result"
6---
7[29; 33) 'self': [unknown]
8[107; 198) '{ ...(S); }': ()
9[117; 118) 'x': u32
10[126; 127) 'S': S
11[126; 134) 'S.into()': u32
12[144; 145) 'y': u64
13[153; 154) 'S': S
14[153; 161) 'S.into()': u64
15[171; 172) 'z': [unknown]
16[175; 192) 'Into::...::into': [unknown]
17[175; 195) 'Into::...nto(S)': [unknown]
18[193; 194) 'S': S
19