Any chance to pass an Action via an Event
Open
question
- Dominant language
- C++
- Stars
- 1.2k
- Forks
- 193
- PR merge metrics
- No merged PRs in 30d
Description
Probably this is more a general C++ question than it is a tinyfsm one, but maybe somebody did this already.
I have an event called ShouldEstimateAndSend which transits to a new state on a few conditions. I'd like to have it call transit\(ShoudEstimateAndSend::action_function).
Using std::function would work, but this introduces some runtime overhead and pulls in exception handling which is not what I like on my embedded target. Using a template event class 'breaks' inheritance and would need a template react function as far as I can see?!
Can't wiggle my head around this.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.