hamedkhaledi / Compiler-Project

Projects of compiler course Fall 99

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Decaf Compiler

Compiler Project Fall 1399 - Shahid Beheshti University

About Decaf Language

Decaf is a simple object oriented language similar to C/C++/Java. The features of this language has been simplified to be implemented easier. Yet, it's still powerful enough to be used to write some interesting programs.


Project Description

Description
Scanner

Phases

Scanner Scanner
Parser Scanner
Codegen Scanner

How To Run

1- Compile JFlex

First, you must install Jflex

jflex src/Scanner.flex

or you can use jar file in the project

java -jar src/jflex-1.8.2.jar src/Scanner.flex

2- Compile CUP

cd src/
java -jar java-cup-11b.jar parser.cup

3- Compile Compiler

javac -cp "java-cup-11b.jar:java-cup-11b-runtime.jar:jflex-full-1.7.0.jar Main.java"

Contributers

Hamed Khademi Khaledi

Mohammad Khoddam

Amir Hallaji Bidgoli

About

Projects of compiler course Fall 99

License:MIT License


Languages

Language:Java 97.1%Language:Lex 2.0%Language:Python 0.6%Language:Shell 0.3%Language:CSS 0.0%