mirror of https://github.com/falsovsky/z80.git
Forgot to close
This commit is contained in:
parent
db3541fde4
commit
4614ab4c58
|
@ -9,13 +9,14 @@ if len(sys.argv) < 2:
|
||||||
|
|
||||||
allowed_chars = (">", "<", "+", "-", ".", ",", "[", "]")
|
allowed_chars = (">", "<", "+", "-", ".", ",", "[", "]")
|
||||||
|
|
||||||
file = open(sys.argv[1], 'r')
|
f = open(sys.argv[1], 'r')
|
||||||
print "ORG $9400"
|
print "ORG $9400"
|
||||||
sys.stdout.write("src db \"")
|
sys.stdout.write("src db \"")
|
||||||
for char in file.read():
|
for char in f.read():
|
||||||
if char in allowed_chars:
|
if char in allowed_chars:
|
||||||
sys.stdout.write(char)
|
sys.stdout.write(char)
|
||||||
else:
|
else:
|
||||||
continue
|
continue
|
||||||
print "\", 0"
|
print "\", 0"
|
||||||
|
f.close()
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue