fix: array ref as R-Value

This commit is contained in:
Eatswap 2022-12-11 20:12:59 +08:00
parent 8bec6e3f56
commit 7f11aaf21e
Signed by: Eatswap
GPG Key ID: BE661106A1F3FA0B
1 changed files with 4 additions and 2 deletions

View File

@ -123,8 +123,9 @@ array-ref
;
L-Value
: IDENTIFIER
| array-ref
: IDENTIFIER { std::printf("Parsed L-Value -> IDENTIFIER\n"); }
| array-ref { std::printf("Parsed L-Value -> array-ref\n"); }
;
R-Value
: IDENTIFIER { std::printf("Parsed R-Value -> IDENTIFIER\n"); }
@ -132,6 +133,7 @@ R-Value
| INTEGER { std::printf("Parsed R-Value -> INTEGER\n"); }
| FLOAT { std::printf("Parsed R-Value -> FLOAT\n"); }
| STRING { std::printf("Parsed R-Value -> STRING\n"); }
| array-ref { std::printf("Parsed R-Value -> array-ref\n"); }
;
R-Value-list