Skip to content

This repository was created to keep track of my personal learning material for Flex and Bison.

License

Notifications You must be signed in to change notification settings

DahlitzFlorian/learning-flex-bison

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Learning Flex and Bison

Description

This repository was created to keep track of my personal learning material for Flex and Bison. The source code is provided in the src directory, the explanations and notes are stored inside the notes directory.

Build

You can generate the lexcial analyzer and the parser using the build script in the root directory. It expects exactly one parameter, which is the path to the lexical analyzer description. After hitting enter the script will delete the build directory if existing, generate a new one and save the lexical analyzer just there as well as the generated parser and the corresponding header file. Last but not least gcc will create an executable you can run afterwards.

Note: The build script was created for a MacOS system and may not work on other systems. Furthermore, be sure to have Flex and Bison installed!

Example

$ ./build.sh flex/binary.l
$ ./build/binary.exe
1101 + 10 * 11
 = 19

Releases

No releases published

Packages

No packages published