Skip to content

Semi-2005/Turkish-Inspired-Programming-Languages

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Turkish-Inspired Programming Language

Java Status Parser Course

Course Information

  • Course: Programming Language
  • Project: Term Project
  • Implementation Language: Java

Overview

This project is a mini programming language inspired by Turkish syntax and keywords. The goal is to design and implement the core front-end components of a compiler.

Implemented Components

  • Lexical Analyzer (Lexer)
  • Recursive Descent Parser
  • Symbol Table
  • Syntax Error Detection
  • Test Case Execution with Sample Source Files

Language Features

  • Variable Declarations
  • Assignment Statements
  • Arithmetic Expressions
  • Conditional Statements (if / else)
  • Loop Structures (while)
  • Block Scope with Braces

Project Structure

src/
 ├── Main.java
 ├── Lexer.java
 ├── Parser.java
 ├── Token.java
 ├── TokenType.java
 └── SymbolTable.java

tests/
 ├── ArithmeticExample.txt
 ├── ConditionalExample.txt
 ├── LoopExample.txt
 └── VariableDeclarationExample.txt

Sample Programs

Sample source codes are located in the tests/ folder.

How to Run

javac src/*.java
java -cp src Main

Example Syntax

tam x;
x = 5 + 3;

eger (x > 5) {
   yaz x;
}

UML Architecture Diagram

+-------------------+
|      Main.java    |
| Program Entry     |
+---------+---------+
          |
          v
+-------------------+
|     Lexer.java    |
| Source Scanner    |
+---------+---------+
          |
          v
+-------------------+
|     Token.java    |
| Token Objects     |
+---------+---------+
          |
          v
+-------------------+
|    Parser.java    |
| Syntax Analyzer   |
+----+---------+----+
     |         |
     v         v
+---------+  +------------------+
|TokenType|  | SymbolTable.java |
| Enum    |  | Variable Storage |
+---------+  +------------------+

Component Responsibilities

  • Main.java → Starts program execution and loads input files.
  • Lexer.java → Converts source code into tokens.
  • Token.java → Stores token type and value.
  • TokenType.java → Defines all token categories using enum.
  • Parser.java → Validates syntax using Recursive Descent Parsing.
  • SymbolTable.java → Stores declared identifiers and metadata.

Development Status

In Progress 🚧

Authors

Programming Languages Course Project Team

About

A mini programming language implementation in Java including Lexer, Recursive Descent Parser, Symbol Table and syntax validation.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages