CERT
Skip to end of metadata
Go to start of metadata

The C++ Standard, [intro.scope], paragraph 2 [ISO/IEC 14882-2014] states the following:

C++ is a general purpose programming language based on the C programming language as described in ISO/IEC 9899:1999 Programming languages—C (hereinafter referred to as the C standard). In addition to the facilities provided by C, C++ provides additional data types, classes, templates, exceptions, namespaces, operator overloading, function name overloading, references, free store management operators, and additional library facilities.

Because C++ is based on the C programming language, there is considerable overlap between the guidelines specified by the SEI CERT C Coding Standard and those specified by this coding standard. To reduce the amount of duplicated information, this coding standard focuses on the parts of the C++ programming language that are not wholly covered by the CERT C Coding Standard. Because of the increased focus on types in C++, some rules in C are extended by the CERT C++ Secure Coding Standard. Except where noted, the contents of the CERT C Coding Standard apply equally to code written in C++.  Contents from the CERT C Coding Standard that apply to the CERT C++ Coding Standard are described in each related chapter of the C++ standard.

The following guidelines from the CERT C Coding Standard do not apply to the CERT C++ Secure Coding Standard:

 

 

2 Comments

  1. The following guidelines from the CERT C Coding Standard do not apply to the CERT C++ Secure Coding Standard:

    I wonder about the value of listing the rules that do not apply to C++...wouldn't it be more valuable to list the C rules that do apply to C++? That would be more relevant to the book.

    1. We list all of the rules that do apply in each individual chapter (and MSC lists rules from all of the chapters that don't exist in the C++ book but still apply, like PRE). I don't know if the above list still holds value for the book, however – we may want to simply remove it. I don't know that listing all of the rules that do apply, in a single location, makes a whole lot of sense though (for the same reason we don't have a master list of all C++ rules in one table).