mirror of
https://github.com/slint-ui/slint.git
synced 2025-08-04 18:58:36 +00:00
LSP: fetch the file content from cache instead of from disk to compute the line number
Otherwise it doesn't work with the web extension. And the file must anyway be in the cache
This commit is contained in:
parent
31502d5918
commit
81b53e2ae0
2 changed files with 11 additions and 6 deletions
|
@ -104,6 +104,10 @@ impl SourceFileInner {
|
|||
.unwrap_or_default()
|
||||
})
|
||||
}
|
||||
|
||||
pub fn source(&self) -> Option<&str> {
|
||||
self.source.as_ref().map(|s| s.as_str())
|
||||
}
|
||||
}
|
||||
|
||||
pub type SourceFile = Rc<SourceFileInner>;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue