aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_db/src
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2018-12-28 15:03:03 +0000
committerAleksey Kladov <[email protected]>2018-12-28 15:17:43 +0000
commit02924174bb084d73cab67af6665ddf00e91983f6 (patch)
tree35e47a7e720a448a407fbca607f5895aacb68428 /crates/ra_db/src
parentd7440a5f4928415f2d2a9f7b2badaff8a9376a09 (diff)
introduce FileRange
Diffstat (limited to 'crates/ra_db/src')
-rw-r--r--crates/ra_db/src/lib.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/crates/ra_db/src/lib.rs b/crates/ra_db/src/lib.rs
index 3028db17c..7181f2950 100644
--- a/crates/ra_db/src/lib.rs
+++ b/crates/ra_db/src/lib.rs
@@ -8,7 +8,7 @@ pub mod mock;
8use std::sync::Arc; 8use std::sync::Arc;
9 9
10use ra_editor::LineIndex; 10use ra_editor::LineIndex;
11use ra_syntax::{TextUnit, SourceFileNode}; 11use ra_syntax::{TextUnit, TextRange, SourceFileNode};
12 12
13pub use crate::{ 13pub use crate::{
14 cancelation::{Canceled, Cancelable}, 14 cancelation::{Canceled, Cancelable},
@@ -70,3 +70,9 @@ pub struct FilePosition {
70 pub file_id: FileId, 70 pub file_id: FileId,
71 pub offset: TextUnit, 71 pub offset: TextUnit,
72} 72}
73
74#[derive(Clone, Copy, Debug)]
75pub struct FileRange {
76 pub file_id: FileId,
77 pub range: TextRange,
78}