summaryrefslogtreecommitdiff
path: root/lib/bio/test/bio-unitwr.myr
blob: f1019274cd24c1c105e04fff980b271294d54aeb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use std
use bio

const main = {
	var f

	std.mkpath("tmpout")
	match bio.create("tmpout/test-unitwr", bio.Wr, 0o644)
	| `std.Ok bio:	f = bio
	| `std.Err m:	std.fatal("Unable to open data file: {}\n", m)
	;;
	bio.putb(f, 42)
	bio.putc(f, 'ה')
	bio.putb(f, 0xa)
	bio.close(f);
}