Boost logo

Boost :

From: Daniel Frey (d.frey_at_[hidden])
Date: 2002-07-03 09:18:11


On Wed, 2002-07-03 at 15:23, Joel de Guzman wrote:
>
> David Abrahams wrote:
>
> >I've got no problem with accepting this patch, provided:
> >
> >1. It passes all the existing tests, with BOOST_NO_NRVO in both states
> >2. Aleksey and Daryle agree
> >3. The macros are prefixed with BOOST_

OK, although they are (currently) only temporary inside the
operators.hpp, #undef-ed after they are used.

> >4. The backslashes are lined up for readability (emacs has a key which does
> >this):

The final patch will contain it :)

> May I suggest that the macros be placed in an independent hpp file? This
> should be
> useful for those who want to take advantage of the optimizations but do
> not need
> the boost operators library.

A good idea, I also though about this when writing the new header. The
problem is to find an appropriate syntax, as it's not just the functions
body that is affected, but also the parameters (by-value vs.
by-const-reference). For the work-around of different compilers, I don't
know if there are lots of implementations needed. I identified two (NRVO
and NO_NRVO), plus the work-around for the Intel compiler which I don't
consider to be necessary. We can use the old implementation as long as
the compiler doesn't fix the bug. Even the new implementation would
work, it would just be sub-optimal :)

Anyway, if you have compilers that I don't have and you are able to show
that they need just another implementation, please tell me and I see
what needs to be done.

Regards, Daniel


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