[msm] EUML submachine without macro

Hi,
I'm trying to define a submachine without the
BOOST_MSM_EUML_DECLARE_STATE_MACHINE macro (the "old" way - like in
http://www.boost.org/doc/libs/1_46_0/libs/msm/doc/HTML/examples/SimpleTutori...).
The "main" machine works as expected. However, the submachine doesn't kick
in at all (the system asserts in default no-transition handler). Any ideas?
Ray
------------
#include <boost/msm/front/state_machine_def.hpp>
#include <boost/msm/front/euml/euml.hpp>
#include <boost/msm/back/state_machine.hpp>
using namespace std;
using namespace boost::msm::front::euml;
namespace msm = boost::msm;
//#define WITH_MACROS
//************
//* Events
//************
BOOST_MSM_EUML_EVENT(play)
BOOST_MSM_EUML_EVENT(toggle)
//*************
//* Submachine
//*************
#ifdef WITH_MACROS
//************************
//* This works fine
//************************
BOOST_MSM_EUML_ACTION(Song1_Entry)
{
template

Hi,
I'm trying to define a submachine without the BOOST_MSM_EUML_DECLARE_STATE_MACHINE macro (the "old" way - like in http://www.boost.org/doc/libs/1_46_0/libs/msm/doc/HTML/examples/SimpleTutori...). The "main" machine works as expected. However, the submachine doesn't kick in at all (the system asserts in default no-transition handler). Any ideas?
Ray
Hi, you're just a little too fast as I added the example in the 1.47 release. In the meantime, the submachine example can be found there: http://svn.boost.org/svn/boost/trunk/libs/msm/doc/HTML/examples/CompositeTut... It's slightly trickier than the main machine though. You need to define the front-end the "old" way, then inherit from the back-end and euml_state. HTH, Christophe
participants (2)
-
Christophe Henry
-
rayg