aboutsummaryrefslogtreecommitdiff
path: root/tests/conformance/4-statements/uninit_struct_init_ok.zc
blob: ab033ae4bed38e7f30a8b919cb0a67eeb232aaf7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
// expect: 9/
// spec 4.1.5: while(1) always enters, so an assignment before break initializes
include rt;
void pn(int x) { rt.put_n(x); rt.put_c(10); }
fn main() {
	int x;
	while (1) { x = 9; break; }
	pn(x);
	return 0;
}
// zc0: skip