|
Boost Users : |
Subject: Re: [Boost-users] [msm] more than 10 states causes long compilationerror
From: Raj Sambasivan (rajinikanth_at_[hidden])
Date: 2014-07-04 02:28:27
thanks that fixed it!
On Fri, Jul 4, 2014 at 6:48 AM, <christophe.j.henry_at_[hidden]> wrote:
> Hi,
> unfortunately, fusion uses a different default than mpl.
> You need:
> #define FUSION_MAX_VECTOR_SIZE 20
>
> See: http://www.boost.org/doc/libs/1_55_0/libs/msm/doc/HTML/ch05.html
>
> HTH,
> Christophe
>
> *From:* Raj Sambasivan <rajinikanth_at_[hidden]>
> *Sent:* Friday, July 04, 2014 12:02 AM
> *Newsgroups:* gmane.comp.lib.boost.user
> *To:* boost-users_at_[hidden]
> *Subject:* [msm] more than 10 states causes long compilationerror
>
> Hi,
> I get a long compilation error when i include the last line,
> i tried including
>
> #define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
>
> #define BOOST_MPL_LIMIT_VECTOR_SIZE 30 // or whatever you need
>
> #define BOOST_MPL_LIMIT_MAP_SIZE 30
>
> but still have the same problem, compilation error is at the bottom.
>
> any help?
>
>
> struct transition_table: boost::mpl::vector<
>
> Row<Empty, NewOrderRequest, PendingNew, handleNewOrderRequest>,
>
>
>
> Row<PendingNew, AckedResponse, Acked, handleAckedResponse>,
>
> Row<PendingNew, OrderRejectedResponse, OrderRejected,
> handleOrderRejectedResponse>,
>
> Row<PendingNew, CancelRequest, PendingCancel, handleCancelRequest>,
>
>
>
> Row<PendingCancel, CanceledResponse, Canceled,
> handleCanceledResponse>,
>
> Row<PendingCancel, CancelRejected, CancelRejected,
> handleCancelRejectedResponse>,
>
>
>
> Row<PendingReplace, ReplacedResponse, Replaced,
> handleReplacedResponse>,
>
> Row<PendingReplace, ReplaceRejected, ReplaceRejected,
> handleReplaceRejectedResponse>,
>
> Row<Acked, CancelRequest, PendingCancel,
> handleCancelRequest>,
>
>
>
> Row<Acked, FilledResponse, Filled, handleFilledResponse>
>
> >
>
> {
>
> };
>
>
>
>
>
> compilation error (truncated)
>
> g++ -I/boost_1_55_0/ -c -Wall test.cpp
>
> In file included from test.cpp:1:
>
> In file included from ./Order.H:11:
>
> In file included from /boost_1_55_0/boost/msm/back/state_machine.hpp:28:
>
> In file included from /boost_1_55_0/boost/fusion/include/as_set.hpp:10:
>
> */boost_1_55_0/boost/fusion/container/set/convert.hpp:24:30: **error: *
> *implicit*
>
> * instantiation of undefined template
> 'boost::fusion::detail::as_set<11>'*
>
> typedef typename gen::
>
> * ^*
>
> */boost_1_55_0/boost/msm/back/state_machine.hpp:1164:50: note: *in
> instantiation
>
> of template class
>
> 'boost::fusion::result_of::as_set<boost::mpl::s_item<Filled,
>
> boost::mpl::s_item<ReplaceRejected, boost::mpl::s_item<Replaced,
>
> boost::mpl::s_item<CancelRejected, boost::mpl::s_item<Canceled,
>
> boost::mpl::s_item<OrderRejected, boost::mpl::s_item<Acked,
>
> boost::mpl::s_item<PendingReplace, boost::mpl::s_item<PendingCancel,
>
> boost::mpl::s_item<PendingNew, boost::mpl::s_item<Empty,
>
> boost::mpl::set0<mpl_::na> > > > > > > > > > > > >' requested here
>
> typedef typename ::boost::fusion::result_of::as_set<state_list>::typ...
>
> * ^*
>
> *test.cpp:5:37: note: *in instantiation of template class
>
> 'boost::msm::back::state_machine<<anonymous>::order_,
>
> boost::parameter::void_, boost::parameter::void_,
> boost::parameter::void_,
>
> boost::parameter::void_>' requested here
>
> std::cout << " -> " << state_names[o.current_state()[0]] << std::endl;
>
> * ^*
>
> */boost_1_55_0/boost/fusion/container/set/detail/as_set.hpp:26:12: note: *
>
> template is declared here
>
> struct as_set;
>
> * ^*
>
> In file included from test.cpp:1:
>
> In file included from ./Order.H:11:
>
> In file included from /boost_1_55_0/boost/msm/back/state_machine.hpp:28:
>
> In file included from /boost_1_55_0/boost/fusion/include/as_set.hpp:10:
>
> */boost_1_55_0/boost/fusion/container/set/convert.hpp:25:26: **error: *
> *'apply'*
>
> * following the 'template' keyword does not refer to a template*
>
> template apply<typename
> result_of::begin<Sequence>::type>::type
>
> * ^~~~~*
>
> *test.cpp:5:38: **error: **expected ']'*
>
> *...*
>
>
>
>
> ------------------------------
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>
>
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net