InconsistentHistoryTest5.cpp 893 B

123456789101112131415161718192021222324252627282930313233343536
  1. //////////////////////////////////////////////////////////////////////////////
  2. // Copyright 2005-2006 Andreas Huber Doenni
  3. // Distributed under the Boost Software License, Version 1.0. (See accompany-
  4. // ing file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  5. //////////////////////////////////////////////////////////////////////////////
  6. #include <boost/statechart/state_machine.hpp>
  7. #include <boost/statechart/simple_state.hpp>
  8. namespace sc = boost::statechart;
  9. namespace mpl = boost::mpl;
  10. struct A;
  11. struct InconsistentHistoryTest : sc::state_machine<
  12. InconsistentHistoryTest, A > {};
  13. struct B;
  14. struct A : sc::simple_state< A, InconsistentHistoryTest, B > {};
  15. struct B : sc::simple_state< B, A > {};
  16. int main()
  17. {
  18. InconsistentHistoryTest machine;
  19. machine.initiate();
  20. // A does not have history
  21. machine.clear_shallow_history< A, 0 >();
  22. return 0;
  23. }