This project is a simple C compiler written in Rust, currently supporting basic lexing for a subset of C code.
compiler– The main Rust project folderdriver.rs– Entry point that runs the compilerlexer.rs– Performs lexical analysis and generates tokens
- Lexical analysis of simple C programs
- Supports the following tokens:
- Keywords:
int,void,return - Identifiers (e.g.,
main) - Constants (integer numbers)
- Symbols:
(,),{,},;
- Keywords:
- Prints all tokens in order for debugging
- Parser
- Code Emission
- more Syntax