diff options
Diffstat (limited to 'crates/ra_ide_api/src/lib.rs')
-rw-r--r-- | crates/ra_ide_api/src/lib.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_ide_api/src/lib.rs b/crates/ra_ide_api/src/lib.rs index 2873bab36..2b02dab2a 100644 --- a/crates/ra_ide_api/src/lib.rs +++ b/crates/ra_ide_api/src/lib.rs | |||
@@ -251,7 +251,7 @@ pub struct RangeInfo<T> { | |||
251 | } | 251 | } |
252 | 252 | ||
253 | impl<T> RangeInfo<T> { | 253 | impl<T> RangeInfo<T> { |
254 | fn new(range: TextRange, info: T) -> RangeInfo<T> { | 254 | pub fn new(range: TextRange, info: T) -> RangeInfo<T> { |
255 | RangeInfo { range, info } | 255 | RangeInfo { range, info } |
256 | } | 256 | } |
257 | } | 257 | } |
@@ -391,7 +391,7 @@ impl Analysis { | |||
391 | pub fn goto_definition( | 391 | pub fn goto_definition( |
392 | &self, | 392 | &self, |
393 | position: FilePosition, | 393 | position: FilePosition, |
394 | ) -> Cancelable<Option<Vec<NavigationTarget>>> { | 394 | ) -> Cancelable<Option<RangeInfo<Vec<NavigationTarget>>>> { |
395 | self.db | 395 | self.db |
396 | .catch_canceled(|db| goto_definition::goto_definition(db, position))? | 396 | .catch_canceled(|db| goto_definition::goto_definition(db, position))? |
397 | } | 397 | } |