]> de.git.xonotic.org Git - xonotic/gmqcc.git/blob - tests/break.qc
moving -Olocal-temps to -O4 until the issues are solved
[xonotic/gmqcc.git] / tests / break.qc
1 void   print(...)   = #1;
2 string ftos (float) = #2;
3
4 void test(float brkat, float contat) {
5     float i;
6
7     for (i = 0; i < 10; i += 1) {
8         if (i == contat) {
9             print("ct ");
10             continue;
11         }
12         print(ftos(i), " ");
13         if (i == brkat) {
14             print("brk ");
15             break;
16         }
17     }
18     print("end\n");
19 }
20
21 void main() {
22     test(-1, -1);
23     test( 3, -1);
24     test(-1,  3);
25     test( 5,  2);
26 }