Chapter 11. Writing Exception-Safe Code—Part 4
Mid-series interlude: What have we accomplished so far?
Now that we have implemented an exception-safe and exception-neutral
Stack<T>, answer these questions as precisely as possible:
What are the important exception-safety guarantees?
Stack<T>that was just implemented, what are the requirements on
T, the contained type?
Just as there's more than one way to skin a cat (I have a feeling I'm going to get enraged e-mail from animal lovers), there's more than one way to write exception-safe code. In fact, there are two main alternatives we can choose from when it comes to guaranteeing ...