|
Boost Users : |
Subject: Re: [Boost-users] Adding more than 20 rows in transition table for Boost::MSM
From: Yechiel Levi (yechiel_at_[hidden])
Date: 2014-09-23 07:48:56
I have went through the code over and over.
#include "File_Meta_FSM.h" -- ( this does not have any boost includes at
all)
#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 // or whatever you need
#define FUSION_MAX_VECTOR_SIZE 30 // or whatever you need
#include "boost/mpl/vector/vector30.hpp"
#include <boost/msm/back/state_machine.hpp>
//front-end
#include <boost/msm/front/state_machine_def.hpp>
#include <boost/msm/front/functor_row.hpp>
// for And_ operator
#include <boost/msm/front/euml/operator.hpp>
////MSM.cpp
namespace MSM
{
namespace msm = boost::msm;
namespace mpl = boost::mpl;
namespace msmf = boost::msm::front;
using namespace msmf::euml;
... struct declaration , and other state machine implementations.
....
}
This following errors:
builder1: Compiling /home/yechiel/git_trunk/Infra/FSM.cpp
builder1: In file included from /usr/local/include/boost/mpl/erase.hpp:19,
builder1: from
/usr/local/include/boost/fusion/mpl/erase.hpp:10,
builder1: from /usr/local/include/boost/fusion/mpl.hpp:20,
builder1: from
/usr/local/include/boost/fusion/include/mpl.hpp:11,
builder1: from
/usr/local/include/boost/msm/back/state_machine.hpp:30,
builder1: from File_Meta_FSM.cpp:18:
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:56: error: â_â
was not declared in this scope
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:56: error: â_â
was not declared in this scope
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:56: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:56: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:57: error:
template argument 3 is invalid
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:62: error: â_â
was not declared in this scope
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:62: error: â_â
was not declared in this scope
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:62: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:62: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/mpl/aux_/erase_impl.hpp:63: error:
template argument 3 is invalid
builder1: In file included from /usr/local/include/boost/mpl/insert.hpp:19,
builder1: from
/usr/local/include/boost/fusion/mpl/insert.hpp:10,
builder1: from /usr/local/include/boost/fusion/mpl.hpp:24,
builder1: from
/usr/local/include/boost/fusion/include/mpl.hpp:11,
builder1: from
/usr/local/include/boost/msm/back/state_machine.hpp:30,
builder1: from File_Meta_FSM.cpp:18:
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:53: error: â_â
was not declared in this scope
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:53: error: â_â
was not declared in this scope
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:53: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:53: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:54: error:
template argument 3 is invalid
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:59: error: â_â
was not declared in this scope
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:59: error: â_â
was not declared in this scope
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:59: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:59: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/mpl/aux_/insert_impl.hpp:60: error:
template argument 3 is invalid
builder1: In file included from /usr/local/include/boost/parameter.hpp:18,
builder1: from
/usr/local/include/boost/msm/back/state_machine.hpp:51,
builder1: from File_Meta_FSM.cpp:18:
builder1: /usr/local/include/boost/parameter/preprocessor.hpp:88: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/parameter/preprocessor.hpp:88: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/parameter/preprocessor.hpp:88: error:
template argument 1 is invalid
builder1: In file included from
/usr/local/include/boost/msm/mpl_graph/detail/incidence_list_graph.ipp:38,
builder1: from
/usr/local/include/boost/msm/mpl_graph/incidence_list_graph.hpp:18,
builder1: from
/usr/local/include/boost/msm/back/metafunctions.hpp:50,
builder1: from
/usr/local/include/boost/msm/back/state_machine.hpp:57,
builder1: from File_Meta_FSM.cpp:18:
builder1: /usr/local/include/boost/mpl/equal.hpp:98: error: â_â was not
declared in this scope
builder1: /usr/local/include/boost/mpl/equal.hpp:98: error: â_â was not
declared in this scope
builder1: /usr/local/include/boost/mpl/equal.hpp:98: error: template
argument 1 is invalid
builder1: /usr/local/include/boost/mpl/equal.hpp:98: error: template
argument 2 is invalid
builder1: /usr/local/include/boost/mpl/equal.hpp:108: error: template
argument 3 is invalid
builder1: /usr/local/include/boost/mpl/equal.hpp:108: error: template
argument 3 is invalid
builder1: /usr/local/include/boost/mpl/equal.hpp:108: error: template
argument 1 is invalid
builder1: /usr/local/include/boost/mpl/equal.hpp:108: error: template
argument 3 is invalid
builder1: /usr/local/include/boost/mpl/equal.hpp:108: error: template
argument 1 is invalid
builder1: /usr/local/include/boost/mpl/equal.hpp:108: error: template
argument 3 is invalid
builder1: /usr/local/include/boost/mpl/equal.hpp:108: error: template
argument 1 is invalid
builder1: In file included from
/usr/local/include/boost/msm/back/state_machine.hpp:62,
builder1: from File_Meta_FSM.cpp:18:
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp: In
constructor âboost::msm::back::dispatch_table<Fsm, Stt, Event,
CompilePolicy>::dispatch_table()â:
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:358: error:
â_â is not a member of âboost::mpl::placeholdersâ
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:358: error:
â_â is not a member of âboost::mpl::placeholdersâ
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:358: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:358: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:359: error:
â_â is not a member of âboost::mpl::placeholdersâ
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:359: error:
â_â is not a member of âboost::mpl::placeholdersâ
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:359: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:359: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:360: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:360: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:361: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:383: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/dispatch_table.hpp:383: error:
invalid type in declaration before â;â token
builder1: In file included from File_Meta_FSM.cpp:18:
builder1: /usr/local/include/boost/msm/back/state_machine.hpp: At global
scope:
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:111: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:111: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:111: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:112: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:114: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:114: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:114: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:115: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:117: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:117: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:117: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:118: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:121: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:121: error:
â_â is not a member of âboost::mplâ
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:121: error:
template argument 1 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:122: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:123: error:
template argument 2 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:123: error:
template argument 3 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:123: error:
template argument 4 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:123: error:
template argument 5 is invalid
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:123: error:
invalid type in declaration before â;â token
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:149: error:
wrong number of template arguments (1, should be 3)
builder1: /usr/local/include/boost/parameter/binding.hpp:44: error:
provided for âtemplate<class Parameters, class Keyword, class Default>
struct boost::parameter::bindingâ
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:149: error:
expected â{â before â::â token
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:150: error:
invalid type in declaration before â,â token
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:150: error:
declaration of âtypeâ not in a namespace surrounding â::â
builder1: /usr/local/include/boost/msm/back/state_machine.hpp:150: error:
âtypeâ should have been declared inside â::â
If i remove the //#define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS i get:
builder1: from File_Meta_FSM.cpp:12:
builder1: /usr/local/include/boost/proto/transform/when.hpp:243: error:
wrong number of template arguments (30, should be 20)
builder1: /usr/local/include/boost/mpl/aux_/preprocessed/gcc/map.hpp:22:
error: provided for âtemplate<class T0, class T1, class T2, class T3, class
T4, class T5, class T6, class T7, class T8, class T9, class T10, class T11,
class T12, class T13, class T14, class T15, class T16, class T17, class
T18, class T19> struct boost::mpl::mapâ
builder1: Execution failed: Command exit with 1
Any idea?
On Sep 22, 2014 10:12 PM, "Christophe Henry" <
christophe.j.henry_at_[hidden]> wrote:
> >You think the problem is with states?
>
> I try to guess without seeing code...
>
> >But before I defined the mpl no preprocessed header macro all compiles
> well except that I have 21 states which is beyond the limit
>
> Then itâs definitely wrong.
> Frankly, donât rely too much on the compiler to not compile if you
> exceed the limit. I once saw a fsm with 40 transitions and 30 states and
> gcc never complained, never understood why.
>
> >When I define the no preprocessed header macro I get this weird warnings.
> >Do I need to define those macros in my dependencies project as well?
> Since they use some boost..
>
> You need to define it in the TU including the msm headers. If you include
> msm from a header (which you should avoid) you might get a conflict so
> youâd have to define it for all, which would everywhere increase
> compile-times so donât do it.
>
> _______________________________________________
> 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