A brief introduction to C++’s model for type- and resource-safety -- Stroustrup, Sutter, Dos Reis

A new paper has been posted to the CppCoreGuidelines /docs folder:

A brief introduction to C++’s model for type- and resource-safety 

by Bjarne Stroustrup, Herb Sutter, and Gabriel Dos Reis

The goal of the paper is to provide a readable high-level overview of C++'s existing resource handling model and the extension of that for type safety that was announced at CppCon. A more detailed treatment of lifetime safety (avoiding leaks and dangling) can be found in Herb Sutter's CppCon talk (YouTube) (Channel 9) and Lifetime paper.

From the paper:

Abstract

You can write C++ programs that are statically type safe and have no resource leaks. You can do that without loss of performance and without limiting C++’s expressive power. This model for type- and resource-safe C++ has been implemented using a combination of ISO standard C++ language facilities, static analysis, and a tiny support library (written in ISO standard C++). This supports the general thesis that garbage collection is neither necessary nor sufficient for quality software. This paper describes the techniques used to eliminate dangling pointers and to ensure resource safety. Other aspects – also necessary for safe and effective use of C++ – have conventional solutions so they are mentioned only briefly here.

The techniques and facilities presented are supported by the Core C++ Guidelines [Stroustrup,2015] and enforced by a static analysis tool for those [Sutter,2015].

Add a Comment

Comments are closed.

Comments (0)

There are currently no comments on this entry.