mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-10 23:24:24 +00:00
Capture tokens for Pat used in macro_rules! argument
This extends PR #73293 to handle patterns (Pat). Unlike expressions, patterns do not support custom attributes, so we only need to capture tokens during macro_rules! argument parsing.
This commit is contained in:
parent
4b0e6d5b90
commit
191b0806d2
1 changed files with 1 additions and 0 deletions
|
@ -340,6 +340,7 @@ fn take_pat(from: &mut Pat) -> Pat {
|
|||
id: DUMMY_NODE_ID,
|
||||
kind: Wild,
|
||||
span: DUMMY_SP,
|
||||
tokens: None
|
||||
};
|
||||
mem::replace(from, dummy)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue