This project was made for the subject of Language processors in University of Lleida (UDL).
Subject directed by Dr.Jordi Planes Cid.
The goal of this project is to develop a simple macro expression processor using a binary tree as a data structure.
- Creating and initializing variables.
x := a + 3; y := x * 2;
- Giving an expression.
y + x + b;
- Creating and initializing variales with a lamda.
h := lamda q , w . 1 + q * w;
- Giving an expression with a lamda.
4 + h a b;
- Giving an expression with lamda that has a variable assigned to a macro.
z := lamda t ,w ,s . 3 + t * s - w; p - z y b c;
- For the given expression in 2.
((a+3)*2)+(a+3)+b
- For the given expression in 4.
4+(1+a*b)
- For the given expression in 5.
p-(3+((a+3)*2)*c-b)
[Lex] - Lexical Parser.
[Yacc] - Sintactical Parser.
[C/C++] - Code implementation.
- Jordi Ricard Onrubia Palacios - Programming - JordiROP
This project is licensed under the MIT License - see the LICENSE.md file for details