mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 12:54:58 +00:00
Make MBE expansion more resilient (WIP)
This commit is contained in:
parent
d3773ec152
commit
b973158aeb
10 changed files with 167 additions and 90 deletions
|
@ -1430,7 +1430,8 @@ impl MacroFixture {
|
|||
let (invocation_tt, _) =
|
||||
ast_to_token_tree(¯o_invocation.token_tree().unwrap()).unwrap();
|
||||
|
||||
self.rules.expand(&invocation_tt)
|
||||
let (tt, err) = self.rules.expand(&invocation_tt);
|
||||
err.map(Err).unwrap_or(Ok(tt))
|
||||
}
|
||||
|
||||
fn assert_expand_err(&self, invocation: &str, err: &ExpandError) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue