Added struct parsing support to `parse` (for top-evel parsing)

entity_declaration_type_checking
Tristan B. Kildaire 4 years ago
parent 017ef66d81
commit 5cee963957

@ -1116,6 +1116,14 @@ public final class Parser
/* Add the class definition to the program */
modulle.addStatement(clazz);
}
/* If it is a struct definition */
else if(symbol == SymbolType.STRUCT)
{
Struct ztruct = parseStruct();
/* Add the struct definition to the program */
modulle.addStatement(ztruct);
}
else
{
expect("parse(): Unknown '" ~ tok.getToken() ~ "'");

@ -30,7 +30,10 @@ class kl
}
struct structTest
{
}
class Shekshi
{

Loading…
Cancel
Save