I'm using an hierarchical FSM for an embedded C++ application interface. I'd like to use small functions to determine whether certain inter-state events can be triggered, as well as use them to effect changes in the database: however, making a new class with different event functions for each state is daunting, as well as setting pointers to them as callbacks. (we're talking about 300 functions here.)
If C++ supported lambda functions, I'd use them, but I don't have a lot of weight on the project architecture, so I'm reluctant to use third-party solutions that require heavy library integration (like boost) or the inclusion of extra preprocessor steps.
Any ideas?