aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
authorKirill Bulatov <[email protected]>2020-02-23 10:02:00 +0000
committerKirill Bulatov <[email protected]>2020-02-23 10:02:00 +0000
commitb2a7b29bb9e195e75ad04dc69c572d02f98fe5ce (patch)
tree403a8230613c32486f1bc86e0b275653a833a719 /crates
parentc200dba167c294fc7d9080945df9a01ae7461ca0 (diff)
Style fixes
Diffstat (limited to 'crates')
-rw-r--r--crates/ra_ide/src/inlay_hints.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/crates/ra_ide/src/inlay_hints.rs b/crates/ra_ide/src/inlay_hints.rs
index fb63fd1de..a484dfdeb 100644
--- a/crates/ra_ide/src/inlay_hints.rs
+++ b/crates/ra_ide/src/inlay_hints.rs
@@ -113,12 +113,13 @@ fn get_param_name_hints(
113 .collect::<Vec<_>>(); 113 .collect::<Vec<_>>();
114 114
115 let fn_signature = get_fn_signature(db, analyzer, &expr)?; 115 let fn_signature = get_fn_signature(db, analyzer, &expr)?;
116 let parameters = 116 let n_params_to_skip =
117 if fn_signature.has_self_param && fn_signature.parameter_names.len() > args.len() { 117 if fn_signature.has_self_param && fn_signature.parameter_names.len() > args.len() {
118 fn_signature.parameter_names.iter().skip(1) 118 1
119 } else { 119 } else {
120 fn_signature.parameter_names.iter().skip(0) 120 0
121 }; 121 };
122 let parameters = fn_signature.parameter_names.iter().skip(n_params_to_skip);
122 123
123 let hints = parameters 124 let hints = parameters
124 .zip(args) 125 .zip(args)