Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/base-db/src/lib.rs')
| -rw-r--r-- | crates/base-db/src/lib.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/crates/base-db/src/lib.rs b/crates/base-db/src/lib.rs index fd47403ec4..ff439119c9 100644 --- a/crates/base-db/src/lib.rs +++ b/crates/base-db/src/lib.rs @@ -7,6 +7,7 @@ extern crate rustc_driver as _; pub use salsa; pub use salsa_macros; +use span::TextSize; // FIXME: Rename this crate, base db is non descriptive mod change; @@ -281,6 +282,8 @@ pub trait SourceDatabase: salsa::Database { fn crates_map(&self) -> Arc<CratesMap>; fn nonce_and_revision(&self) -> (Nonce, salsa::Revision); + + fn line_column(&self, file: FileId, offset: TextSize) -> Result<(u32, u32), ()>; } static NEXT_NONCE: AtomicUsize = AtomicUsize::new(0); |