>Is it possible to use MSM to create a parentstate "StateEval" with
substates "StateEven", "StateOdd", "StateFloat" ?,
> the idea being to make transition_table as short as
possible.
>
>Something like this maby (but it does not work
>
> struct transition_table :
mpl::vector<
> Row<StateEval, EventT,
StateEval::StateEven, none, none>,
>
Row<StateEval, EventT, StateEval::StateOdd, none,
GuardToOdd>,
> Row<StateEval, EventT,
StateEval::StateFloat, none, GuardToFloat>
>
>{};
>
>
>Basically: is it possible to create a parentstate, that listens to
events (even when an inner substate is already active)?
>
>Thanks.
>nicesw123
You want a submachine named StateEval and 3 substates inside, called
StateEven, StateOdd, and StateFloat.
Then you want 3 direct entries (which I dislike as it is a fsm goto, please
consider direct entry transitions, on the above page).
Then you save some transitions by having in your current fsm transitions
originate from StateEval instead of substates. Correct?
HTH,
Christophe