Boost logo

Boost :

From: Marcin Kalicinski (kalita_at_[hidden])
Date: 2006-04-19 12:41:14


>>Agreed. I thought about it before, and came to a conclusion that the best
>>way to implement it is to use preprocessor constant to allow user specify
>>default separator, e.g. BOOST_PROPERTY_TREE_SEPARATOR.
>>
>>
> I disagree. I think this should be a runtime per-tree setting, not
> something set at compile time. I also think it would be quite trivial to
> do.

You mean ptree should have additional data member containing default
separator? How do we make sure that all nodes in the tree have the same
separators? Also, this would add some runtime overhead to the library,
storing so many copies of the same character.

As an alternative to macro, it could be a part of the traits. But I think
this solution is too cumbersome to be practical, because user will need to
roll out his own ptree type just to use different default separator. It will
also made trees with different separators incompatible.

Marcin


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