diff python/zcc.py @ 213:003c8a976fff

Merge of semantics and parser again ..
author Windel Bouwman
date Fri, 05 Jul 2013 11:18:48 +0200
parents 8b2f20aae086
children 494828a7adf1
line wrap: on
line diff
--- a/python/zcc.py	Sun Jun 30 19:00:41 2013 +0200
+++ b/python/zcc.py	Fri Jul 05 11:18:48 2013 +0200
@@ -1,6 +1,6 @@
 #!/usr/bin/python
 
-import sys, os, argparse
+import sys, argparse
 import c3, ppci, codegen
 import arm_cm3
 import codegenarm
@@ -8,7 +8,8 @@
 
 # Parse arguments:
 parser = argparse.ArgumentParser(description='lcfos Compiler')
-parser.add_argument('source', type=argparse.FileType('r'), help='the source file to build')
+parser.add_argument('source', type=argparse.FileType('r'), \
+  help='the source file to build')
 parser.add_argument('-d', '--dumpir', action='store_true', help="Dump IR-code")
 parser.add_argument('-o', '--output', help='Output file', metavar='filename')
 
@@ -45,7 +46,6 @@
     # TODO: store data
 
 if __name__ == '__main__':
-    args = parser.parse_args()
-    print(args, type(args))
-    main(args)
+    arguments = parser.parse_args()
+    main(arguments)