Skip to content

Custom Sharp Compiler is a C# Windows Forms application that serves as a basic compiler, handling lexical analysis, syntax parsing, and error detection for user-provided code.

Notifications You must be signed in to change notification settings

usamafayaz/custom-sharp-compiler

Repository files navigation

Custom Sharp Compiler

Overview

CustomSharpCompiler is a semester project built as a Windows Forms application in C#. It compiles a custom programming language with support for variable declarations, operations, functions, and control structures.

Features

Variable Declaration and Types

Supports variable declarations for:

  • integar
  • decimal
  • match (boolean)
  • key (character)

Arithmetic and Logical Operations

Handles the following operations:

  • Increment: inc
  • Decrement: dec

Functions

Supports function declarations and function calls.

Classes

Allows defining classes using custom syntax.

Input/Output

Supports basic input and output operations.

Conditional Statements

Supports if-else conditions with custom syntax:

  • If: agar
  • Else: magar
  • Else If: agarmagar

Loops

Supports for loops with custom syntax.

Technology Stack

  • Language: C#
  • Framework: Windows Forms
  • Tools: Visual Studio

Installation and Setup

  1. Clone the repository:

    git clone https://github.com/usamafayaz/custom-sharp-compiler.git
  2. Open the project in Visual Studio.

  3. Build the solution:

    Build > Build Solution
  4. Run the application:

    Debug > Start Without Debugging

Contact

For any inquiries, please contact [usama.fayyaz157@gmail.com].

Alt text Alt text

About

Custom Sharp Compiler is a C# Windows Forms application that serves as a basic compiler, handling lexical analysis, syntax parsing, and error detection for user-provided code.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages