Subject: Re: [boost] [msm] triggering of a transition on a subclass event does not work on sub state machines in case of favor_compile_time policy is used.
From: Christophe Henry (christophe.j.henry_at_[hidden])
Date: 2011-01-16 16:18:17


> Hi All
>
> I have run it to a problem that feature : Event Hierarchy see doc :
> http://svn.boost.org/svn/boost/trunk/libs/msm/doc/HTML/ch03s02.html#d0e1108
>
> Does not work in case of sub state machine with favor_compile_time
> policy. No trans get called on the sub state machine even it has a row
> with event type to the event base class.
>
> This now hit me badly because compiler runs out of heap if
> favor_compile_time policy is not used but when it is used I can not
> dispatch based on base type and I have about 150 different event so
> declare a transition for it is a no go.
>
> Is there any workaround for this problem ?.

Hi Richard,

It took a while but I now committed a solution into the trunk (rev.
68194). Could you please give it a try? It passes my tests but
double-checking cannot hurt.
It's actually a complete reimplementation of the feature, without
boost::any. The advantages:
- it supports event hierarchy
- it compiles slightly faster
- it runs much faster
- it requires no rtti

I hope it solves your problem. Please let me know.
It's not a major change so I could merge it into 1.46, but only if you
manage to test it until Monday evening. Otherwise, you'll have to use
the trunk version until 1.47.

Regards,
Christophe