Boost logo

Boost :

Subject: Re: [boost] [xint] Boost.Move vs Copy-on-Write timings
From: Chad Nelson (chad.thecomfychair_at_[hidden])
Date: 2010-05-04 19:32:01


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 05/04/2010 02:02 PM, Mathias Gaunard wrote:

>> On 05/04/2010 06:08 AM, Mathias Gaunard wrote:
>>
>>>> _attach attaches the result to the target by adjusting the pointers
>>>> where possible, and copying if necessary. Copying is usually only
>>>> necessary for fixed_integer types, and only in some of the detail
>>>> functions.
>>>
>>> Sounds like what operator= does.
>>
>> operator= is implemented by a call to _attach, in all three of the
>> integer types.
>
> Then what's the point of providing two names for the same function?

_attach works across all three integer types, and doesn't need to return
anything. operator= needs to return the type that it converts to, and
thus has to be defined separately for all three types.
- --
Chad Nelson
Oak Circle Software, Inc.
*
*
*
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkvgrnEACgkQp9x9jeZ9/wROogCfX8q99B6pX+WRdcRt4fq1OkAa
SgsAoPgAYjIwfBYajFrQiY05ZJFEmCZ7
=gzTc
-----END PGP SIGNATURE-----


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