SCION-CORE icon indicating copy to clipboard operation
SCION-CORE copied to clipboard

Allow states to be initial and final states.

Open davidkpiano opened this issue 9 years ago • 3 comments

It's legal for states to be an initial and a final state, especially in machines with only one state. Right now, the $type only supports either INITIAL or FINAL (among other choices).

davidkpiano avatar Oct 05 '15 15:10 davidkpiano

Can initial states be final? Would that be something like this?

<state id="p">
    <final id="q"/>
</state>

mogsie avatar Dec 18 '15 12:12 mogsie

It's not very useful, but yeah, I'd imagine initial states can be final states. No reason why not.

davidkpiano avatar Dec 19 '15 01:12 davidkpiano

Both SCXML and Statecharts have special syntaxes for initial states and for final states, and so the $type attribute is a carry-over of that special syntax requirement.

@davidkpiano Can you provide a use case for this? Thank you.

jbeard4 avatar Jan 12 '16 02:01 jbeard4