Boost logo

Boost :

Subject: Re: [boost] [review][assign] Formal review of Assign v2 ongoing
From: er (er.ci.2020_at_[hidden])
Date: 2011-06-19 18:36:36


On 6/16/11 5:56 PM, John Bytheway wrote:
> Please consider looking at the library and submitting a review.

And please allow me to spark a bit of interest:

#include <map>
#include <string>
#include <boost/assign/list_inserter.hpp>
#include <boost/assign/v2/include/csv_put_ext.hpp>
#include <boost/range/adaptor/map.hpp>
#include <libs/assign/v2/please_review_assign_v2_thanks.h>

void run()
     {
         typedef std::string str_;
         typedef int int_;
         typedef std::map<str_, int_> map_;
         typedef map_::value_type p_;

         { // STL
             map_ map;
             map.insert( p_("jan", 31) );
             map.insert( p_("feb", 28) );
             map.insert( p_("mar", 31) );
         }
         { // Boost.Assign
             using namespace boost::assign;
             map_ map;
             boost::assign::insert( map )
               ("jan", 31)("feb", 28)("mar", 31);
         }
         { // Boost.Assign 2.0
             using namespace boost::assign::v2;
             map_ map;
             csv_put<2>( map, "jan", 31, "feb", 28, "mar", 31 );
         }
     }

You may recall that 'csv' functions were proposed in the mini-review,
June 2010, and received interest, I think. This time, arity is arbitrary
(I = 2, in this case). Also, it support C++0x, which means, for example,
csv_put<>() is not restrained in number of arguments (in this case,
though, it only makes sense to have at most 12 pairs).

Thanks for your attention.

>
> Where to get it
> ===============
>
> The documentation is online at:
>
> <http://svn.boost.org/svn/boost/sandbox/assign_v2/libs/assign/v2/doc/html/index.html>
>
>
> Review guidelines
> =================
> More detail on the review process is available at:
>
> http://www.boost.org/community/reviews.html
>


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk