Skip to content

tmkasun/mini_compiler

master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
asm
 
 
 
 
lex
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Introduction

                              +-------+
                    Source -> |  Lex  |  -> yylex
                              +-------+

                              +-------+
                    Input ->  | yylex | -> Output
                              +-------+
                          An overview of Lex
  • This repository contains components of a compiler in order to learn the basics of compilers

  • Some codes are real implimentations of video tutorials and stanford online course

                      lexical        grammar
                       rules          rules
                         |              |
                         v              v
                    +---------+    +---------+
                    |   Lex   |    |  Yacc   |
                    +---------+    +---------+
                         |              |
                         v              v
                    +---------+    +---------+
           Input -> |  yylex  | -> | yyparse | -> Parsed input
                    +---------+    +---------+
    
    
                          Lex with Yacc
    

Tools and Softwares

  • I have used lex/flex for build scanner/lexical analizer and YACC/BISON for syntax parsing.jFLAP for building NFAs and conver them DFA.And you can do quite a lot of work other than what I have mentioned here.

Usage

  • Clone the repository and go through the source before run
  • Some may have precompiled bineries

About

Academic project theory of compilers

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published