CSE425 Compiler Design Lab

Lab 3 · Lexical analysis with LEX

This lab involves implementing lexical analysis using LEX

Installation

sudo apt-get install bison flex


We use a input file (Game.hx) which contains a sample program written in an pre-assigned language, on which we perform lexical analysis.

flex lex.cpp
g++ lex.yy.c -ll -o main
./main Game.hx >& output


← Lab 2 · All labs · Lab 4 →