Skip to content

Commit f090205

Browse files
committed
Auto merge of rust-lang#16415 - Waqar144:work/make-try-to-nav-pub, r=Veykril
internal: Make TryToNav trait public Currently there is no proper way to get a target FileRange for a given Definition.
2 parents 38f7a34 + 231f730 commit f090205

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

crates/ide/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ use syntax::SourceFile;
7979
use triomphe::Arc;
8080
use view_memory_layout::{view_memory_layout, RecursiveMemoryLayout};
8181

82-
use crate::navigation_target::{ToNav, TryToNav};
82+
use crate::navigation_target::ToNav;
8383

8484
pub use crate::{
8585
annotations::{Annotation, AnnotationConfig, AnnotationKind, AnnotationLocation},
@@ -104,7 +104,7 @@ pub use crate::{
104104
SymbolInformationKind,
105105
},
106106
move_item::Direction,
107-
navigation_target::{NavigationTarget, UpmappingResult},
107+
navigation_target::{NavigationTarget, TryToNav, UpmappingResult},
108108
prime_caches::ParallelPrimeCachesProgress,
109109
references::ReferenceSearchResult,
110110
rename::RenameError,

crates/ide/src/navigation_target.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ pub(crate) trait ToNav {
7676
fn to_nav(&self, db: &RootDatabase) -> UpmappingResult<NavigationTarget>;
7777
}
7878

79-
pub(crate) trait TryToNav {
79+
pub trait TryToNav {
8080
fn try_to_nav(&self, db: &RootDatabase) -> Option<UpmappingResult<NavigationTarget>>;
8181
}
8282

0 commit comments

Comments
 (0)