Skip to content

Commit

Permalink
Add usage for --auto-include
Browse files Browse the repository at this point in the history
  • Loading branch information
ydah committed Oct 15, 2023
1 parent 5cd38d4 commit 7322bbf
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,13 @@ $ lrama -d sample/parse.y
```

```shell
# "calc", "calc.c", and "calc.h" are generated
$ lrama -d sample/calc.y -o calc.c && gcc -Wall calc.c -o calc && ./calc
# "y.tab.c" and "y.tab.h" are generated and added `#include "y.tab.h"`
$ lrama -d sample/parse.y --auto-include
```

```shell
# "calc", "calc.c", and "calc.h" are generated and added `#include "calc.h"`
$ lrama -d sample/calc.y -o calc.c --auto-include && gcc -Wall calc.c -o calc && ./calc
Enter the formula:
1
=> 1
Expand Down

0 comments on commit 7322bbf

Please sign in to comment.