aboutsummaryrefslogtreecommitdiff
path: root/tests/conformance/3-expressions/const_expr_local_const.zc
blob: 46a8d55766d9e4dbb5cc32ac4616bea0601f3354 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
// expect: 5/11/7/
include rt;
void pn(int x) { rt.put_n(x); rt.put_c(10); }
fn main() {
	const n = 5;
	const m = n * 2 + 1;
	int[m] a;
	const int k = 7;
	pn(n); pn(len(a)); switch (7) { case k: pn(k); }
	return 0;
}