|
Boost : |
Subject: Re: [boost] [type_erasure] ODR violation promotion
From: Vicente J. Botet Escriba (vicente.botet_at_[hidden])
Date: 2011-09-09 15:26:17
Le 09/09/11 20:44, Steven Watanabe a écrit :
> AMDG
>
> On 09/09/2011 11:23 AM, Vicente J. Botet Escriba wrote:
>> The example for concept map seams not complete, as the specialization
>> for less_than_comparable<std::type_info> is not used in any type erasure
>> type. Could you complete it?
>>
> What more do you want to see?
>
> Something like this:
>
> {
> any<less_than_comparable<>, _self&> t1(typeid(int));
> any<less_than_comparable<>, _self&> t2(typeid(double));
> bool b = t1< t2; // b == typeid(int).before(typeid(double))
> }
>
> I had assumed that this would be obvious. I'd
> rather not clutter the examples too much. The
> important part is the specialization.
I would prefer an example that uses the specialization, but of course It
is up to you to include whatever you want.
>> Before the Boost.Conversion review someone signaled that the
>> Boost.Conversion review was promoting ODR violations as two libraries
>> could specialize a conversion for types S and T and make them
>> incompatible for an end user as the ODR is violated.
>>
>> I think that your library suffer from the same issue, when two libraries
>> need to specialize a concept provided by the library for a 3rd part
>> concrete class using the proposed concept map mechanism. Do you agree?
>> If not, how do the library avoids this kind of issue?
>>
> I have no intention of trying to deal with it.
> As far as I'm concerned it's the responsibility
> of whoever defines the specializations. I'm
> not going to worry about it at all until I
> hear reports of it causing real problems, as
> opposed to being a purely theoretical concern.
>
>
IIUC you response, you agree that your library has the same problem.
Thanks,
Vicnte
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk