diff python/testc3.py @ 162:d8c735dc31f9

Used new editor in ide
author Windel Bouwman
date Sun, 10 Mar 2013 11:36:55 +0100
parents 10330be89bc2
children 8104fc8b5e90
line wrap: on
line diff
--- a/python/testc3.py	Sat Mar 09 15:52:55 2013 +0100
+++ b/python/testc3.py	Sun Mar 10 11:36:55 2013 +0100
@@ -1,8 +1,7 @@
 import c3
 import time, ppci, x86, ir
 
-testsrc = """
-package test;
+testsrc = """package test;
 
 var u32 c, d;
 
@@ -64,6 +63,9 @@
    cg = c3.CodeGenerator()
    x86gen = x86.X86CodeGen(diag)
    p.parseSource(src)
+   ok = len(diag.diags) == 0
+   if not ok:
+      return
    tc.checkPackage(sema.mod)
    print('{0} errors'.format(len(diag.diags)))