aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_mbe/src/mbe_expander.rs
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2019-07-18 18:09:50 +0100
committerAleksey Kladov <[email protected]>2019-07-19 11:16:24 +0100
commit08fd402ef2ef1151a9b09cf11c5869b79f1959bb (patch)
treea1172066c2a564d7b0024d23099248415a9fee16 /crates/ra_mbe/src/mbe_expander.rs
parentd402974aa0af6de290245a9d2a69a5d56c4fa610 (diff)
migrate mbe to the new rowan
Diffstat (limited to 'crates/ra_mbe/src/mbe_expander.rs')
-rw-r--r--crates/ra_mbe/src/mbe_expander.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/crates/ra_mbe/src/mbe_expander.rs b/crates/ra_mbe/src/mbe_expander.rs
index c7c06c7fd..f185aecb7 100644
--- a/crates/ra_mbe/src/mbe_expander.rs
+++ b/crates/ra_mbe/src/mbe_expander.rs
@@ -599,7 +599,8 @@ mod tests {
599 let macro_definition = 599 let macro_definition =
600 source_file.syntax().descendants().find_map(ast::MacroCall::cast).unwrap(); 600 source_file.syntax().descendants().find_map(ast::MacroCall::cast).unwrap();
601 601
602 let (definition_tt, _) = ast_to_token_tree(macro_definition.token_tree().unwrap()).unwrap(); 602 let (definition_tt, _) =
603 ast_to_token_tree(&macro_definition.token_tree().unwrap()).unwrap();
603 crate::MacroRules::parse(&definition_tt).unwrap() 604 crate::MacroRules::parse(&definition_tt).unwrap()
604 } 605 }
605 606
@@ -611,7 +612,8 @@ mod tests {
611 let macro_invocation = 612 let macro_invocation =
612 source_file.syntax().descendants().find_map(ast::MacroCall::cast).unwrap(); 613 source_file.syntax().descendants().find_map(ast::MacroCall::cast).unwrap();
613 614
614 let (invocation_tt, _) = ast_to_token_tree(macro_invocation.token_tree().unwrap()).unwrap(); 615 let (invocation_tt, _) =
616 ast_to_token_tree(&macro_invocation.token_tree().unwrap()).unwrap();
615 617
616 expand_rule(&rules.rules[0], &invocation_tt) 618 expand_rule(&rules.rules[0], &invocation_tt)
617 } 619 }