|
Boost : |
From: E. Gladyshev (egladysh_at_[hidden])
Date: 2003-10-09 11:28:45
--- David Abrahams <dave_at_[hidden]> wrote:
> Yes, but not for anything else. This is exactly the memcpy trick that
> Eric was referring to earlier. The fact that you spelled it
> "variant_copy" and not "memcpy" doesn't change anything; it has the
> same semantics. I don't know why we have to keep going over the same
> ground over and over again. All of this is in the discussion
> archives. If people would just go back and do some review we could
> avoid lots of wasted bandwidth and, I dare say, aggravation.
variant_copy() is completely defined. Eric's concerns about
memcpy was that is undefinded.
Stop kidding yourself, variant_copy is much more predicable
than new T() that variant is using to provide basic guarantess.
Theretically, if a copy constructor crashes the memory
heap could already be corrupted.
The stack solution is much more safer in this respect
and it provides strong guarantess.
[...]
> No, you can't.
Yes, you can.
Eugene
__________________________________
Do you Yahoo!?
The New Yahoo! Shopping - with improved product search
http://shopping.yahoo.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk