feat: support variable declaration statement

This commit is contained in:
Lucàs
2024-07-03 00:18:17 +02:00
parent 69e88fd5fd
commit 9d3fa71e34
6 changed files with 131 additions and 4 deletions
+26
View File
@@ -0,0 +1,26 @@
// Déclaration d'une variable de type entier
var a: entier = 4 + 2 + 3 * 1;
/*
SourceFile([
VariableStatement([
VariableDeclaration(
Type_Integer,
Identifier("a"),
BinaryExpression(
Add,
BinaryExpression(
Add,
Literal(Integer(4)
),
Literal(Integer(2))
),
BinaryExpression(
Multiply,
Literal(Integer(3)),
Literal(Integer(1))
))
)]
)]
)
*/