summaryrefslogtreecommitdiff
path: root/test/outparam-sl.myr
blob: 78d796346e18272ff3f9eb6d30bc53b86e90de07 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
use std
/* should assign a slice through an out param, returning exiting with 2 */
const arr = [1,2,3,4]
const f = {out
	out# = arr[1:3]
}

const main = {
	var v

	f(&v)
	-> v[0]
}