Open AzureMarker opened 3 years ago
Originally found here: https://github.com/Mcat12/intellij-lalrpop/pull/17#issuecomment-729636357
Given this:
X: () = {}; Y: () = {}; F = { <a: X> Y <Y> => f(<>) };
The alternative in F has 2 symbols: <a: X> and Y<Y>.
F
<a: X>
Y<Y>
After diving into LALRPOP's code, it looks like their lexer emits either a MacroId or a normal Id depending on if there is an < immediately following an identifier (with no space in-between): https://github.com/lalrpop/lalrpop/blob/cba3a7463c014b8444623848219532628054e9a1/lalrpop/src/tok/mod.rs#L647
MacroId
Id
<
Originally found here: https://github.com/Mcat12/intellij-lalrpop/pull/17#issuecomment-729636357
Given this:
The alternative in
F
has 2 symbols:<a: X>
andY<Y>
.After diving into LALRPOP's code, it looks like their lexer emits either a
MacroId
or a normalId
depending on if there is an<
immediately following an identifier (with no space in-between): https://github.com/lalrpop/lalrpop/blob/cba3a7463c014b8444623848219532628054e9a1/lalrpop/src/tok/mod.rs#L647