On 01/31/10 08:12, Larry Evans wrote:
On 01/31/10 07:20, Hicham Mouline wrote: [snip]
Because all the members of params are double, there is no way to differentiate between different the 1st and 2nd vector<double>
Yes; however, Couldn't you, pair each type with it's index? IOW, you have, instead of:
typedef package_c
::pkg_type fields_t ; from my earlier attachment, you have:
enum field_names { field_1 , field_2 ... , field_n }; typedef package < pair
, vector<double> > , pair , vector<double> > ... , pair , vector > ... > fields_t ; Then, the resulting cross_product would be a sequence of pairs from which you could generate a fusion map. [snip]
Such a sequence of sequence of fusion::pair's is generated by the
attached. Generating a fusion map from a sequence of fusion::pairs
has not been done. I didn't see any hint here:
http://www.boost.org/doc/libs/1_41_0/libs/fusion/doc/html/fusion/container/g...
about how to do that. Output from attached is:
--{--output--
absent_fields_seq=
( name=1, type=1)
( name=2, type=2)
( name=3, type=1)
size