aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide_api/src/completion/complete_scope.rs
diff options
context:
space:
mode:
authorbors[bot] <bors[bot]@users.noreply.github.com>2019-04-09 18:55:44 +0100
committerbors[bot] <bors[bot]@users.noreply.github.com>2019-04-09 18:55:44 +0100
commit2fc2d4373b2c4e96bebf320a84270eee3afe34aa (patch)
tree5bdb33ae377b4004f0b28ec5e2edff71b41e8c4e /crates/ra_ide_api/src/completion/complete_scope.rs
parent5f700179fc7ed16d2848a6dbc7cf23da3b8df6c7 (diff)
parent45a2b9252401cc580dfa2e0e761313cc8334d47c (diff)
Merge #1110
1110: Introduce display module and implement new FunctionSignature for CallInfo's r=matklad a=vipentti This introduces a new module `display` in `ra_ide_api` that contains UI-related things, in addition this refactors CallInfo's function signatures into a new `FunctionSignature` type, which implements `Display` and can be converted into `lsp_types::SignatureInformation` in the `conv` layer. Currently only `CallInfo` uses the `FunctionSignature` directly, but `function_label` now uses the same signature and returns it as a string, using the `Display` implementation. This also fixes #960 I think this similar structure could be applied to other UI-displayable items, so instead of the `ra_ide_api` returning `Strings` we could return some intermediate structures that can be converted into a UI-displayable `String` easily, but that could also provide some additional information. Co-authored-by: Ville Penttinen <[email protected]>
Diffstat (limited to 'crates/ra_ide_api/src/completion/complete_scope.rs')
-rw-r--r--crates/ra_ide_api/src/completion/complete_scope.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_ide_api/src/completion/complete_scope.rs b/crates/ra_ide_api/src/completion/complete_scope.rs
index 6146b7bb6..9d82f2270 100644
--- a/crates/ra_ide_api/src/completion/complete_scope.rs
+++ b/crates/ra_ide_api/src/completion/complete_scope.rs
@@ -145,7 +145,7 @@ mod tests {
145 check_reference_completion( 145 check_reference_completion(
146 "dont_show_both_completions_for_shadowing", 146 "dont_show_both_completions_for_shadowing",
147 r" 147 r"
148 fn foo() -> { 148 fn foo() {
149 let bar = 92; 149 let bar = 92;
150 { 150 {
151 let bar = 62; 151 let bar = 62;