Py2Cpp is a python compiler developed using C++. It focuses on implementing the lexical analysis and syntax analysis phases of a compiler. This project includes a fully functional GUI, a symbol table, error handling mechanisms, and parse tree generation.
This project was created as part of the Design of Compilers course at Ain Shams University, Spring 2025.
- Lexical analysis with token generation
- Syntax analysis using recursive descent parser
- Symbol table with GUI view
- Error handling (lexical and syntactic)
- Parse tree visualization (Graphviz integration)
- Modern C++ with Qt-based GUI
Ensure the following dependencies are installed on your system:
- C++ Compiler supporting C++20
- CMake version 3.16 or higher
- Qt 5 or 6 development libraries
- Graphviz (for parse tree visualization)
🛠️ On Debian-based systems:
sudo apt install build-essential cmake qtbase5-dev graphviz
🛠️ On Windows:
Clone the repository
git clone https://github.com/ysif9/Python-Compiler.git
cd Python-CompilerCreate a build directory
mkdir build && cd buildConfigure the project
cmake ..Build the executable
makeRun the application
./Python-Compiler- Add Screenshots
- Yousif Abdulhafiz - @ysif9
- Philopater Guirgis - @Philodoescode
- Hams Hassan - @Hams2305
- Ahmed Lotfy - @dark-hunter0
- Jana Sameh - @janasameh7
- Ahmed Al-amin - @Ahmed-Al-amin