|
Boost : |
Subject: Re: [boost] quince: queries in C++ expressions
From: Mostafa (mostafa_working_away_at_[hidden])
Date: 2014-07-21 22:33:31
On Mon, 21 Jul 2014 19:25:12 -0700, Michael Shepanski
<mps_at_[hidden]> wrote:
> On 22/07/2014 8:09 AM, Mostafa wrote:
>>
>> That's what I figured, and Boost.Preprocessor could be used to take
>> care of the variadic templates. My only concern, and maybe Michael can
>> chime in here, would be the use of temporaries. In C++11 they could be
>> moved, but in C++03 they may have to be copied, and I wonder if that
>> would become costly with quince's design.
>
> Re temporaries: no alarm bells are going off in my head. I suspect that
> all that's at issue are small-scale optimizations that shouldn't
> influence us unless measurement shows otherwise.
If those temporaries are quince types, they can even be moved in C++03
using Boost.Move.
> Overall comments about replacing variadic templates with
> Boost.Preprocessor and decltype with Boost.TypeOf:
>
> - I experienced some difficulties with internal compiler errors, and
> other discrepancies between compilers. I suspect that a change to
> different mechanisms would produce a different set of such pragmatic
> problems. It may very well be that Boost.Preprocessor and Boost.TypeOf
> lead to *fewer* problems than variadic templates and decltype -- but the
> latter problems have all been worked around already.
>
> - I do like the brevity of expression in C++11.
No arguments there.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk