Boost logo

Boost :

Subject: Re: [boost] [conversion] review
From: Emil Dotchevski (emildotchevski_at_[hidden])
Date: 2011-08-31 17:11:35


On Wed, Aug 31, 2011 at 1:13 PM, Gordon Woodhull <gordon_at_[hidden]> wrote:
>
> On Aug 31, 2011, at 3:01 PM, Emil Dotchevski wrote:
>>
>> To be fair, function templates can be specialized without defining a
>> main template, and in that case you get the same amount of coupling as
>> when you use regular functions.
>>
>> I do agree however that the call syntax should not rely on <>. One
>> reason is that it turns off ADL. Another reason is that sometimes an
>> implicit conversion to match an existing non-template overload is
>> preferable to instantiating a template.
>
> The function overload customization point in Conversion uses a dummy parameter and no <>.  convert_to<> is a just a more pleasant wrapper over that.  So I think these language features are still available.

What makes it more pleasant? Is it more convenient? In what use cases?

Emil Dotchevski
Reverge Studios, Inc.
http://www.revergestudios.com/reblog/index.php?n=ReCode


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