From 77596a9d96d29e46dcea21e591f19b08d44f2a9f Mon Sep 17 00:00:00 2001 From: Meyer Simon Date: Thu, 27 Feb 2025 17:02:17 -0500 Subject: [PATCH] got it to workgit add grammar.ygit add grammar.ygit add grammar.ygit add grammar.ygit add grammar.ygit add grammar.ygit add grammar.y! t#34 --- grammar.y | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/grammar.y b/grammar.y index 2015769..0ce008e 100644 --- a/grammar.y +++ b/grammar.y @@ -63,7 +63,7 @@ input: /*empty for now*/ OPTIONAL; OPTIONAL: - '[' {printf("success");}; + L_BRACKET {printf("success");}; // B : '{'{CreateScope(cur,line,column)} E '}'; //Braced Expressions can have braces removed to get regular expressions // D : '[' l ']'; //Declaration Lists Brackets can be taken out to get a list of Declarations // E : Maybe_D U; //An expression can start with an optional D followed by an undeclared segment @@ -76,7 +76,7 @@ OPTIONAL: void yyerror(const char *err) { fprintf(stderr, "Error: %s\n", err); -} +} int main() { int a; while (a = yyparse()){