[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

*From*: Stephan Merz <stephan.merz@xxxxxxxxx>*Date*: Sun, 9 Jun 2019 18:46:25 +0200*References*: <3c1c1132-b17a-40f4-8503-6d92e8ce13bf@googlegroups.com>

Hello, Evaluate == \E u \in U : /\ u.status="started" /\ U' = IF Predicate(u) THEN (U\{u}) \cup {termUpdate(u)} ELSE (U\{u}) \cup {denUpdate(u)} Using a set of records is most appropriate when your specification handles a set of objects that are not known a priori. If the set of objects is fixed (say, with oid as the key for identifying objects) then you could represent the state of these objects using a table (a TLA+ function) and write your action along the lines of the following Evaluate == \E oid \in OID : /\ obj[oid].status = "started" /\ obj' = [obj EXCEPT ![oid].status = IF Predicate(obj[oid]) THEN "terminated" ELSE "denied"] Stephan
You received this message because you are subscribed to the Google Groups "tlaplus" group. To unsubscribe from this group and stop receiving emails from it, send an email to tlaplus+unsubscribe@xxxxxxxxxxxxxxxx. To post to this group, send email to tlaplus@xxxxxxxxxxxxxxxx. Visit this group at https://groups.google.com/group/tlaplus. To view this discussion on the web visit https://groups.google.com/d/msgid/tlaplus/12958B59-6019-4BCF-B751-1C611CBA0545%40gmail.com. For more options, visit https://groups.google.com/d/optout. |

**Follow-Ups**:**Re: [tlaplus] A problem in expressing a step***From:*groban

**Re: [tlaplus] A problem in expressing a step***From:*Leslie Lamport

**References**:**[tlaplus] A problem in expressing a step***From:*groban

- Prev by Date:
**[tlaplus] A problem in expressing a step** - Next by Date:
**Re: [tlaplus] A problem in expressing a step** - Previous by thread:
**[tlaplus] A problem in expressing a step** - Next by thread:
**Re: [tlaplus] A problem in expressing a step** - Index(es):