Skip to content

Commit 075ee50

Browse files
committed
Ajout des returns + fix pour les types bools.
1 parent d03e655 commit 075ee50

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/Parser.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ namespace FPL {
2626
"vide",
2727
"auto",
2828
"importer",
29-
"requete",
3029
"convertir",
3130
"bool",
3231
"booleen"
@@ -304,6 +303,11 @@ namespace FPL {
304303
if (CheckerOperateur(";").has_value()) {
305304
fonction.HasReturn = true;
306305
fonction.ReturnIsIdentfiant = true;
306+
if (va->mText == "vrai" || va->mText == "faux") {
307+
fonction.ReturnType = Type("bool", BOOL);
308+
fonction.ReturnIsIdentfiant = false;
309+
fonction.ReturnValue = va->mText;
310+
}
307311
fonction.ReturnIdentifantValue = va->mText;
308312

309313
if (CheckerIdentifiant().has_value() || CheckerValue().has_value() || CheckerType().has_value()) {

0 commit comments

Comments
 (0)