You've already forked pokecrystal-board
mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2025-09-08 08:13:02 -07:00
load labels only once in gbz80disasm
This commit is contained in:
@@ -557,6 +557,11 @@ call_commands = [0xdc, 0xd4, 0xc4, 0xcc, 0xcd]
|
|||||||
all_labels = {}
|
all_labels = {}
|
||||||
def load_labels(filename="labels.json"):
|
def load_labels(filename="labels.json"):
|
||||||
global all_labels
|
global all_labels
|
||||||
|
|
||||||
|
# don't re-load labels each time
|
||||||
|
if all_labels != {}:
|
||||||
|
return
|
||||||
|
|
||||||
if os.path.exists(filename):
|
if os.path.exists(filename):
|
||||||
all_labels = json.read(open(filename, "r").read())
|
all_labels = json.read(open(filename, "r").read())
|
||||||
else:
|
else:
|
||||||
|
Reference in New Issue
Block a user