summaryrefslogtreecommitdiff
path: root/tests/source/locals.scade
blob: 379cbde54f5b1d798c51972fb9e9ac7ab39e879e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
node test(i: int) returns(a, b, c: int; exit: bool)
let
  activate
    if i mod 5 = 0 then
      var x: int;
      let
        x = i;
        a = x;
      tel
    else
      var x: int;
      let
        x = (0 -> pre i);
        a = x;
      tel
  returns a;
  b = 0;
  c = 0;
  exit = i >= 12;
tel