diff options
Diffstat (limited to 'crates/ra_ide_api/src/expand.rs')
-rw-r--r-- | crates/ra_ide_api/src/expand.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/ra_ide_api/src/expand.rs b/crates/ra_ide_api/src/expand.rs index 0228bced9..0ad125a9e 100644 --- a/crates/ra_ide_api/src/expand.rs +++ b/crates/ra_ide_api/src/expand.rs | |||
@@ -28,7 +28,7 @@ pub(crate) fn original_range(db: &RootDatabase, node: Source<&SyntaxNode>) -> Fi | |||
28 | .value | 28 | .value |
29 | .descendants_with_tokens() | 29 | .descendants_with_tokens() |
30 | .filter_map(|it| it.into_token()) | 30 | .filter_map(|it| it.into_token()) |
31 | .find_map(|it| expansion.map_token_up(node.with_ast(&it))); | 31 | .find_map(|it| expansion.map_token_up(node.with_value(&it))); |
32 | 32 | ||
33 | match token { | 33 | match token { |
34 | Some(it) => { | 34 | Some(it) => { |
@@ -54,7 +54,7 @@ pub(crate) fn descend_into_macros( | |||
54 | return None; | 54 | return None; |
55 | } | 55 | } |
56 | let source_analyzer = | 56 | let source_analyzer = |
57 | hir::SourceAnalyzer::new(db, token.with_ast(token.value.parent()).as_ref(), None); | 57 | hir::SourceAnalyzer::new(db, token.with_value(token.value.parent()).as_ref(), None); |
58 | let exp = source_analyzer.expand(db, ¯o_call)?; | 58 | let exp = source_analyzer.expand(db, ¯o_call)?; |
59 | exp.map_token_down(db, token.as_ref()) | 59 | exp.map_token_down(db, token.as_ref()) |
60 | }) | 60 | }) |