Skip to content

supunab/flex_lexical_analyzer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple Lexical Analyzer Using Flex

A simple lexical analyzer built using Flex, following the tutorial on https://www.youtube.com/watch?v=54bo1qaHAfk&t=517s

The lexical analyzer will tokenize the config.in file into tokens and myscanner.c will read the file and perform a basic syntax analysis with error handling.

How to run

Generate the lexical analyzer using lex
lex myscanner.l

Complie the program
gcc myscanner.c lex.yy.c -o myscanner

To test, you can provide input using stdin
./myscanner < config.in

Credits

The source code is implemented based on https://www.youtube.com/watch?v=54bo1qaHAfk&t=517s

About

A simple lexical analyzer built using Flex, following the tutorial on https://www.youtube.com/watch?v=54bo1qaHAfk&t=517s

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages