Use Idents in a number of structures in HIR
Namely: labels, type parameters, bindings in patterns, parameter names in functions without body. All of these do not need hygiene after lowering to HIR, only span locations.
This commit is contained in:
@@ -7325,7 +7325,7 @@ impl<'a> Parser<'a> {
|
||||
match self.token {
|
||||
token::Ident(ident, false) if ident.name == keywords::Underscore.name() => {
|
||||
self.bump(); // `_`
|
||||
Ok(Some(Ident::new(ident.name.gensymed(), ident.span)))
|
||||
Ok(Some(ident.gensym()))
|
||||
}
|
||||
_ => self.parse_ident().map(Some),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user