diff options
Diffstat (limited to 'crates/ra_ide_api/src/completion/completion_context.rs')
-rw-r--r-- | crates/ra_ide_api/src/completion/completion_context.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/crates/ra_ide_api/src/completion/completion_context.rs b/crates/ra_ide_api/src/completion/completion_context.rs index de9b95c81..fd4cfc944 100644 --- a/crates/ra_ide_api/src/completion/completion_context.rs +++ b/crates/ra_ide_api/src/completion/completion_context.rs | |||
@@ -65,7 +65,10 @@ impl<'a> CompletionContext<'a> { | |||
65 | Some(ctx) | 65 | Some(ctx) |
66 | } | 66 | } |
67 | 67 | ||
68 | pub(crate) fn leaf_range(&self) -> TextRange { | 68 | // The range of the identifier that is being completed. |
69 | // This is purely advisory and can be used, for example, to highlight this range in the editor. | ||
70 | // Clients are expected to ignore this field. | ||
71 | pub(crate) fn source_range(&self) -> TextRange { | ||
69 | self.leaf.range() | 72 | self.leaf.range() |
70 | } | 73 | } |
71 | 74 | ||