auto_ptr in exception safety design

Joined
Feb 12, 2008
Messages
108
Reaction score
0
Hello everyone,


What I am confused is about,

http://www.gotw.ca/gotw/059.htm

--------------------
Indeed, often the best way to implement the Pimpl idiom is exactly as shown in Example 4 above, by using a pointer (in order to take advantage of nonthrowing operations) while still wrapping the dynamic resource safely in an auto_ptr manager object. Just remember that now your object must provide its own copy construction and assignment with the right semantics for the auto_ptr member, or disable them if copy construction and assignment don't make sense for the class.
--------------------

1. What means "the right semantics for the auto_ptr member"?

2. "disable" means for the class, copy construction and assignment are not needed? Curious. Never thought of a class which does not need that two basic functions. :)


thanks in advance,
George
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,046
Latest member
Gavizuho

Latest Threads

Top