aboutsummaryrefslogtreecommitdiff
path: root/tests/conformance/4-statements/uninit_outparam_ok.zc
blob: e97f54bbb17c8f17446cfe59e366c7e6854fa7e8 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
// expect: 7/
// spec 4.1.5: passing &x counts as initializing x
include rt;
void pn(int x) { rt.put_n(x); rt.put_c(10); }
void fill(int* p) { *p = 7; }
fn main() {
	int x;
	fill(&x);
	pn(x);
	return 0;
}
// zc0: skip