shithub: mc

ref: 7ed35649bb5b7ce79c7a01f1b1d8cb850b8d388a
dir: /lib/json/types.myr/

View raw version
use std

pkg json =
	type elt = union
		`Null
		`Bool	bool
		`Num	flt64
		`Str	byte[:]
		`Arr	elt#[:]
		`Obj	(byte[:], elt#)[:]
	;;

	type err = struct
		e	: errtype
		line	: std.size
		off	: std.size
	;;

	type errtype = union
		`Badesc char
		`Junk char
		`Depth
		`End
	;;
;;