module ec_modes language "EC:2010" { testcase tc0() runs on c1 { label b0 cont{ onentry{ //OK, need to apply restrictions A:=2.0; } inv{ A > C //DOES THIS MAKE SENSE? } //OK // // A := 5.0; B := 4.0; wait(200); onexit{ //OK, need to apply restrictions A := 1.0; } } until{ [notinv]{log("bla"); goto b1} [A > 1 and B < 2] {log("blablabla"); continue; repeat;} []p.receive(1) {log("blabla"); goto b0} [finished]{log("finished!")} } //OK cont {} until {} //OK with option UntilGuardList cont {} until{(a>b)} //OK //cont {} until{()} //this is absurd and should not be accepted cont {} until{[notinv]{log("bla");}} //OK //TODO: need further examples with until blocks and guards label b1; cont {} until {(A>now)}; //ok cont {} until {(A>duration)}; //ok } testcase tc1() runs on c1 { cont { seq { cont {} until {(A==B)} cont {} cont {} par { cont {} cont {} } until {(A>X)} } until { (X == Y) } } } mode ModeType mode1 (in float p1, in integer p2, in ModeType m3) runs on c1 { m3(p1, p2, m3); } type mode ModeType (in float p1, in integer p2, in ModeType m3); }