mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-11-19 11:35:16 +00:00
Parse bare dyn types with leading lifetime
This commit is contained in:
parent
0dd94d3b07
commit
2a509d0eb2
4 changed files with 72 additions and 1 deletions
|
|
@ -35,7 +35,7 @@ const GENERIC_ARG_FIRST: TokenSet = TokenSet::new(&[
|
|||
// type T = S<i32>;
|
||||
fn generic_arg(p: &mut Parser<'_>) -> bool {
|
||||
match p.current() {
|
||||
LIFETIME_IDENT => lifetime_arg(p),
|
||||
LIFETIME_IDENT if !p.nth_at(1, T![+]) => lifetime_arg(p),
|
||||
T!['{'] | T![true] | T![false] | T![-] => const_arg(p),
|
||||
k if k.is_literal() => const_arg(p),
|
||||
// test associated_type_bounds
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue