mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 05:15:04 +00:00
dont store body inside source map
This commit is contained in:
parent
eaf1df26e9
commit
f4c5383103
5 changed files with 54 additions and 61 deletions
|
@ -484,7 +484,7 @@ impl Function {
|
|||
}
|
||||
|
||||
pub fn body_source_map(&self, db: &impl HirDatabase) -> Arc<BodySourceMap> {
|
||||
db.body_source_map(*self)
|
||||
db.body_with_source_map(*self).1
|
||||
}
|
||||
|
||||
pub fn body(&self, db: &impl HirDatabase) -> Arc<Body> {
|
||||
|
@ -497,7 +497,7 @@ impl Function {
|
|||
|
||||
pub fn scopes(&self, db: &impl HirDatabase) -> ScopesWithSyntaxMapping {
|
||||
let scopes = db.expr_scopes(*self);
|
||||
let syntax_mapping = db.body_source_map(*self);
|
||||
let syntax_mapping = db.body_with_source_map(*self).1;
|
||||
ScopesWithSyntaxMapping { scopes, syntax_mapping }
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue