Self-test questions
For multiple choice questions, choose all options that apply:
What are the Abraham's Exception Safety Guarantees?
a. Basic, weak, and strong
b. Basic, strong, and no-throw
c. Weak, strong, and no-throw
d. None, basic, and strong
What are the main differences between
boost::scoped_ptr
andstd::unique_ptr
?a.
boost::scoped_ptr
does not support move semanticsb.
std::scoped_ptr
has no partial specialization for arraysc.
std::unique_ptr
can be stored in STL containersd.
std::unique_ptr
supports custom deletersWhy is
boost::shared_ptr
heavier than other smart pointers?a. It uses a shared reference counter
b. It supports both copy and move semantics
c. It uses two allocations per encapsulated object
d. It is not heavier than other smart pointers
What is the disadvantage of using
boost::make_shared
to create ashared_ptr
?a. It is slower than directly instantiating
boost::shared_ptr
b. It is not thread safe
c. It does not release object memory until all
weak_ptr
referents expired. It is not...