Skip to content

Commit c815d5b

Browse files
bors[bot]matklad
andauthored
Merge #5225
5225: Alight details in comkplation list r=matklad a=matklad bors r+ 🤖 Co-authored-by: Aleksey Kladov <[email protected]>
2 parents a826ac6 + 943fa46 commit c815d5b

File tree

9 files changed

+542
-1207
lines changed

9 files changed

+542
-1207
lines changed

crates/ra_ide/src/completion.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ mod completion_config;
22
mod completion_item;
33
mod completion_context;
44
mod presentation;
5+
mod patterns;
6+
#[cfg(test)]
7+
mod test_utils;
58

69
mod complete_attribute;
710
mod complete_dot;
@@ -15,9 +18,6 @@ mod complete_unqualified_path;
1518
mod complete_postfix;
1619
mod complete_macro_in_item_position;
1720
mod complete_trait_impl;
18-
mod patterns;
19-
#[cfg(test)]
20-
mod test_utils;
2121

2222
use ra_ide_db::RootDatabase;
2323

crates/ra_ide/src/completion/complete_dot.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ fn foo(s: S) { s.<|> }
8383
"#,
8484
expect![[r#"
8585
me bar() fn bar(&self)
86-
fd foo u32
86+
fd foo u32
8787
"#]],
8888
);
8989
}
@@ -98,7 +98,7 @@ impl S {
9898
}
9999
"#,
100100
expect![[r#"
101-
me foo() fn foo(self)
101+
me foo() fn foo(self)
102102
fd the_field (u32,)
103103
"#]],
104104
)
@@ -114,7 +114,7 @@ impl A {
114114
}
115115
"#,
116116
expect![[r#"
117-
me foo() fn foo(&self)
117+
me foo() fn foo(&self)
118118
fd the_field (u32, i32)
119119
"#]],
120120
)
@@ -148,7 +148,7 @@ fn foo(a: inner::A) { a.<|> }
148148
"#,
149149
expect![[r#"
150150
fd crate_field u32
151-
fd pub_field u32
151+
fd pub_field u32
152152
fd super_field u32
153153
"#]],
154154
);

crates/ra_ide/src/completion/complete_keyword.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -216,17 +216,17 @@ mod tests {
216216
check(
217217
r"use a::<|>",
218218
expect![[r#"
219-
kw self
220-
kw super::
221-
"#]],
219+
kw self
220+
kw super::
221+
"#]],
222222
);
223223

224224
check(
225225
r"use a::{b, <|>}",
226226
expect![[r#"
227-
kw self
228-
kw super::
229-
"#]],
227+
kw self
228+
kw super::
229+
"#]],
230230
);
231231
}
232232

crates/ra_ide/src/completion/complete_pattern.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ fn foo() {
6161
expect![[r#"
6262
st Bar
6363
en E
64-
ev X ()
64+
ev X ()
6565
ct Z
6666
md m
6767
"#]],

crates/ra_ide/src/completion/complete_postfix.rs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -260,14 +260,14 @@ fn main() {
260260
}
261261
"#,
262262
expect![[r#"
263-
sn box Box::new(expr)
264-
sn call function(expr)
265-
sn dbg dbg!(expr)
266-
sn if if expr {}
263+
sn box Box::new(expr)
264+
sn call function(expr)
265+
sn dbg dbg!(expr)
266+
sn if if expr {}
267267
sn match match expr {}
268-
sn not !expr
269-
sn ref &expr
270-
sn refm &mut expr
268+
sn not !expr
269+
sn ref &expr
270+
sn refm &mut expr
271271
sn while while expr {}
272272
"#]],
273273
);
@@ -283,12 +283,12 @@ fn main() {
283283
}
284284
"#,
285285
expect![[r#"
286-
sn box Box::new(expr)
287-
sn call function(expr)
288-
sn dbg dbg!(expr)
286+
sn box Box::new(expr)
287+
sn call function(expr)
288+
sn dbg dbg!(expr)
289289
sn match match expr {}
290-
sn ref &expr
291-
sn refm &mut expr
290+
sn ref &expr
291+
sn refm &mut expr
292292
"#]],
293293
)
294294
}

0 commit comments

Comments
 (0)