~ Fibnoacci example
~ Calculates a fibonacci pair using recursion

proc fib {x1: Int, x2: Int, n: Int}
	if n = 0
		x1 += 0
		x2 += 1
	else
		n -= 1
		do fib {x1, x2, n}
		x1 += x2
		x1 <> x2
	fi x1 = x2
return

~fn fib
~	0 -> 0
~	1 -> 1
~	n -> fib(n-1) + fib(n-2)
~end

proc main
	var x1 := 0
	var x2 := 0
	var n := 4
	do fib {x1, x2, n}
	drop n := 0
	drop x2 := 5
	drop x1 := 8
return