Boost logo

Boost :

From: Aleksey Gurtovoy (agurtovoy_at_[hidden])
Date: 2007-08-14 09:02:49

Martin Apel wrote in message
> Aleksey Gurtovoy wrote:
>> All in all, to get the behavior you want with the current library you
>> need to actually merge two maps into a third one.

> I'm not sure, if I understand this correctly. What is the recommended
> way of merging two maps into a third one? Is it possible with the
> current MPL implementation?


> I only found an map::insert metafunction
> to insert a single element, but not a whole range of pairs.

You can actually to do something along these lines (untested):

typedef copy<
    , inserter< map0<>, insert<_1,_2> >
>::type JointMap;

Aleksey Gurtovoy
MetaCommunications Engineering

Boost list run by bdawes at, gregod at, cpdaniel at, john at