comparison bin/gs2c.py @ 12097:c9f5afad5250 draft

<fizzie> sled /hackenv/bin/gs2c.py//s|bin/gs2.py|/hackenv/bin/gs2.py|
author HackEso <hackeso@esolangs.org>
date Sat, 16 Nov 2019 22:25:06 +0000
parents c989a1669243
children
comparison
equal deleted inserted replaced
12096:98ed38b7d553 12097:c9f5afad5250
8 if sys.platform == "win32": 8 if sys.platform == "win32":
9 import os, msvcrt 9 import os, msvcrt
10 msvcrt.setmode(sys.stdout.fileno(), os.O_BINARY) 10 msvcrt.setmode(sys.stdout.fileno(), os.O_BINARY)
11 11
12 mnemonics = {} 12 mnemonics = {}
13 with open('bin/gs2.py') as f: 13 with open('/hackenv/bin/gs2.py') as f:
14 for line in f: 14 for line in f:
15 if '#=' in line: 15 if '#=' in line:
16 a, b = line.split('#=') 16 a, b = line.split('#=')
17 a = re.findall(r'\\x(..)', a.strip()) 17 a = re.findall(r'\\x(..)', a.strip())
18 b = b.strip().split(', ') 18 b = b.strip().split(', ')