Boost logo

Boost :

Subject: Re: [boost] Boost Fusion suggestion
From: Joel de Guzman (joel_at_[hidden])
Date: 2012-03-28 01:35:10


On 3/28/2012 3:03 AM, Pavel Bažant wrote:
> I am not actually a Boost developer, but have the following suggestion
> regarding boost.fusion:
> I find the macro
> BOOST_FUSION_DEFINE_STRUCT
> potentially very useful, but it does not provide means to influence
> the initialization list of the default constructor. Alternatively,
> means to emulate c++11 default initialization (the struct Foo {int
> x=10;} syntax) could be emulated. Such feature would be very useful,
> as it would minimize repetition and make it easier to ensure that
> uninitialized variables are nowhere used.
>
> I already generate my structs from BOOST_PP sequences in a similar way
> to BOOST_FUSION_DEFINE_STRUCT to avoid having to write json
> serialization boilerplate, but a variant of BOOST_FUSION_DEFINE_STRUCT
> i am suggesting would make this task even simpler.

I've been meaning to cleanup the macros as they are currently in an
unwieldy state. If you have interest in this and want to contribute
some, that would be great. Feel free to email me privately and tell
me more about your ideas.

Regards,

-- 
Joel de Guzman
http://www.boostpro.com
http://boost-spirit.com

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