shithub: mc

ref: 6565eb50cfcc4e11ed5e350cdae30dc861dc0a8e
dir: /test/loop.myr/

View raw version
use std
/* checks that loops work. */
const main = {
	var i
	var n

	n = 0
	for i = 0; i < 5; ++i
		std.put("{}", i)
	;;
	for i = 0; i < 5; ++i
		if i > 3
			break
		;;
		std.put("{}", i)
	;;
	for i = 0; i < 10; ++i
		if i < 6
			continue
		;;
		std.put("{}", i)
	;;
	std.put("\n")
}