Skip to content

UmairMirza1/Roman-Urdu-Compiler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

66 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ROMAN URDU COMPILER

.ru is our file extension abbreviation of "Roman Urdu" for this Compiler This readMe contains Phases that the parser has been implemented in.

Steps to run

- cd main
- make 
- ./a.out <filename>

Grammar

We start by defining Regular Definition

Implementation

PHASE 1

Lexer

There is just one complete DFA in the Tokenizer Function image

Whenever we hit a final state , we go into the else part of the that specific case.

  • We keep track of the currentLexeme
  • Once we hit a final state , We add the Pair to the tokens array
  • Reset the DFA back to state 0 which would be our case 0
  • Reset the lexeme
  • Decrement the iterator in cases where there can be two different Tokens that can occur without a space

PHASE 2

Parser

Context Free Grammar is given in CFG.txt

PHASE 3

Translation scheme

Translation Scheme is given in Translation scheme.pdf

PHASE 4

Virtual Machine

Final product

image

About

Yet another programming language but in Roman urdu

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published