summaryrefslogtreecommitdiff
path: root/Test/inline/expansion4.bpl
blob: be11a391e6da74537a713f19b6036f0bedfdc73f (plain)
1
2
3
4
5
6
7
8
9
function foo(x:int) : int
  { if x <= 0 then 1 else foo(x - 1) + 2 }

procedure bar()
{
  assert foo(0) == 1;
  assert foo(1) == 3;
  assert foo(2) == 5;
}