User Tools

Site Tools


c_exceptions

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
c_exceptions [2018/02/02 11:02]
rpjday [Error handling possibilities]
c_exceptions [2018/02/02 11:02] (current)
rpjday [Guarantees]
Line 22: Line 22:
 C++ standard library provides one of the following guarantees for every library operation: C++ standard library provides one of the following guarantees for every library operation:
  
-  * //basic// for all operations: The basic invariants of all objects are maintained, and no resources, such as memory, are leaked. In particular, the basic invariants of every built-in and standard-library type guarantee that you can destroy an object or assign to it after every standard-library operation (§iso.17.6.3.1).+  * //basic// for all operations: The basic invariants of all objects are maintained, and no resources, such as memory, are leaked. In particular, the basic invariants of every built-in and standard-library type guarantee that //you can destroy an object or assign to it after every standard-library operation// (§iso.17.6.3.1).
   * //strong// for key operations: in addition to providing the basic guarantee, either the operation succeeds, or it has no effect. This guarantee is provided for key operations, such as ''​push_back()'',​ single-element ''​insert()''​ on a list, and ''​uninitialized_copy()''​.   * //strong// for key operations: in addition to providing the basic guarantee, either the operation succeeds, or it has no effect. This guarantee is provided for key operations, such as ''​push_back()'',​ single-element ''​insert()''​ on a list, and ''​uninitialized_copy()''​.
   * //nothrow// for some operations: in addition to providing the basic guarantee, some operations are guaranteed not to throw an exception. This guarantee is provided for a few simple operations, such as ''​swap()''​ of two containers and ''​pop_back()''​.   * //nothrow// for some operations: in addition to providing the basic guarantee, some operations are guaranteed not to throw an exception. This guarantee is provided for a few simple operations, such as ''​swap()''​ of two containers and ''​pop_back()''​.
  
c_exceptions.txt · Last modified: 2018/02/02 11:02 by rpjday