mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-27 12:29:21 +00:00
Add a "Debug ItemTree" LSP request
This commit is contained in:
parent
8d13864440
commit
271ec6b990
9 changed files with 108 additions and 0 deletions
|
@ -50,6 +50,7 @@ mod typing;
|
|||
mod markdown_remove;
|
||||
mod doc_links;
|
||||
mod view_crate_graph;
|
||||
mod view_item_tree;
|
||||
|
||||
use std::sync::Arc;
|
||||
|
||||
|
@ -288,6 +289,10 @@ impl Analysis {
|
|||
self.with_db(|db| view_hir::view_hir(&db, position))
|
||||
}
|
||||
|
||||
pub fn view_item_tree(&self, file_id: FileId) -> Cancelable<String> {
|
||||
self.with_db(|db| view_item_tree::view_item_tree(&db, file_id))
|
||||
}
|
||||
|
||||
/// Renders the crate graph to GraphViz "dot" syntax.
|
||||
pub fn view_crate_graph(&self) -> Cancelable<Result<String, String>> {
|
||||
self.with_db(|db| view_crate_graph::view_crate_graph(&db))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue