aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/tests/method_resolution.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_ty/src/tests/method_resolution.rs')
-rw-r--r--crates/hir_ty/src/tests/method_resolution.rs40
1 files changed, 20 insertions, 20 deletions
diff --git a/crates/hir_ty/src/tests/method_resolution.rs b/crates/hir_ty/src/tests/method_resolution.rs
index 0f17ff151..596d4f182 100644
--- a/crates/hir_ty/src/tests/method_resolution.rs
+++ b/crates/hir_ty/src/tests/method_resolution.rs
@@ -108,16 +108,16 @@ fn infer_associated_method_with_modules() {
108 check_infer( 108 check_infer(
109 r#" 109 r#"
110 mod a { 110 mod a {
111 struct A; 111 pub struct A;
112 impl A { pub fn thing() -> A { A {} }} 112 impl A { pub fn thing() -> A { A {} }}
113 } 113 }
114 114
115 mod b { 115 mod b {
116 struct B; 116 pub struct B;
117 impl B { pub fn thing() -> u32 { 99 }} 117 impl B { pub fn thing() -> u32 { 99 }}
118 118
119 mod c { 119 pub mod c {
120 struct C; 120 pub struct C;
121 impl C { pub fn thing() -> C { C {} }} 121 impl C { pub fn thing() -> C { C {} }}
122 } 122 }
123 } 123 }
@@ -130,22 +130,22 @@ fn infer_associated_method_with_modules() {
130 } 130 }
131 "#, 131 "#,
132 expect![[r#" 132 expect![[r#"
133 55..63 '{ A {} }': A 133 59..67 '{ A {} }': a::A
134 57..61 'A {}': A 134 61..65 'A {}': a::A
135 125..131 '{ 99 }': u32 135 133..139 '{ 99 }': u32
136 127..129 '99': u32 136 135..137 '99': u32
137 201..209 '{ C {} }': C 137 217..225 '{ C {} }': c::C
138 203..207 'C {}': C 138 219..223 'C {}': c::C
139 240..324 '{ ...g(); }': () 139 256..340 '{ ...g(); }': ()
140 250..251 'x': A 140 266..267 'x': a::A
141 254..265 'a::A::thing': fn thing() -> A 141 270..281 'a::A::thing': fn thing() -> A
142 254..267 'a::A::thing()': A 142 270..283 'a::A::thing()': a::A
143 277..278 'y': u32 143 293..294 'y': u32
144 281..292 'b::B::thing': fn thing() -> u32 144 297..308 'b::B::thing': fn thing() -> u32
145 281..294 'b::B::thing()': u32 145 297..310 'b::B::thing()': u32
146 304..305 'z': C 146 320..321 'z': c::C
147 308..319 'c::C::thing': fn thing() -> C 147 324..335 'c::C::thing': fn thing() -> C
148 308..321 'c::C::thing()': C 148 324..337 'c::C::thing()': c::C
149 "#]], 149 "#]],
150 ); 150 );
151} 151}