summaryrefslogtreecommitdiff
path: root/test/catfile.myr
blob: b766209f5e10736cca136f31e390e169871ffde5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/* checks that we can read a data file. */
use std

const main = {args : byte[:][:]
	var r

	r = std.slurp("data/catfile-in")
	match r
	| `std.Ok dat: 	std.write(1, dat)
	| `std.Fail msg:	std.put("Failed to read file: %s\n", msg)
	;;
	-> 0
}