New Lang is a programming language project written in Go.
- If-Else Expression Evaluation: Supports the evaluation of if-else expressions in the evaluator.
- Infix Expression Evaluation: Supports the evaluation of infix expressions, including operations for integers and booleans.
- Postfix Expression Evaluation: Supports the evaluation of prefix expressions, including handling of the '!' and '-' operators.
To install New Lang, follow these steps:
- Clone the repository:
git clone https://github.com/a-samir97/new-lang.git
- Navigate to the project directory:
cd new-lang
- Build the project:
go build
To use New Lang, run the following command:
./new-lang [options] <input-file>
- ast/: Responsible for defining the Abstract Syntax Tree (AST) for the language. This includes the structures and types used to represent the syntax of the language.
- lexer/: Responsible for lexical analysis. This folder contains the code for breaking down the input source code into tokens that can be further processed by the parser.
- parser/: Responsible for parsing the tokens produced by the lexer into an Abstract Syntax Tree (AST). This folder contains the code for syntactic analysis.
- evaluator/: Contains the code for evaluating the AST nodes. This includes the implementation of evaluation rules for different expressions and statements in the language.
For more details on PRs, you can visit the [pull requests page](https://github.com/a-samir97/new-lang/pulls?state=all).