blob: a285401ec8bfa51136bd4c62cefbc055b92e4395 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#!/usr/bin/env python3
import sys
from lexer import lexer
with open(sys.argv[1], "rb") as f:
data = f.read()
data2 = data.decode("ascii")
lexer.input(data2)
while True:
tok = lexer.token()
if not tok:
break
print(tok)
|