heptagon/test/good/tt.ept

34 lines
500 B
Text
Raw Normal View History

2011-05-23 14:04:11 +02:00
node f(x:bool;c:bool) returns (o:bool)
2011-05-23 09:24:57 +02:00
let
2011-05-23 14:04:11 +02:00
automaton
state A
var l:bool; do
l = x when c;
o = merge c (true -> l) (false -> false)
until true then B
state B
do o = false
end
2011-05-23 09:24:57 +02:00
tel
2012-07-18 16:54:44 +02:00
node main() returns (o:bool)
let
o = f(true, true)
tel
2011-05-23 14:04:11 +02:00
(*
node clock_on<<pref, per : int>>(w1, w2 : bool) returns (o : bool)
2011-05-23 09:24:57 +02:00
let
2011-05-23 14:04:11 +02:00
automaton
state FirstPeriod
var w2' : bool; do
w2' = w1 when w2;
o = false;
until true then Cruise
state Cruise do
o = true;
2011-05-23 14:04:11 +02:00
end
2011-05-23 09:24:57 +02:00
tel
2011-05-23 14:04:11 +02:00
*)