Skip to content

Commit

Permalink
Improved possibility to test current state in orthogonal state machines
Browse files Browse the repository at this point in the history
  • Loading branch information
pborzecki committed Jun 30, 2020
1 parent d3fa5b3 commit 2303acb
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions include/boost/sml.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -1712,8 +1712,11 @@ class sm {
auto result = false;
visit_current_states<T>([&](auto state) {
(void)state;
result |= (aux::get_id<state_t, typename TState::type>((states_ids_t *)0) ==
aux::get_id<state_t, typename decltype(state)::type>((states_ids_t *)0));
if ((aux::get_id<state_t, typename TState::type>((states_ids_t *)0) ==
aux::get_id<state_t, typename decltype(state)::type>((states_ids_t *)0))) {
result = true;
return;
}
});
return result;
}
Expand Down

0 comments on commit 2303acb

Please sign in to comment.