summaryrefslogtreecommitdiff
path: root/romstr.py
diff options
context:
space:
mode:
authorBryan Bishop <kanzure@gmail.com>2012-07-01 08:55:21 -0500
committerBryan Bishop <kanzure@gmail.com>2012-07-01 08:55:21 -0500
commit2a0389e3842741740ab2809fd0a7149610f8fb32 (patch)
tree344462e89fbcbae6bf8f281f629fba892fe2ae4f /romstr.py
parentbb3ffe4e137d91337f6ba4b2d4b816808039c28e (diff)
use os.path.join instead of cowboying it
original-commit-id: b85d9b86add29a64eec6a48f4a69054641213853
Diffstat (limited to 'romstr.py')
-rw-r--r--romstr.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/romstr.py b/romstr.py
index b5e7d5b..b9c8efd 100644
--- a/romstr.py
+++ b/romstr.py
@@ -50,7 +50,7 @@ class RomStr(str):
""" Loads labels from labels.json, or parses the source code file and
generates new labels.
"""
- filename = os.path.dirname(__file__) + "/" + filename
+ filename = os.path.join(os.path.dirname(__file__), filename)
# blank out the hash
self.labels = {}
@@ -75,7 +75,7 @@ class RomStr(str):
# scan the asm source code for labels
if generate_labels:
- asm = open(os.path.dirname(__file__) + "/../main.asm", "r").read().split("\n")
+ asm = open(os.path.join(os.path.dirname(__file__), "../main.asm"), "r").read().split("\n")
for line in asm:
label = get_label_from_line(line)