
Hello, I get another error if I use templated states (gcc-3.4.6). 'simple_state.hpp:403: error: no type named inner_context_type in struct proto<int>' Instantiation of state_machine:: initiate() causes the error. with regards, Oliver #include <iostream> #include <stdexcept> #include <boost/statechart/simple_state.hpp> #include <boost/statechart/state_machine.hpp> namespace sc = boost::statechart; template< typename S > struct proto; template< typename S > struct sm : public sc::state_machine< sm< S >, proto< S >
{}; template< typename S > struct inactive; template< typename S > struct proto : public sc::simple_state< proto< S >, sm< S >, inactive< S >
{}; template< typename S > struct inactive : public sc::simple_state< inactive< S >, proto< S >
{}; int main() { try { sm< int > fsm; fsm.initiate(); // <<== causes compiler error return 0; } catch ( std::runtime_error const& e) { std::cerr << e.what() << std::endl; } catch (...) { std::cerr << "unhandled exception" << std::endl; } return -1; }