diff options
author | alon@honor <none@none> | 2010-09-03 23:04:23 -0700 |
---|---|---|
committer | alon@honor <none@none> | 2010-09-03 23:04:23 -0700 |
commit | 8181e238184e170ec31bab865859e7c9294824a4 (patch) | |
tree | 6987f555d57d2dfa1a53a924bbe38958a0b9986b /tests | |
parent | c1f71fad78b739ee6963735c00fd336375c3b117 (diff) |
support for global consts
Diffstat (limited to 'tests')
-rw-r--r-- | tests/runner.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/runner.py b/tests/runner.py index 68904978..4aab0970 100644 --- a/tests/runner.py +++ b/tests/runner.py @@ -157,6 +157,7 @@ class T(unittest.TestCase): def test_intvars(self): src = ''' #include <stdio.h> + int global = 20; int main() { int x = 5; @@ -165,6 +166,7 @@ class T(unittest.TestCase): y += 1; int w = x*3+4; int k = w < 15 ? 99 : 101; + k += global; int i = k > 100; // Should be an int, not a bool! int j = i << 6; j >>= 1; @@ -177,7 +179,7 @@ class T(unittest.TestCase): return 0; } ''' - self.do_test(src, '*5,23,10,19,101,1,37,1,0*') + self.do_test(src, '*5,23,10,19,121,1,37,1,0*') def test_floatvars(self): src = ''' |