aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide_api/src/lib.rs
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2019-10-24 12:01:02 +0100
committerAleksey Kladov <[email protected]>2019-10-24 12:16:36 +0100
commit4529da906db7f18aaf384c079332e4ea12c82d55 (patch)
treedf095e7f3a20f9c5b3df09c4722d0e3e406b122f /crates/ra_ide_api/src/lib.rs
parent6d186ec3beff14bc161d1c7b7c98b412c4f833d9 (diff)
for highlighting, search only the current file
Diffstat (limited to 'crates/ra_ide_api/src/lib.rs')
-rw-r--r--crates/ra_ide_api/src/lib.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/crates/ra_ide_api/src/lib.rs b/crates/ra_ide_api/src/lib.rs
index 19669a7f0..0832229fd 100644
--- a/crates/ra_ide_api/src/lib.rs
+++ b/crates/ra_ide_api/src/lib.rs
@@ -71,7 +71,7 @@ pub use crate::{
71 inlay_hints::{InlayHint, InlayKind}, 71 inlay_hints::{InlayHint, InlayKind},
72 line_index::{LineCol, LineIndex}, 72 line_index::{LineCol, LineIndex},
73 line_index_utils::translate_offset_with_edit, 73 line_index_utils::translate_offset_with_edit,
74 references::ReferenceSearchResult, 74 references::{ReferenceSearchResult, SearchScope},
75 runnables::{Runnable, RunnableKind}, 75 runnables::{Runnable, RunnableKind},
76 syntax_highlighting::HighlightedRange, 76 syntax_highlighting::HighlightedRange,
77}; 77};
@@ -481,8 +481,9 @@ impl Analysis {
481 pub fn find_all_refs( 481 pub fn find_all_refs(
482 &self, 482 &self,
483 position: FilePosition, 483 position: FilePosition,
484 search_scope: Option<SearchScope>,
484 ) -> Cancelable<Option<ReferenceSearchResult>> { 485 ) -> Cancelable<Option<ReferenceSearchResult>> {
485 self.with_db(|db| references::find_all_refs(db, position).map(|it| it.info)) 486 self.with_db(|db| references::find_all_refs(db, position, search_scope).map(|it| it.info))
486 } 487 }
487 488
488 /// Returns a short text describing element at position. 489 /// Returns a short text describing element at position.