This commit is contained in:
Sven Heidemann
2020-05-25 21:05:52 +02:00
parent b01204fdd4
commit 9b25f36eb3
6 changed files with 32 additions and 7 deletions

View File

@@ -58,3 +58,13 @@ class Repo:
print(outp_toks)
# print('\n')
def output_ast(self) -> None:
if len(self.ast) > 0:
outp_toks = []
for tok in self.ast:
outp_toks.append({tok.value: tok.type})
# print({tok.value: tok.type})
print(outp_toks)
# print('\n')