Error out on invalid form for `parseTypedDeclaration`
parent
eca6acf4bf
commit
aa8c23b4c7
|
@ -5,6 +5,7 @@ import std.conv : to;
|
|||
import std.string : isNumeric, cmp;
|
||||
import compiler.symbols : SymbolType;
|
||||
import compiler.lexer : Token;
|
||||
import core.stdc.stdlib;
|
||||
|
||||
public final class Parser
|
||||
{
|
||||
|
@ -199,6 +200,11 @@ public final class Parser
|
|||
|
||||
gprintln("ParseTypedDec: VariableDeclarationWithAssingment: (Type: "~type~", Identifier: "~identifier~")", DebugType.WARNING);
|
||||
}
|
||||
else
|
||||
{
|
||||
gprintln("Expected one of the following: (, ; or =", DebugType.ERROR);
|
||||
exit(0);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue