A use-after-free can compile cleanly yet cause a reliability failure or an exploitable security vulnerability. A C++ compiler checks conformance to the language standard, but it typically cannot see the runtime values and thread ordering on which many memory safety failures depend. section 2.0 section 2.7
A style guide, or coding guideline, is a catalog of rules specifying what source code may contain and what it must not do. In safety-critical development, it translates the language requirements of a safety standard into concrete rules for a disciplined reviewer or tool to check. It is one part of a wider process that also includes verification, documentation, and independent assessment. section 2.0 section 2.7
C++ guidelines restrict error-prone or nondeterministic constructs and patterns that make verification difficult. Static and dynamic analysis can check rules mechanically and produce evidence for certification; a guideline or tool alone is not the whole safety process. section 2.2 section 1.4.3
Choosing a C++ guideline
MISRA C++:2023 targets reliability and certification evidence, with mandatory, required, and advisory rules. CERT C++ adds a security focus, linking applicable rules to known weaknesses. Existing automotive projects may still reference AUTOSAR C++14, although MISRA C++:2023 is its successor for new projects. section 2.2
Table 2.1 Major C++ coding guidelines for safety-critical systems
|
Guidelines
|
C++ Version
|
Number of Rules
|
Primary Domain
|
Status
|
|
MISRA C++:2023
|
17
|
179
|
Automotive, Aerospace, Medical, Rail
|
Current standard
|
|
AUTOSAR C++14
|
14
|
342
|
Automotive
|
Merged into MISRA C++ 2023
|
|
CERT C++
|
11/14
|
83
|
Defense, Connected Systems
|
Active
|
|
HIC++
|
11
|
155
|
Aerospace, UK Defense
|
Active
|
|
JSF C++
|
98/03
|
200+
|
Avionics (F-35)
|
Legacy
|
Compare major C++ guidelines by language version, rule count, domain, and status. section 2.2












