Skip to content

Commit 2b490fc

Browse files
committed
final
1 parent eafcd88 commit 2b490fc

File tree

238 files changed

+8987
-3053
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

238 files changed

+8987
-3053
lines changed

.DS_Store

10 KB
Binary file not shown.

aaaa.tam

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
PUSH 1
2+
STORE (1) 0[CB]
3+
JUMP FUNC_Fighter_1_END
4+
FUNC_Fighter_1_START:
5+
PUSH 0
6+
FUNC_Fighter_1_END:
7+
HALT
8+

lexer.jflex

+18
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ ContenuCommentaire = ( [^*] | \*+[^*/] )*
6666
Chaine = \" ([^\"] | \\\") * \"
6767
Caractere = \' ([^\\] | \\\\) \'
6868

69+
Identificateur_Type = [:uppercase:] ([:jletterdigit:] | [:jletter:] | "_" )*
6970
Identificateur = ([:jletter:] | "_" ) ([:jletterdigit:] | [:jletter:] | "_" )*
7071

7172

@@ -131,10 +132,27 @@ Identificateur = ([:jletter:] | "_" ) ([:jletterdigit:] | [:jletter:] | "_" )*
131132
"fst" { return symbolFactory.newSymbol("Premier", UL_Premier); }
132133
"snd" { return symbolFactory.newSymbol("Second", UL_Second); }
133134
"while" { return symbolFactory.newSymbol("Tant que", UL_Tant_Que); }
135+
"interface" { return symbolFactory.newSymbol("Interface", UL_Interface); }
136+
"extends" { return symbolFactory.newSymbol("Extends", UL_Extends); }
137+
"final" { return symbolFactory.newSymbol("Final", UL_Final); }
138+
"abstract" { return symbolFactory.newSymbol("Abstract", UL_Abstract); }
139+
"public" { return symbolFactory.newSymbol("Public", UL_Public); }
140+
"private" { return symbolFactory.newSymbol("Private", UL_Private); }
141+
"static" { return symbolFactory.newSymbol("Static", UL_Static); }
142+
"class" { return symbolFactory.newSymbol("Class", UL_Class); }
143+
"implements" { return symbolFactory.newSymbol("Implements", UL_Implements); }
144+
"protected" { return symbolFactory.newSymbol("Protected", UL_Protected); }
145+
"this" { return symbolFactory.newSymbol("This", UL_This); }
146+
"construct" { return symbolFactory.newSymbol("Construct", UL_Construct); }
147+
"String[] args" { return symbolFactory.newSymbol("String[] args", UL_ARGS); }
148+
"super" { return symbolFactory.newSymbol("super", UL_SUPER); }
149+
150+
134151
{Caractere} { return symbolFactory.newSymbol("Caractère", UL_Caractere, yytext()); }
135152
{Chaine} { return symbolFactory.newSymbol("Chaine de caractères", UL_Chaine, yytext()); }
136153
{Entier} { return symbolFactory.newSymbol("Nombre Entier", UL_Nombre_Entier, yytext()); }
137154
{Flottant} { return symbolFactory.newSymbol("Nombre Flottant", UL_Nombre_Flottant, yytext()); }
155+
{Identificateur_Type} { return symbolFactory.newSymbol("Identificateur_Type", UL_Identificateur_Type, yytext()); }
138156
{Identificateur} { return symbolFactory.newSymbol("Identificateur", UL_Identificateur, yytext()); }
139157
}
140158

0 commit comments

Comments
 (0)