Boost logo

Boost :

Subject: Re: [boost] [design] policy based. Was: [XInt] Review
From: JCK (jan.kleinsorge.bulk_at_[hidden])
Date: 2011-03-11 04:51:24


On 03/11/11 02:20 AM, Chad Nelson wrote:
> On Thu, 10 Mar 2011 23:06:46 +0100
> Joachim Faulhaber<afojgo_at_[hidden]> wrote:
>
>
>>> integer_t handles some options, and passes the data to the
>>> implementing class for others. It was the best solution I could find
>>> to handle all options.
>>>
>> [...] I invested some work to make my suggestion about good design
>> more concrete. I will give you a small example of a policy based
>> design that is directly related to some problems of code replication
>> and insufficient separation of concerns in your library. At the same
>> time I hope it'll help to understand policy based design, which
>> includes getting a better understanding for myself. [...]
>>
> I think I see what you're getting at. Thank you. I'll have to think
> about that further to see the best way to implement it.
>

As a side-note, in that context, providing an implementation (sometime
in the future) similar to Microsoft's SafeInt [1] would be an extremely
useful addition to this library. This would be more useful than a simple
binary fail-state, IMHO.

Best regards
Jan

[1] http://msdn.microsoft.com/en-us/library/ms972705


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