2010-06-21 12:11:06 +02:00
|
|
|
(* pour debugger
|
|
|
|
set arguments -v test/good/t4.ept *)
|
|
|
|
|
|
|
|
node f() returns (o:int)
|
|
|
|
var nat, nat2, r:int;
|
|
|
|
let
|
|
|
|
nat = 0 -> pre nat + 1;
|
|
|
|
reset
|
|
|
|
nat2 = 0 -> pre nat2 + 1;
|
|
|
|
reset
|
|
|
|
r = 0 -> pre r + 1;
|
|
|
|
every (true -> pre r = 4)
|
|
|
|
every (true -> pre nat2 = 10);
|
|
|
|
o = r + nat;
|
|
|
|
tel
|
|
|
|
|
|
|
|
node g(x: int) returns (o: int)
|
|
|
|
let
|
|
|
|
automaton
|
|
|
|
state A do o = 1 until x = 1 then B
|
|
|
|
state B do o = 0 until x = 1 then A
|
|
|
|
end
|
|
|
|
tel
|
|
|
|
|
2012-07-18 16:54:44 +02:00
|
|
|
node main() returns (o1,o2:int)
|
|
|
|
let
|
|
|
|
o1 = f();
|
|
|
|
o2 = g(o1 / 10);
|
|
|
|
tel
|