shithub: mc

ref: c827bfd2eb941cfdccf9cb2a1b6e50c24af5049e
dir: /test/matchbind.myr/

View raw version
type u = union
	`Int int
	`Chr char
	`Nil
;;

const main = {
	var v

	v = `Int 11
	match v
	`Int 127:
		-> 42
		;;
	`Int x:
		-> x
		;;
	`Chr 'a':
		-> 4
		;;
	`Nil:
		-> 6
		;;
	;;
}