fusion: mpl vector as a fusion vector

Hello by include <fusion/include/mpl.hpp> if I have a mpl::vector<> and I want to use it as a member of a struct. This member will actually hold runtime data. typedef mpl::vector<......> mplvector_t; can I just define it as struct S { mplvector_t m; }; or do I need to do this: struct S { fusion::result_of::as_vector<mplvector_t>::type m; }; and then I can store data in m? Regards,

AMDG Hicham Mouline wrote:
by include <fusion/include/mpl.hpp>
if I have a mpl::vector<> and I want to use it as a member of a struct. This member will actually hold runtime data.
typedef mpl::vector<......> mplvector_t;
can I just define it as struct S { mplvector_t m; };
No this won't work.
or do I need to do this:
struct S { fusion::result_of::as_vector<mplvector_t>::type m; };
and then I can store data in m?
Yes. In Christ, Steven Watanabe
participants (2)
-
Hicham Mouline
-
Steven Watanabe