CodeCheck Documentation CodeCheck Documentation - Uncategorized Checks |
Check ID | Check Name | Supported | Severity |
---|---|---|---|
AC_00 | No Control Code Characters | Yes | |
AC_01 | No Direct or Indirect Recursion | Yes | |
AC_HIS_02 | Number of Paths(PATH) | Yes | |
AC_HIS_04 | Cyclomatic Complexity (v(G)) | Yes | |
AC_HIS_05 | Calling Functions (CALLING) | Yes | |
AC_HIS_06 | Called Functions (CALLS) | Yes | |
AC_HIS_07 | Function Parameters (PARAM) | Yes | |
AC_HIS_08 | Number of Staments (STMT) | Yes | |
AC_HIS_09 | Number of call levels (LEVEL) | Yes | |
AC_HIS_10 | Number of return points (RETURN) | Yes | |
AC_HIS_11 | Language scope (VOCF) | Yes | |
AC_HIS_12 | Recursion (AP_CG_CYCLE) | Yes | |
AC_HIS_13 | Statements Changed (SCHG) | Yes | |
AC_HIS_14 | Statements Deleted (SDEL) | Yes | |
AC_HIS_15 | New Statements (SNEW) | Yes | |
AC_HIS_16 | Stability Index (S) | Yes | |
ADA_N000 | Naming Convention: Components | Yes | |
ADA_N001 | Naming Convention: Entries | Yes | |
ADA_N002 | Naming Convention: Enumerations | Yes | |
ADA_N003 | Naming Convention: Exceptions | Yes | |
ADA_N004 | Naming Convention: Files | Yes | |
ADA_N005 | Naming Convention: Functions | Yes | |
ADA_N006 | Naming Convention: Implicits | Yes | |
ADA_N007 | Naming Convention: Objects | Yes | |
ADA_N008 | Naming Convention: Packages | Yes | |
ADA_N009 | Naming Convention: Parameters | Yes | |
ADA_N010 | Naming Convention: Procedures | Yes | |
ADA_N011 | Naming Convention: Protected Entities | Yes | |
ADA_N012 | Naming Convention: Tasks | Yes | |
ADA_N013 | Naming Convention: Types | Yes | |
ADA_V000 | Unused Variables | Yes | |
ADA_V001 | Variables should be commented | Yes | |
ADA_V002 | Magic Numbers | Yes | |
ARR39-C | Do not add or subtract a scaled integer to a pointer | Yes | High |
CC_PLUG_DUPLICATES | Duplicate Lines of Code | Yes | Informational |
CC_PLUG_FILE_DUPLICATES | File Duplicate Lines of Code | Yes | Informational |
CPP_A000 | Assembler instructions only use asm keyword | Yes | |
CPP_A001 | Assembly language shall be encapsulated and isolated. | Yes | |
CPP_A002 | Assignment Operator Return This | Yes | |
CPP_A003 | Assignment Operator Self Assignment | Yes | |
CPP_A004 | Parameter of assignment operator is a constant reference | Yes | |
CPP_A005 | Move and copy assignment operators shall either move or respectively copy base classes and data members of a class, without any side effects | Yes | |
CPP_A006 | The asm declaration shall not be used. | Yes | |
CPP_A007 | Assembler instructions shall only be introduced using the asm declaration. | Yes | |
CPP_A008 | Assembly Language Code Usage not Documented | Yes | |
CPP_A009 | User-defined copy and move assignment operators should use user-defined no-throw swap function. | Yes | |
CPP_A010 | Move constructor shall not initialize its class members and base classes using copy semantics. | Yes | |
CPP_A011 | A copy assignment and a move assignment operators shall handle self-assignment. | Yes | |
CPP_A012 | Copy and move constructors and copy assignment and move assignment operators shall be declared protected or defined "=delete" in base class. | Yes | |
CPP_A013 | Assignment operators should be declared with the ref-qualifier &. | Yes | |
CPP_A014 | The semantic equivalence between a binary operator and its assignment operator form shall be preserved | Yes | |
CPP_A015 | An assignment operator shall return a reference to "this" | Yes | |
CPP_A016 | In a class template with a dependent base, any name that may be found in that dependent base shall be referred to using a qualified-id or this-> | Yes | |
CPP_A017 | A template should check if a specific template argument is suitable for this template | Yes | |
CPP_AO000 | Assignment operators shall not be used in sub-expressions | Yes | |
CPP_B000 | Bool, Unsigned, or Signed Bit-fields | Yes | |
CPP_B001 | ( Fuzzy parser ) Bit-fields shall only be declared with an appropriate type | Yes | |
CPP_B002 | Enum Bit-fields | Yes | |
CPP_B003 | The underlying bit representations of floating-point values shall not be used | Yes | |
CPP_B004 | ( Fuzzy parser ) Named bit-fields with signed integer type shall have a length of more than one bit. | Yes | |
CPP_B005 | ( Fuzzy parser ) Single-bit named bit fields shall not be of a signed type | Yes | |
CPP_B006 | Bit-field Length | Yes | |
CPP_C000 | Commented Out Code | Yes | |
CPP_C001 | Line-splicing shall not be used in // comments | Yes | |
CPP_C002 | No Nested Comments | Yes | |
CPP_C003 | Only use /* comments | Yes | |
CPP_C004 | Parameter of copy constructor is a constant reference | Yes | |
CPP_C005 | Members in function-try-blocks in constructors or destructors | Yes | |
CPP_C006 | Explicitly call all immediate and virtual base classes | Yes | |
CPP_C007 | A copy constructor shall be declared when there is a template constructor with a single parameter that is a generic parameter | Yes | |
CPP_C008 | A copy constructor shall only initialize its base classes and the non-static members of the class of which it is a member | Yes | |
CPP_C009 | Explicit Constructors | Yes | |
CPP_C010 | Incomplete constructor initialization list | Yes | |
CPP_C011 | An object's dynamic type shall not be used from the body of its constructor or destructor | Yes | |
CPP_C012 | Virtual Function Call In Constructor | Yes | |
CPP_C013 | The statement forming the body of a switch, while, do ... while or for statement shall be a compound statement | Yes | |
CPP_C014 | Dangling Else | Yes | |
CPP_C015 | A for loop shall contain a single loop-counter which shall not have floating-point type | Yes | |
CPP_C016 | An if ( condition ) construct shall be followed by a compound statement. The else keyword shall be followed by either a compound statement, or another if statement | Yes | |
CPP_C017 | The body of an iteration-statement or a selection-statement shall be a compound-statement | Yes | |
CPP_C018 | Any label referenced by a goto statement shall be declared in the same block, or in a block enclosing the goto statement | Yes | |
CPP_C019 | A loop-control-variable other than the loop-counter shall not be modified within condition or expression | Yes | |
CPP_C020 | If loop-counter is not modified by -- or ++, then, within condition, the loop-counter shall only be used as an operand to <=, <, > or >= | Yes | |
CPP_C021 | The loop-counter shall be modified by one of: --, ++, -= n, or += n; where n remains constant for the duration of the loop | Yes | |
CPP_C022 | The loop-counter shall not be modified within condition or statement | Yes | |
CPP_C023 | The goto statement shall jump to a label declared later in the same function body | Yes | |
CPP_C024 | No Continue Statements | Yes | |
CPP_C025 | Goto Statements | Yes | |
CPP_C026 | There should be no more than one break or goto statement used to terminate any iteration statement | Yes | |
CPP_C027 | Member data in non-POD class types shall be private | Yes | |
CPP_C028 | A null statement shall only occur on a line by itself | Yes | |
CPP_C029 | Single exit point at end | Yes | |
CPP_C030 | A switch-label shall only be used when the most closely-enclosing compound statement is the body of a switch statement | Yes | |
CPP_C031 | Switch Has Default | Yes | |
CPP_C032 | Every switch statement shall have at least two switch-clauses | Yes | |
CPP_C033 | An unconditional throw or break statement shall terminate every non-empty switch-clause | Yes | |
CPP_C034 | Unreachable Code | Yes | |
CPP_C035 | No Backslash at End of Comment | Yes | |
CPP_C036 | If statements shall not have assignments in the conditions | Yes | |
CPP_C037 | Documentation | Yes | |
CPP_C038 | Before preprocessing, a null statement shall only occur on a line by itself; it may be followed by a comment, provided that the first character following the null statement is a white-space character | Yes | |
CPP_C039 | A switch statement shall have at least two case-clauses, distinct from the default label | Yes | |
CPP_C040 | A loop-control-variable other than the loop-counter which is modified in statement shall have type bool | Yes | |
CPP_C041 | Do statements should not be used | Yes | |
CPP_C042 | For-init-statement and expression should not perform actions other than loop-counter initialization and modification | Yes | |
CPP_C043 | Checked exceptions that could be thrown from a function shall be specified together with the function declaration and they shall be identical in all function declarations and for all its overriders. | Yes | |
CPP_C044 | Continue Statement Used in a not Well-formed For Loop | Yes | |
CPP_C045 | Write constructor member initializers in the canonical order | Yes | |
CPP_C046 | Switch Statement not Well-formed | Yes | |
CPP_C047 | All if and else if constructs shall be terminated with an else clause | Yes | |
CPP_C049 | Class Constructor with Parameter Type std::initializer_list | Yes | |
CPP_C050 | A for-loop that loops through all elements of the container and does not use its loop-counter shall not be used | Yes | |
CPP_C051 | Constructors that are not noexcept shall not be invoked before program startup | Yes | |
CPP_C052 | If a constructor is not noexcept and the constructor cannot finish object initialization, then it shall deallocate the object's resources and it shall throw an exception | Yes | |
CPP_C053 | Explicit Calls to Constructors of Temporary Objects | Yes | |
CPP_C054 | When a "deep copy" constructor is not implemented, comments in the class header shall describe this fact | Yes | |
CPP_C055 | Constructors that can be used with one argument should be declared explicit. | Yes | |
CPP_C056 | Move and copy constructors shall move and respectively copy base classes and data members of a class, without any side effects | Yes | |
CPP_CF000 | The condition of a switch statement shall not have bool type | Yes | |
CPP_CF001 | All cases in a switch statement shall have a break or it shall be well commented | Yes | |
CPP_CF002 | Switch statements should have a default case | Yes | |
CPP_CF003 | Switch label unstructured | Yes | |
CPP_CF004 | The std::terminate() function shall not be called implicitly | Yes | |
CPP_CF005 | Program shall not be abruptly terminated | Yes | |
CPP_CF006 | Simple Control Flow | Yes | |
CPP_CF007 | Loops with Fixed Limits | Yes | |
CPP_CM000 | Comments shall precede code being commented and shall align with code they represent | Yes | |
CPP_CM001 | Each function shall end with a comment | Yes | |
CPP_CM002 | Timing delays shall be preceded by comments explaining the delay | Yes | |
CPP_CM003 | Class headers shall include a short description for every member function declaration and a comment for every data member declared | Yes | |
CPP_CT_BUGPRONE_ASSERT_SIDE_EFFECT | Assert Side Effect | Yes | High |
CPP_CT_BUGPRONE_BRANCH_CLONE | Branch Clone | Yes | High |
CPP_CT_BUGPRONE_COPY_CONSTRUCTOR_INIT | Copy Constructor Init | Yes | High |
CPP_CT_BUGPRONE_INFINITE_LOOP | Infinte Loop | Yes | High |
CPP_CT_BUGPRONE_MACRO_REPEATED_SIDE_EFFECTS | Macro Side Effects | Yes | High |
CPP_CT_BUGPRONE_NOT_NULL_TERMINATED_RESULT | Missing Null Terminator | Yes | High |
CPP_CT_BUGPRONE_REDUNDANT_BRANCH_CONDITION | Redundant Condition | Yes | High |
CPP_CT_MODERNIZE_USE_DEFAULT_MEMBER_INIT | Default Member Init | Yes | |
CPP_CT_MODERNIZE_USE_EQUALS_DEFAULT | Default Member Function | Yes | |
CPP_CT_MODERNIZE_USE_EQUALS_DELETE | Delete Member Function | Yes | |
CPP_CT_MODERNIZE_USE_NULLPTR | Null Pointer Keyword | Yes | |
CPP_CT_READABILITY_DELETE_NULL_POINTER | Delete Null Pointer | Yes | High |
CPP_CT_READABILITY_REDUNDANT_CASTING | Redundant Cast | Yes | High |
CPP_D000 | An accessible base class shall not be both virtual and non-virtual in the same hierarchy | Yes | |
CPP_D001 | Do not delete a polymorphic object without a virtual destructor | Yes | |
CPP_D002 | Single Declarations | Yes | |
CPP_D003 | When an array is declared with external linkage, its size shall be stated explicitly or defined implicitly by initialisation | Yes | |
CPP_D004 | A u or U suffix shall be applied to all integer constants that are represented in an unsigned type | Yes | |
CPP_D005 | A base class shall only be declared virtual if it is used in a diamond hierarchy | Yes | |
CPP_D006 | Class Derived From Virtual Bases | Yes | |
CPP_D007 | A compatible declaration shall be visible when an object or function with external linkage is defined | Yes | |
CPP_D008 | A copy assignment operator shall be declared when there is a template assignment operator with a parameter that is a generic parameter | Yes | |
CPP_D009 | Multiple declarations for an identifier in the same namespace shall not straddle a using-declaration for that identifier | Yes | |
CPP_D010 | = construct in enumerator list shall only be used on either the first item alone, or all items explicitly. | Yes | |
CPP_D011 | Use the static keyword for internal linkage | Yes | |
CPP_D012 | An external object or function shall be declared in one and only one file | Yes | |
CPP_D013 | An identifier with external linkage shall have exactly one definition | Yes | |
CPP_D015 | Externals shall have the same type in the declaration and definition | Yes | |
CPP_D017 | Non-static Inline Functions | Yes | |
CPP_D018 | Literal suffixes shall be upper case | Yes | |
CPP_D019 | The comma operator, && operator and the || operator shall not be overloaded | Yes | |
CPP_D020 | The lowercase character L shall not be used in a literal suffix | Yes | |
CPP_D021 | Narrow and wide string literals shall not be concatenated | Yes | |
CPP_D022 | Functions and objects should not be defined with external linkage if they are referenced in only one translation unit | Yes | |
CPP_D023 | Single-Function Global Objects | Yes | |
CPP_D024 | The restrict type qualifier shall not be used | Yes | |
CPP_D026 | The register keyword shall not be used | Yes | |
CPP_D027 | The unary & operator shall not be overloaded | Yes | |
CPP_D028 | Within an enumerator list, the value of an implicitly-specified enumeration constant shall be unique | Yes | |
CPP_D029 | Destructor Set Data Ptr to 0 | Yes | |
CPP_D030 | Exceptions in Destructors | Yes | |
CPP_D031 | Non-Virtual Destructors in Base Classes | Yes | |
CPP_D032 | Virtual Function Call In Destructor | Yes | |
CPP_D033 | A function shall not be declared implicitly | Yes | |
CPP_D034 | Datamembers should be declared private | Yes | |
CPP_D035 | Destructor of a base class shall be public virtual, public override or protected non-virtual | Yes | |
CPP_D036 | Volatile keyword shall not be used | Yes | |
CPP_D037 | Functions shall not be declared at block scope | Yes | |
CPP_D038 | When an array with external linkage is declared, its size shall be stated explicitly | Yes | |
CPP_D039 | A function definition shall only be placed in a class definition if (1) the function is intended to be inlined (2) it is a member function template (3) it is a member function of a class template | Yes | |
CPP_D040 | All declarations of an object or function shall have compatible types | Yes | |
CPP_D041 | The One Definition Rule | Yes | |
CPP_D042 | If a function has internal linkage then all redeclarations shall include the static storage class specifier | Yes | |
CPP_D043 | Static and thread-local objects shall be constant-initialized | Yes | |
CPP_D044 | Declarations at Lowest Scope | Yes | |
CPP_D045 | A type, object or function that is used in multiple translation units shall be declared in one and only one file | Yes | |
CPP_D046 | Constexpr or const specifiers shall be used for immutable data declaration | Yes | |
CPP_D047 | The constexpr specifier shall be used for values that can be determined at compile time | Yes | |
CPP_D048 | The auto specifier shall not be used apart from following cases: (1) to declare that a variable has the same type as return type of a function call, (2) to declare that a variable has the same type as initializer of non-fundamental type, (3) to declare parameters of a generic lambda expression, (4) to declare a function template using trailing return type syntax | Yes | |
CPP_D049 | A class, structure, or enumeration shall not be declared in the definition of its type | Yes | |
CPP_D050 | Enumerations shall be declared as scoped enum classes | Yes | |
CPP_D051 | A non-type specifier shall be placed before a type specifier in a declaration. | Yes | |
CPP_D052 | Use the same identifier in definition and declaration of functions. | Yes | |
CPP_D053 | Multiple Base Classes | Yes | |
CPP_D054 | Virtual function declaration shall contain exactly one of the three specifiers: (1) virtual, (2) override, (3) final | Yes | |
CPP_D055 | All Checks/Language Specific/C and C++/Destructors/Non-Virtual Destructors in Base Classes | Yes | |
CPP_D056 | User-defined assignment operator shall not be virtual | Yes | |
CPP_D057 | Hierarchies should be based on interface classes | Yes | |
CPP_D058 | A non-POD type should be defined as class | Yes | |
CPP_D059 | Friend declarations shall not be used. | Yes | |
CPP_D060 | If a class declares a copy or move operation, or a destructor, either via "=default", "=delete", or via a user-provided declaration, then all others of these five special member functions shall be declared as well. | Yes | |
CPP_D061 | Constructors shall explicitly initialize all virtual base classes, all direct non-virtual base classes and all non-static data members. | Yes | |
CPP_D062 | Both NSDMI and a non-static member initializer in a constructor shall not be used in the same type. | Yes | |
CPP_D063 | If all user-defined constructors of a class initialize data members with constant values that are the same across all constructors, then data members shall be initialized using NSDMI instead. | Yes | |
CPP_D064 | All constructors that are callable with a single argument of fundamental type shall be declared explicit. | Yes | |
CPP_D065 | Common class initialization for non-constant members shall be done by a delegating constructor. | Yes | |
CPP_D066 | If a public destructor of a class is non-virtual, then the class should be declared final. | Yes | |
CPP_D067 | All class data members that are initialized by the constructor shall be initialized using member initializers. | Yes | |
CPP_D068 | If the behavior of a user-defined special member function is identical to implicitly defined special member function, then it shall be defined =default or be left undefined. | Yes | |
CPP_D069 | Member Data in Non-POD Class not Private | Yes | |
CPP_D070 | Template specialization shall be declared in the same file as the primary template | Yes | |
CPP_D071 | All user-provided class destructors, deallocation functions, move constructors, move assignment operators and swap functions shall not exit with an exception. A noexcept exception specification shall be added to these functions as appropriate | Yes | |
CPP_D072 | Non-standard entities shall not be added to standard namespaces | Yes | |
CPP_D073 | There shall be one variable declaration per line | Yes | |
CPP_D074 | An external variable shall not be set to a value where it is being declared | Yes | |
CPP_D075 | Incorrect Order of Initialization | Yes | |
CPP_D076 | If a class requires a virtual destructor but has nothing to undo from a constructor, an empty implementation should be provided. | Yes | |
CPP_DD000 | The defines, typedefs, structures, externals, globals, statics, external prototypes, and local prototypes shall be grouped by category. | Yes | |
CPP_DD001 | Use of global functions and variables shall be limited | Yes | |
CPP_DD002 | Globals should not be used in macros | Yes | |
CPP_DD003 | There shall be a function prototype for all functions | Yes | |
CPP_DD004 | Prototypes for static functions shall include the static storage class | Yes | |
CPP_DD005 | Any defined constants that are used as argument or return variables shall be placed in an include file | Yes | |
CPP_DD006 | Initializer lists shall be written in the order in which they are declared | Yes | |
CPP_DD007 | The private keyword should be used in class definitions | Yes | |
CPP_DD008 | Nesting template class definitions should be avoided. | Yes | |
CPP_DD009 | Assignment operators should check for self-assignment | Yes | |
CPP_DD010 | The use of friend classes should be avoided | Yes | |
CPP_DD011 | If the subscript operator (operator[]) is overloaded, both the const and non-const versions should be defined. | Yes | |
CPP_DD012 | Layering techniques, where applicable, should be used instead of private inheritance. | Yes | |
CPP_DD013 | Public Inheritance not Used in a "is-a" Relationship | Yes | |
CPP_DD014 | Use the same parameter names and type qualifiers for all declarations and definitions | Yes | |
CPP_DD015 | Overload allocation and deallocation functions as a pair in the same scope | Yes | |
CPP_DD016 | Do not write syntactically ambiguous declarations | Yes | |
CPP_DD017 | Avoid cycles during initialization of static objects | Yes | |
CPP_DD018 | Obey the one-definition rule | Yes | |
CPP_DD019 | Arrays shall not be partially initialized | Yes | |
CPP_DD020 | An element of an object shall not be initialized more than once | Yes | |
CPP_DD021 | Where designated initializers are used to initialize an array object the size of the array shall be specified explicitly | Yes | |
CPP_DD022 | Make sure that objects are initialized before they are used | Yes | |
CPP_DD023 | Use the same form in corresponding uses of new and delete | Yes | |
CPP_DD024 | Postpone variable definitions as long as possible | Yes | |
CPP_DD025 | Avoid hiding inherited names | Yes | |
CPP_DD026 | Never redefine an inherited non-virtual function | Yes | |
CPP_E000 | A class type exception shall always be caught by reference | Yes | |
CPP_E001 | There should be at least one exception handler to catch all otherwise unhandled exceptions | Yes | |
CPP_E002 | Catch-All Statement Before Last | Yes | |
CPP_E003 | Catch Const References | Yes | |
CPP_E004 | Destructors Not Throw Exceptions | Yes | |
CPP_E005 | An empty throw (throw;) shall only be used in the compound-statement of a catch handler | Yes | |
CPP_E006 | Order of Catch Blocks with Derived Classes | Yes | |
CPP_E007 | An exception object should not have pointer type | Yes | |
CPP_E008 | Exceptions shall be raised only after start-up and before termination of the program | Yes | |
CPP_E009 | Exceptions thrown shall be the type indicated by the function | Yes | |
CPP_E010 | Inconsistent Exception-Specification | Yes | |
CPP_E011 | No "errno" allowed | Yes | |
CPP_E012 | NULL shall not be thrown explicitly | Yes | |
CPP_E013 | Throw exceptions by value, not by pointer | Yes | |
CPP_E014 | The assignment-expression of a throw statement shall not itself cause an exception to be thrown | Yes | |
CPP_E015 | Expressions with type bool shall not be used as operands to built-in operators other than the assignment operator =, the logical operators &&, ||, !, the equality operators == and !=, the unary & operator, and the conditional operator | Yes | |
CPP_E016 | Character Operators | Yes | |
CPP_E017 | Code Slicing Should Not Occur | Yes | |
CPP_E018 | Expressions with type enum or enum class shall not be used as operands to built-in and overloaded operators other than the subscript operator [ ], the assignment operator =, the equality operators == and ! =, the unary & operator, and the relational operators <, <=, >, >= | Yes | |
CPP_E019 | Avoid Trigraphs | Yes | |
CPP_E020 | Octal constants (other than zero) and octal escape sequences (other than "\0" ) shall not be used. | Yes | |
CPP_E021 | Octal and Hexadecimal Sequences | Yes | |
CPP_E022 | Escape sequences are standardized | Yes | |
CPP_E023 | Expression uses operand of side-effect more than once | Yes | |
CPP_E024 | Signed operands to modulus or division operator | Yes | |
CPP_E025 | Floating Equality Test | Yes | |
CPP_E026 | Minimization of run-time failures shall be ensured by the use of static analysis tools | Yes | |
CPP_E027 | Only those escape sequences that are defined in ISO/IEC 14882:2014 shall be used | Yes | |
CPP_E028 | Hexadecimal constants should be upper case | Yes | |
CPP_E029 | A "U" suffix shall be applied to all octal or hexadecimal integer literals of unsigned type. | Yes | |
CPP_E031 | Traditional C-style casts shall not be used | Yes | |
CPP_E032 | Infeasible Paths | Yes | |
CPP_E033 | Do not rely on the value of a moved-from object | Yes | |
CPP_E034 | Limited dependence should be placed on C++ operator precedence rules in expressions | Yes | |
CPP_E035 | Parameter list (possibly empty) shall be included in every lambda expression | Yes | |
CPP_E036 | Specify Lambda Return Type | Yes | |
CPP_E037 | Lambda expressions should not be defined inside another lambda expression | Yes | |
CPP_E038 | Identical unnamed lambda expressions shall be replaced with a named function or a named lambda expression | Yes | |
CPP_E039 | A lambda shall not be an operand to decltype or typeid | Yes | |
CPP_E040 | dynamic_cast should not be used | Yes | |
CPP_E041 | reinterpret_cast shall not be used | Yes | |
CPP_E042 | Operands of Logical Boolean Operators | Yes | |
CPP_E043 | The increment (++) and decrement (--) operators shall not be mixed with other operators in an expression | Yes | |
CPP_E044 | Each operand of the ! operator, the logical && or the logical || operators shall have type bool | Yes | |
CPP_E045 | Evaluation of the operand to the sizeof operator shall not contain side effects | Yes | |
CPP_E046 | The right hand operand of a shift operator shall lie between zero and one less than the width in bits of the underlying type of the left hand operand. | Yes | |
CPP_E047 | The ternary conditional operator shall not be used as a sub-expression | Yes | |
CPP_E048 | Each expression statement and identifier declaration shall be placed on a separate line | Yes | |
CPP_E049 | The comma operator shall not be used. | Yes | |
CPP_E050A | Evaluation of the operand to the typeid operator shall not contain side effects | Yes | |
CPP_E050B | The right hand operand of the integer division or remainder operators shall not be equal to zero | Yes | |
CPP_E051 | Unary Minus Operator Applied to an Expression with an Unsigned Type | Yes | |
CPP_E052 | The right-hand operand of a logical && or || operator should not contain persistent side effects | Yes | |
CPP_E053 | Empty Throw | Yes | |
CPP_E054 | NULL Throw | Yes | |
CPP_E055 | Exception Object | Yes | |
CPP_E056 | A lambda expression object shall not outlive any of its reference-captured objects | Yes | |
CPP_E057 | Only instances of types derived from std::exception should be thrown | Yes | |
CPP_E058 | An exception object shall not be a pointer | Yes | |
CPP_E059 | All thrown exceptions should be unique | Yes | |
CPP_E060 | If a function exits with an exception, then before a throw, the function shall place all objects/resources that the function constructed in valid states or it shall delete them | Yes | |
CPP_E061 | Dynamic exception-specification shall not be used | Yes | |
CPP_E062 | A class type exception shall be caught by reference or const reference | Yes | |
CPP_E063 | Catch-all (ellipsis and std::exception) handlers shall be used only in (a) main, (b) task main functions, (c) in functions that are supposed to isolate independent components and (d) when calling third-party code that uses exceptions not according to AUTOSAR C++14 guidelines | Yes | |
CPP_E064 | Unhandled Exceptions on Main Function | Yes | |
CPP_E065 | Condition of if statement shall be bool | Yes | |
CPP_E066 | Const Should be placed on the left-hand side of the comparison | Yes | |
CPP_E067 | Floats shall not be tested for direct equality | Yes | |
CPP_E068 | Provide a valid ordering predicate | Yes | |
CPP_E069 | Assignment in SubExpressions | Yes | |
CPP_E070 | Boolean operators | Yes | |
CPP_E072 | Int to Float Conversion | Yes | |
CPP_E073 | An implicit integral conversion shall not change the signedness of the underlying type | Yes | |
CPP_E074 | Operands shall not be of an inappropriate essential type | Yes | |
CPP_E075 | Both operands of an operator in which the usual arithmetic conversions are performed shall have the same essential type category | Yes | |
CPP_E077 | The value of a composite expression shall not be assigned to an object with wider essential type | Yes | |
CPP_E078 | The value of a composite expression shall not be cast to a different essential type category or a wider essential type | Yes | |
CPP_E079 | Conversions shall not be performed between a pointer to an incomplete type and any other type | Yes | |
CPP_E080 | A cast shall not be performed between a pointer to object type and a pointer to a different object type | Yes | |
CPP_E081 | A conversion should not be performed between a pointer to object and an integer type | Yes | |
CPP_E082 | Initializer lists shall not contain persistent side effects | Yes | |
CPP_E083 | The controlling expression of an if statement and the controlling expression of an iteration-statement shall have essentially Boolean type | Yes | |
CPP_E084 | The macro NULL shall be the only permitted form of integer null pointer constant | Yes | |
CPP_E085 | The result of an assignment operator should not be used | Yes | |
CPP_E086 | A loop counter shall not have essentially floating type | Yes | |
CPP_E087 | Minimize casting | Yes | |
CPP_EH000 | Program shall not be abruptly terminated | Yes | |
CPP_EH001 | The std::terminate() function shall not be called implicitly | Yes | |
CPP_EH002 | Library objects shall not generate error messages directly | Yes | |
CPP_EH003 | Destructors should not throw exceptions | Yes | |
CPP_EH004 | Exceptions should be caught only by reference | Yes | |
CPP_EH005 | A declaration of non-throwing function shall contain noexcept specification | Yes | |
CPP_EH006 | If a function is declared to be noexcept, noexcept(true) or noexcept(<truecondition>), then it shall not exit with an exception | Yes | |
CPP_EH007 | Each exception explicitly thrown in the code shall have a handler of a compatible type in all call paths that could lead to that point | Yes | |
CPP_EH008 | Exceptions thrown across execution boundaries | Yes | |
CPP_EH009 | New Method Throwing an Exception | Yes | |
CPP_EH010 | Use Assertion Statements | Yes | |
CPP_EH011 | Catch exceptions by lvalue reference | Yes | |
CPP_F000 | All prototype parameters must have an identifier. | Yes | |
CPP_F001 | All class templates, function templates, class template member functions and class template static members shall be instantiated at least once | Yes | |
CPP_F002 | Const member functions shall not return non-const pointers or references to class-data | Yes | |
CPP_F003 | Unused Functions | Yes | |
CPP_F004 | Functions with no parameters need explicit void keyword | Yes | |
CPP_F005 | Declare functions at file scope | Yes | |
CPP_F006 | A Function identifier shall either be used to call the function or it shall be preceded by & | Yes | |
CPP_F007 | Functions must not return objects by value. | Yes | |
CPP_F008 | Functions shall not be defined using the ellipsis notation | Yes | |
CPP_F009 | Use Named Parameters and Prototype Form | Yes | |
CPP_F010 | Functions shall not be declared implicitly | Yes | |
CPP_F011 | Inline functions defined in the class body | Yes | |
CPP_F012 | The identifier main shall not be used for a function other than the global function main | Yes | |
CPP_F013 | Member functions shall not return non-const handles to class-data | Yes | |
CPP_F014 | If a member function can be made static then it shall be made static, otherwise if it can be made const then it shall be made const | Yes | |
CPP_F015 | Missing parameter name in function declarations | Yes | |
CPP_F016 | variable numbers of arguments shall not be used. | Yes | |
CPP_F017 | Overloaded function templates shall not be explicitly specialized | Yes | |
CPP_F018 | Parameters in an overriding virtual function shall either use the same default arguments as the function they override, or else shall not specify any default arguments. | Yes | |
CPP_F019 | A pointer or reference parameter in a function shall be declared as pointer to const or reference to const if the corresponding object is not modified | Yes | |
CPP_F020 | use the same identifier in definition and declaration of functions. | Yes | |
CPP_F021 | The features of <stdarg.h> shall not be used | Yes | |
CPP_F022 | Objects should not be passed by reference | Yes | |
CPP_F023 | A function parameter should not be modified | Yes | |
CPP_F024 | The value returned by a function shall be used | Yes | |
CPP_F025 | All functions with void return type shall have external side effect(s) | Yes | |
CPP_F026 | Every function defined in an anonymous namespace, or static function with internal linkage, or private member function shall be used | Yes | |
CPP_F027 | There shall be no unused named parameters in non-virtual functions | Yes | |
CPP_F028 | There shall be no unused named parameters in the set of parameters for a virtual function and all the functions that override it | Yes | |
CPP_F029 | operator "new" and operator "delete" shall be defined together | Yes | |
CPP_F030 | If a project has a sized or unsized version of operator "delete" globally defined, then both sized and unsized versions shall be defined | Yes | |
CPP_F031 | A function shall not return a reference or a pointer to an automatic variable (including parameters), defined within the function. | Yes | |
CPP_F032 | A function shall not return a reference or a pointer to a parameter that is passed by reference to const. | Yes | |
CPP_F033 | Always return a value in non-void functions | Yes | |
CPP_F034 | Trivial accessor and mutator functions should be inlined. | Yes | |
CPP_F035 | Non-virtual public or protected member functions shall not be redefined in derived classes | Yes | |
CPP_F036 | Use Override | Yes | |
CPP_F037 | Time Handling Functions of <ctime> | Yes | |
CPP_F038 | Check Parameters and Return Values - Unchecked Parameters and Return Values | Yes | |
CPP_F038_A | Check Parameters and Return Values - Ignored Return Values | Yes | |
CPP_F039 | A function that contains "forwarding reference" as its argument shall not be overloaded | Yes | |
CPP_F040 | A virtual function shall only be overridden by a pure virtual function if it is itself declared as pure virtual | Yes | |
CPP_F041 | Member functions shall not return non-const raw pointers or references to private or protected data owned by the class | Yes | |
CPP_F042 | If two opposite operators are defined, one shall be defined in terms of the other | Yes | |
CPP_F043 | Comparison operators shall be non-member functions with identical parameter types and noexcept | Yes | |
CPP_F044 | Overloaded Function Not Visible From Where it is Called | Yes | |
CPP_F045 | Virtual functions shall not be introduced in a final class | Yes | |
CPP_F046 | Predicate Function Objects Copied Incorrectly | Yes | |
CPP_F047 | A template constructor shall not participate in overload resolution for a single argument of the enclosing class type | Yes | |
CPP_F048 | A non-member generic operator shall only be declared in a namespace that does not contain class (struct) type, enum type or union type declarations | Yes | |
CPP_F049 | Explicit specializations of function templates shall not be used | Yes | |
CPP_F050 | The noexcept specification of a function shall either be identical across all translation units, or identical or more restrictive between a virtual member function and an overrider | Yes | |
CPP_F051 | A function should be inlined only if it has one or two lines of code | Yes | |
CPP_F052 | The function gets() should not be used | Yes | |
CPP_F053 | Every function shall have an explicitly declared return type. | Yes | |
CPP_F054 | Boolean functions shall explicitly return true or false | Yes | |
CPP_F055 | The default parameter list, when redeclaring or overriding methods, should be kept constant | Yes | |
CPP_F056 | Each function shall contain a prologue | Yes | |
CPP_F057 | Function prologue shall be in header or source | Yes | |
CPP_F058 | Function prologue shall contain certain specific information | Yes | |
CPP_F059 | Variable-length argument lists should not be used | Yes | |
CPP_F060 | A method that does not change the visible properties of a class shall be declared const | Yes | |
CPP_F061 | The type of the return and all method arguments (even type void) shall be specified when defining a method | Yes | |
CPP_F062 | When overloading standardized operators (e.g., a += b, a-=b etc.), the resulting behavior should remain consistent with the expected outcome of the operator. | Yes | |
CPP_F063 | Member function arguments should not share the same name as class state variables | Yes | |
CPP_F064 | Member functions should always be declared const unless they modify state variables | Yes | |
CPP_F065 | Any parameter not modified by a method should be passed to the method as a const. | Yes | |
CPP_F066 | Tail-Call Optimization | Yes | |
CPP_F067 | Functions declared with the [[noreturn]] attribute shall not return | Yes | |
CPP_F069 | A signal handler must be a plain old function | Yes | |
CPP_F070 | Consider alternatives to virtual functions | Yes | |
CPP_H000 | The #include directive shall be followed by either a <filename> or "filename" sequence | Yes | |
CPP_H001 | The backslash character should not occur in a header file name | Yes | |
CPP_H002 | The ', ", /* or // characters shall not occur in a header file name | Yes | |
CPP_H003 | Definitions in Header Files | Yes | |
CPP_H004 | There shall be no unnamed namespaces in header files. | Yes | |
CPP_H005 | Objects or functions with external linkage shall be declared in a header file | Yes | |
CPP_H006 | It shall be possible to include any header file in multiple translation units without violating the One Definition Rule | Yes | |
CPP_H007 | Unnecessary #Includes | Yes | |
CPP_H008 | using-directives and using-declarations (excluding class scope or function scope using-declarations) shall not be used in header files. | Yes | |
CPP_H009 | Header files, that are defined locally in the project, shall have a file name extension of one of: ".h", ".hpp" or ".hxx" | Yes | |
CPP_H010 | Header File Name | Yes | |
CPP_H011 | Absolute path names shall not be used for header files | Yes | |
CPP_H012 | All references to header files shall be listed one per line | Yes | |
CPP_H013 | Names of private header files should not be identical to names of library header files | Yes | |
CPP_H014 | All public header files shall be capable of being included by a C++ file as well as a C file | Yes | |
CPP_H016 | If prototypes, typedefs, macros, structure definitions, or enums are needed in multiple modules, they shall be placed in header files | Yes | |
CPP_H017 | C++ version of the header file should be used | Yes | |
CPP_H018 | When including C Standard Library header files, C++ Standard Library header files without a '.h' appended should be used | Yes | |
CPP_H019 | Forward referencing should be used, when appropriate, over direct inclusion when documenting dependencies within a header file. | Yes | |
CPP_H020 | The standard header file <tgmath.h> shall not be used | Yes | |
CPP_H021 | The standard header file <setjmp.h> shall not be used | Yes | |
CPP_I000 | A class, union or enum name (including qualification, if any) shall be a unique identifier | Yes | |
CPP_I001 | Different identifiers shall be typographically unambiguous | Yes | |
CPP_I002 | External identifiers shall be distinct | Yes | |
CPP_I003 | Identifiers that define objects or functions with external linkage shall be unique | Yes | |
CPP_I004 | Global Namespace Declarations | Yes | |
CPP_I005 | Identifier name reuse | Yes | |
CPP_I006 | Identifiers shall be distinct from macro names | Yes | |
CPP_I007 | Identifiers declared in the same scope and name space shall be distinct | Yes | |
CPP_I008 | Identifiers that define objects or functions with internal linkage should be unique | Yes | |
CPP_I009 | Macro identifiers shall be distinct | Yes | |
CPP_I010 | The identifier name of a non-member object or function with static storage duration should not be reused | Yes | |
CPP_I011 | Identifier name significance | Yes | |
CPP_I012 | Static name reuse | Yes | |
CPP_I013 | A tag name shall be a unique identifier | Yes | |
CPP_I014 | A typedef name shall be a unique identifier. | Yes | |
CPP_I015 | No identifier in one name space should have the same spelling as an identifier in another name space. | Yes | |
CPP_I016 | Reserved Identifiers or Macros | Yes | |
CPP_I017 | Shadowed Identifiers | Yes | |
CPP_I018 | A class or enumeration name shall not be hidden by a variable, function or enumerator declaration in the same scope | Yes | |
CPP_I019 | The identifier name of a non-member object with static storage duration or static function shall not be reused within a namespace | Yes | |
CPP_I020 | An identifier name of a function with static storage duration or a non-member object with external or internal linkage should not be reused | Yes | |
CPP_I021 | Universal character names shall be used only inside character or string literals | Yes | |
CPP_I022 | Similiar Entity Names within Multiple Inheritance | Yes | |
CPP_I023 | Uppercase 'O' shall not be used as an identifier | Yes | |
CPP_I024 | Lowercase 'l' shall not be used as an identifier | Yes | |
CPP_I025 | The using namespace directive should be used only at the method or function scope. | Yes | |
CPP_L000 | Calls to COTS library functions that might throw an exception must be enclosed in a try block. | Yes | |
CPP_L001 | The C library shall not be used | Yes | |
CPP_L002 | The signal handling facilities of <csignal> shall not be used | Yes | |
CPP_L003 | The stream input/output library <cstdio> shall not be used | Yes | |
CPP_L004 | <cstdlib> Library Functions | Yes | |
CPP_L005 | Avoid atof, atoi, atol, and atoll from <cstdlib> or <stdlib.h> | Yes | |
CPP_L006 | Unbounded Functions of <cstring> | Yes | |
CPP_L007 | Avoid using the library <ctime> | Yes | |
CPP_L008 | No "errno" allowed | Yes | |
CPP_L009 | No offsetof allowed | Yes | |
CPP_L010 | The setjmp macro and the longjmp function shall not be used | Yes | |
CPP_L011 | Signal.h should not be used | Yes | |
CPP_L012 | Standard Library Function Names | Yes | |
CPP_L013 | Avoid including stdio.h | Yes | |
CPP_L014 | Library stdlib.h - avoid: abort, exit, getenv and system | Yes | |
CPP_L015 | Guarantee that library functions do not overflow | Yes | |
CPP_L016 | The library <time.h> shall not be used | Yes | |
CPP_L017 | Inputs from independent components shall be validated | Yes | |
CPP_L018 | Ensure your random number generator is properly seeded | Yes | |
CPP_L019 | Random number engines shall not be default-initialized | Yes | |
CPP_L020 | Do not unlock or destroy another POSIX thread's mutex | Yes | |
CPP_L021 | An iterator shall not be implicitly converted to const_iterator | Yes | |
CPP_L022 | An argument to std::forward shall not be subsequently used | Yes | |
CPP_L023 | The std::move shall not be used on objects declared const or const& | Yes | |
CPP_L024 | Forwarding values to other functions shall be done via: (1) std::move if the value is an rvalue reference, (2) std::forward if the value is forwarding reference | Yes | |
CPP_L025 | The std::bind shall not be used | Yes | |
CPP_L026 | Alternate input and output operations on a file stream shall not be used without an intervening flush or positioning call | Yes | |
CPP_L027 | All std::hash specializations for user-defined types shall have a noexcept function call operator | Yes | |
CPP_L028 | The std::auto_ptr type shall not be used | Yes | |
CPP_L029 | Library <clocale> (locale.h) | Yes | |
CPP_L030 | Avoid deadlock with POSIX threads by locking in predefined order | Yes | |
CPP_L031 | Evaluation of the operand to the typeid operator shall not contain side effects. | Yes | |
CPP_L033 | Reserved Builtin Macros | Yes | |
CPP_L034 | Use of the iostream library is preferred over stdio.h | Yes | |
CPP_M000 | Dynamic heap memory allocation | Yes | |
CPP_M001 | The form of the delete expression shall match the form of the new expression used to allocate the memory | Yes | |
CPP_M002 | Non-placement new or delete expressions shall not be used | Yes | |
CPP_M003 | Bitwise operations and operations that assume data representation in memory shall not be performed on objects. | Yes | |
CPP_M004 | Moved-from object shall not be read-accessed. | Yes | |
CPP_M005 | Uninitialized Memory Read | Yes | |
CPP_M006 | Functions malloc, calloc, realloc and free shall not be used | Yes | |
CPP_M007 | When reading strings a maximum field width should be specified | Yes | |
CPP_M008 | Dynamically allocated memory shall be set to some value prior to its use as an rvalue or in a test | Yes | |
CPP_M009 | Memory that has been freed shall not be referenced | Yes | |
CPP_M010 | The new[] and delete[] operators shall be used for the allocation and deallocation of memory resources | Yes | |
CPP_M011 | The delete[] operator shall be used to deallocate arrays that have been allocated with the new[] operator | Yes | |
CPP_M012 | The delete[] operator shall be called in the destructor for all member pointers in an object that are pointing to memory that was dynamically allocated by that object | Yes | |
CPP_M013 | Users shall provide a copy constructor, destructor and assignment operator for a class that uses dynamic memory allocation | Yes | |
CPP_M014 | The operator new should be called with the nothrow option. | Yes | |
CPP_M015 | When overloading the new[] operator, a corresponding delete[] operator should be provided. | Yes | |
CPP_M016 | Overloaded new operator should not hide the global new operator | Yes | |
CPP_M017 | All local allocations made in a method, other than the destructor, should be deallocated prior to exiting the method. | Yes | |
CPP_M018 | Dynamic Memory Usage on Realtime Phase | Yes | |
CPP_M019 | No Dynamic Memory Allocation | Yes | |
CPP_M020 | Properly pair allocation and deallocation functions | Yes | |
CPP_M021 | Declare objects shared between POSIX threads with appropriate storage durations | Yes | |
CPP_N000 | Naming Convention: Classes | Yes | |
CPP_N001 | Naming Convention: Enumerator | Yes | |
CPP_N002 | Naming Convention: Enums | Yes | |
CPP_N003 | Naming Convention: Files | Yes | |
CPP_N004 | Naming Convention: Functions | Yes | |
CPP_N005 | Naming Convention: Macros | Yes | |
CPP_N006 | Naming Convention: Namespaces | Yes | |
CPP_N007 | Naming Convention: Parameters | Yes | |
CPP_N008 | Naming Convention: Structs | Yes | |
CPP_N009 | Naming Convention: Typedefs | Yes | |
CPP_N010 | Naming Convention: Unions | Yes | |
CPP_N011 | Naming Convention: Variables | Yes | |
CPP_N012 | Only those characters specified in the C++ Language Standard basic source character set shall be used in the source code | Yes | |
CPP_N013 | Naming Convention: Header File Names | Yes | |
CPP_N014 | Naming Convention: Implementation File Names | Yes | |
CPP_N015 | Implementation files, that are defined locally in the project, should have a file name extension of ".cpp" | Yes | |
CPP_N016 | User defined suffixes of the user defined literal operators shall start with underscore followed by one or more letters | Yes | |
CPP_N017 | Digit sequences separators ' shall only be used as follows: (1) for decimal, every 3 digits, (2) for hexadecimal, every 2 digits, (3) for binary, every 4 digits | Yes | |
CPP_N018 | All macros shall be fully capitalized | Yes | |
CPP_N019 | Function and variable names shall not be fully capitalized | Yes | |
CPP_P000 | No more than 2 levels of pointer indirection | Yes | |
CPP_P001 | Hide Implementation of Pointers Not Dereferenced | Yes | |
CPP_P002 | Pointer initialization must use 0, not NULL. | Yes | |
CPP_P003 | Pointer function parameters must be tested for equality to 0 before accessing the data being pointed to | Yes | |
CPP_P004 | Pointers Must Be Initialized | Yes | |
CPP_P005 | Arguments to a function-like macro shall not contain tokens that look like preprocessing directives | Yes | |
CPP_P006 | std::make_unique shall be used to construct objects owned by std::unique_ptr | Yes | |
CPP_P007 | A std::unique_ptr shall be used over std::shared_ptr if ownership sharing is not required | Yes | |
CPP_P008 | Do Not Use #define | Yes | |
CPP_P009 | In the definition of a function-like macro, each instance of a parameter shall be enclosed in parentheses, unless it is used as the operand of # or ## | Yes | |
CPP_P010 | All #else, #elif and #endif preprocessor directives shall reside in the same file as the #if, #ifdef or #ifndef directive to which they are related | Yes | |
CPP_P011 | Ifndef Wrappers or Pragma Once | Yes | |
CPP_P012 | File Include Matching Header | Yes | |
CPP_P013 | Function-like macros shall not be defined | Yes | |
CPP_P014_A | Restrict Pointer Usage - Multiple Dereferences | Yes | |
CPP_P014_B | Restrict Pointer Usage - Other | Yes | |
CPP_P015 | Inactive Code | Yes | |
CPP_P017 | #include directives in a file shall only be preceded by other preprocessor directives or comments | Yes | |
CPP_P018 | A macro shall not be defined with the same name as a keyword | Yes | |
CPP_P019 | Macros in Blocks | Yes | |
CPP_P020 | C++ macros shall only be used for include guards, type qualifiers, or storage class specifiers | Yes | |
CPP_P021 | Before dereferencing a pointer, compare it with NULL | Yes | |
CPP_P022 | The pre-processor shall only be used for file inclusion and include guards | Yes | |
CPP_P023 | Reserved identifiers, macros and functions in the standard library shall not be defined, redefined or undefined | Yes | |
CPP_P024 | The address of an object with automatic storage shall not be assigned to another object that may persist after the first object has ceased to exist. | Yes | |
CPP_P025 | All macro identifiers in preprocessor directives shall be defined before use, except in #ifdef and #ifndef preprocessor directives and the defined() operator | No | |
CPP_P026 | avoid #undef | Yes | |
CPP_P028 | A smart pointer shall only be used as a parameter type if it expresses lifetime semantics | Yes | |
CPP_P029 | A project should not contain unused macro declarations | Yes | |
CPP_P030 | Invalid Use of std::shared_ptr | Yes | |
CPP_P031 | Invalid Use of std::unique_ptr | Yes | |
CPP_P032 | Cyclic Structure of std::shared_ptr | Yes | |
CPP_P033 | For pointer declarations, the asterisk shall be placed with the variable | Yes | |
CPP_P034 | Const Member Function Returning Non-Const Pointer or Reference | Yes | |
CPP_P035 | std::make_shared shall be used to construct objects owned by std::shared_ptr | Yes | |
CPP_P036 | A std::shared_ptr shall be used to represent shared ownership | Yes | |
CPP_P037 | A std::unique_ptr shall be used to represent exclusive ownership | Yes | |
CPP_P038 | An already-owned pointer value shall not be stored in an unrelated smart pointer | Yes | |
CPP_P039 | String literals shall not be assigned to non-constant pointers | Yes | |
CPP_P040 | Only nullptr literal shall be used as the null-pointer-constant | Yes | |
CPP_P041 | Subtraction between pointers shall only be applied to pointers that address elements of the same array | Yes | |
CPP_P042 | Pointer arithmetic shall not be used with pointers to non-final classes | Yes | |
CPP_P043 | >, >=, <, <= shall not be applied to objects of pointer type, except where they point to the same array | Yes | |
CPP_P044 | Deleting Pointers to Incomplete Class Types | Yes | |
CPP_P045 | Array indexing over pointer arithmetic | Yes | |
CPP_P046 | A pointer pointing to an element of an array of objects shall not be passed to a smart pointer of single object type | Yes | |
CPP_P047 | A cast shall not convert a pointer to a function to any other pointer type, including a pointer to function type | Yes | |
CPP_P048 | A pointer to member virtual function shall only be tested for equality with null-pointer-constant | Yes | |
CPP_P049 | A pointer operand and any pointer resulting from pointer arithmetic using that operand shall both address elements of the same array | Yes | |
CPP_P050 | Literal zero (0) shall not be used as the null-pointer-constant. | Yes | |
CPP_P051 | Pointer to Integer Cast | Yes | |
CPP_P052 | A parameter shall be passed by reference if it can't be NULL | Yes | |
CPP_P053 | A pointer to member shall not access non-existent class members | Yes | |
CPP_P054 | References should be used instead of pointers when possible. | Yes | |
CPP_P055 | For pointer declarations, the placement of the * shall be consistent | Yes | |
CPP_P056 | Pointer functions shall return a valid pointer on success and a zero pointer on failure | Yes | |
CPP_P057 | A pointer to dynamic memory that is declared and allocated locally should be declared as an auto_ptr. | Yes | |
CPP_P058 | Store newed objects in smart pointers in standalone statements | Yes | |
CPP_P059 | A pointer to a virtual base class shall only be cast to a pointer to a derived class by means of dynamic_cast | Yes | |
CPP_P060 | Prefer pass-by-reference-to-const to pass by value | Yes | |
CPP_P061 | Shared Pointer Capture | Yes | |
CPP_PR000 | #define and #undef shall not be used on a reserved identifier or reserved macro name | Yes | |
CPP_PR001 | Include guards shall be provided | Yes | |
CPP_PR002 | Constants defined by #define shall be explicitly declared with uppercase suffixes | Yes | |
CPP_PR003 | Macros shall not be used to change language syntax | Yes | |
CPP_PR004 | Limit Preprocessor Usage | Yes | |
CPP_PR005 | #include directives should only be preceded by preprocessor directives or comments | Yes | |
CPP_PR006 | There shall be at most one occurrence of the # or ## operators in a single macro definition | Yes | |
CPP_PR007 | The defined preprocessor operator shall only be used in one of the two standard forms | Yes | |
CPP_PR021 | The names of standard library macros and objects shall not be reused | Yes | |
CPP_PR030 | The #pragma directive shall not be used | Yes | |
CPP_PR031 | #error directive shall not be used | Yes | |
CPP_PR032 | The # and ## operators should not be used | Yes | |
CPP_PR033 | The macro offsetof shall not be used | Yes | |
CPP_PR034 | There shall be no unused include directives (slow) | Yes | |
CPP_PR036 | Invalid Preprocessor Directives | Yes | |
CPP_PR037 | Undefined macro identifiers shall not be used in #if or #elif preprocessor directives, except as operands to the defined operator | Yes | |
CPP_PR038 | In the definition of a function-like macro, each instance of a parameter shall be enclosed in parentheses, unless it is used as the operand of # or ## | Yes | |
CPP_PR039 | Function-like Macro Containing Preprocessing Directives | Yes | |
CPP_PR040 | #include Directives Not Grouped Together | Yes | |
CPP_PR041 | Incorrect Use of Pre-processor | Yes | |
CPP_S000 | no unions | Yes | |
CPP_S001 | Flexible array members shall not be declared | Yes | |
CPP_S002 | Incorrect Initializer Lists | Yes | |
CPP_S003 | A type defined as struct shall: (1) provide only public data members, (2) not provide any special member functions or methods, (3) not be a base of another struct or class, (4) not inherit from another struct or class | Yes | |
CPP_S004 | Unions Shall not be Used | Yes | |
CPP_SA_DANGLING_POINTERS | Dangling Pointer | Yes | High |
CPP_SA_DEAD_STORES | Dead Stores | Yes | |
CPP_SA_DIV_ZERO | Division by Zero | Yes | High |
CPP_SA_LEAKS | Memory Leak | Yes | High |
CPP_SA_NULL_PTR | Null Pointer Dereference | Yes | High |
CPP_SA_STACK_ADDRESS_ESCAPE | Stack Address Escape | Yes | High |
CPP_SA_UNDEFINED_CALL | Undefined Call | Yes | High |
CPP_SA_UNINITIALIZED | Uninitialized Value | Yes | High |
CPP_SA_VIRTUAL_CALLS | Virtual Call | Yes | High |
CPP_ST001 | Not more than one space should precede a ";" with the exception of the null statement | Yes | |
CPP_ST002 | Equal signs should be aligned when they occur in a series of assignment operators | Yes | |
CPP_ST003 | Placement of braces for functions shall adhere to one of the following formats and shall be consistent | Yes | |
CPP_ST004 | Code between the beginning and ending braces of a function shall start with one level of indentation | Yes | |
CPP_ST005 | Enum lists should not contain a trailing comma | Yes | |
CPP_ST006 | No line of code should extend beyond column 80 | Yes | |
CPP_ST007 | Declarations shall not be made within an individual block but shall be placed at the function level or at the module level. | Yes | |
CPP_ST008 | Blank lines should be used to separate distinct algorithmic parts | Yes | |
CPP_ST009 | Parentheses should be used in lengthy logical and arithmetic expressions for clarity. | Yes | |
CPP_ST010 | Items should be logically grouped | Yes | |
CPP_ST011 | Inline functions should be used instead of macros | Yes | |
CPP_ST012 | Names that differ in case only or that look similar should not be used. | Yes | |
CPP_ST013 | Switch statements should be used instead of deeply nested else-ifs when testing a variable for multiple values | Yes | |
CPP_ST014 | No line of code should extend beyond 80 characters | Yes | |
CPP_ST015 | Incrementing and decrementing control variables in loops | Yes | |
CPP_ST016 | Calls to free should have an if test around them if it is uncertain that the pointer has been properly allocated. | Yes | |
CPP_ST017 | White space shall not be used in the following places | Yes | |
CPP_ST018 | Continuation lines shall be indented at least one level from the line being continued | Yes | |
CPP_ST019 | Statements under case labels shall be indented one level | Yes | |
CPP_ST020 | For the if-else, while, do, and for control structure, the statement(s) shall be indented one level | Yes | |
CPP_ST021 | Placement of braces for constructs shall be consistent within a module | Yes | |
CPP_ST022 | Boolean expressions involving non-boolean values should always use an explicit test for equality or non-equality. | Yes | |
CPP_ST023 | At least one blank line shall be placed before comments | Yes | |
CPP_ST024 | Functions shall have at least one blank line between them | Yes | |
CPP_ST025 | Each area of declarations shall have at least one blank line before and after it | Yes | |
CPP_ST026 | Class naming conventions | Yes | |
CPP_ST027 | Naming conventions for class data members vs. member function internal data | Yes | |
CPP_ST028 | Data type naming conventions | Yes | |
CPP_ST029 | Immutable data naming conventions | Yes | |
CPP_ST030 | Class design should include the following format | Yes | |
CPP_ST031 | Separate lines should be used for each member declaration | Yes | |
CPP_ST032 | Indentation shall be at least three spaces, and consistent across modules | Yes | |
CPP_ST033 | Short Functions | Yes | |
CPP_T000 | Typedefs that indicate size and signedness should be used in place of the basic numerical types | Yes | |
CPP_T001 | Arguments to character-handling functions shall be representable as an unsigned char | Yes | |
CPP_T002 | The std::vector<bool> specialization shall not be used | Yes | |
CPP_T003 | There should be no unused type declarations | Yes | |
CPP_T004 | Type long double shall not be used | Yes | |
CPP_T005 | Type wchar_t shall not be used | Yes | |
CPP_T006 | The types used for an object, a function return type, or a function parameter shall be token-for-token identical in all declarations and re-declarations | Yes | |
CPP_T007 | A cvalue expression shall not be implicitly converted to a different underlying type | Yes | |
CPP_T008 | An implicit integral conversion shall not change the signedness of the underlying type | Yes | |
CPP_T009 | There shall be no implicit floating-integral conversions | Yes | |
CPP_T010 | An implicit integral or floating-point conversion shall not reduce the size of the underlying type | Yes | |
CPP_T011 | There shall be no explicit floating-integral conversions of a cvalue expression | Yes | |
CPP_T012 | An explicit integral or floating-point conversion shall not increase the size of the underlying type of a cvalue expression | Yes | |
CPP_T013 | An explicit integral conversion shall not change the signedness of the underlying type of a cvalue expression | Yes | |
CPP_T014 | If the bitwise operators ~ and << are applied to an operand with an underlying type of unsigned char or unsigned short, the result shall be immediately cast to the underlying type of the operand | Yes | |
CPP_T015 | The plain char type shall only be used for the storage and use of character values | Yes | |
CPP_T016 | Signed char and unsigned char type shall only be used for the storage and use of numeric values | Yes | |
CPP_T017 | The first operand of a conditional-operator shall have type bool | Yes | |
CPP_T018 | Bitwise operators shall only be applied to operands of unsigned underlying type | Yes | |
CPP_T019 | C-style Array | Yes | |
CPP_T020 | Casts from a base class to a derived class should not be performed on polymorphic types | Yes | |
CPP_T021 | A cast shall not remove any const or volatile qualification from the type of a pointer or reference | Yes | |
CPP_T022 | An object with integer type or pointer to void type shall not be converted to an object with pointer type. | Yes | |
CPP_T023 | Array to Pointer Decay | Yes | |
CPP_T024 | NULL shall not be used as an integer value | Yes | |
CPP_T025 | CV-qualifiers shall be placed on the right hand side of the type that is a typedef or a using name | Yes | |
CPP_T026 | The typedef specifier shall not be used | Yes | |
CPP_T027 | An expression with enum underlying type shall only have values corresponding to the enumerators of the enumeration | Yes | |
CPP_T028 | Enumeration underlying base type shall be explicitly defined | Yes | |
CPP_T029 | In an enumeration, either (1) none, (2) the first or (3) all enumerators shall be initialized | Yes | |
CPP_T030 | When declaring function templates, the trailing return type syntax shall be used if the return type depends on the type of parameters. | Yes | |
CPP_T031 | Common ways of passing parameters should be used. | Yes | |
CPP_T032 | Multiple output values from a function should be returned as a struct or tuple. | Yes | |
CPP_T033 | "consume" parameters declared as X && shall always be moved from. | Yes | |
CPP_T034 | "forward" parameters declared as T && shall always be forwarded. | Yes | |
CPP_T035 | "in" parameters for "cheap to copy" types shall be passed by value. | Yes | |
CPP_T036 | Output parameters shall not be used. | Yes | |
CPP_T037 | "in-out" parameters declared as T & shall be modified. | Yes | |
CPP_T038 | Fixed Width Integers | Yes | |
CPP_T039 | Non-constant operands to a binary bitwise operator shall have the same underlying type | Yes | |
CPP_T040 | User defined literals operators shall only perform conversion of passed parameters | Yes | |
CPP_T041 | A binary arithmetic operator and a bitwise operator shall return a "prvalue" | Yes | |
CPP_T042 | A relational operator shall return a boolean value | Yes | |
CPP_T043 | If "operator[]" is to be overloaded with a non-const version, const version shall also be implemented | Yes | |
CPP_T044 | Undocumented Use of Floating-point Arithmetic | Yes | |
CPP_T045 | Undocumented Use of Scaled-integer or Fixed-point Arithmetic | Yes | |
CPP_T046 | Assigning Object to an Overlapping Object | Yes | |
CPP_T047 | Data types used for interfacing | Yes | |
CPP_T048 | All user-defined conversion operators shall be defined explicit | Yes | |
CPP_T049 | User-defined conversion operators should not be used | Yes | |
CPP_T050 | Types shall be explicitly specified | Yes | |
CPP_T051 | C-style strings shall not be used | Yes | |
CPP_T052 | String-to-Number Conversion Handling | Yes | |
CPP_T053 | A type used as a template argument shall provide all members that are used by the template | Yes | |
CPP_T054A | An array or container shall not be accessed beyond its range (Part A) | Yes | |
CPP_T054B | An array or container shall not be accessed beyond its range Part B | Yes | |
CPP_T055 | A value should not be retrieved from a structure or union with a different type than with which it was stored | Yes | |
CPP_T056 | Explicit type casting shall be used when performing calculations with a mix of signed and unsigned values. | Yes | |
CPP_T057 | Actual arguments shall be explicitly type cast to the appropriate type | Yes | |
CPP_T058 | Simple integers shall be used to test and set booleans | Yes | |
CPP_T059 | Width-sensitive types should be typedef'd and placed in a header file | Yes | |
CPP_T060 | Converting a pointer to integer or integer to pointer | Yes | |
CPP_T061 | All Checks/Language Specific/C and C++/Types/Use Const whenever possible | Yes | |
CPP_U000 | Digraphs shall not be used | Yes | |
CPP_U001 | Discarded return values. | Yes | |
CPP_U002 | Inline Functions have more than X LOC | Yes | |
CPP_U003 | Unused Parameters in Non-virtual Functions | Yes | |
CPP_U004 | Unused Static Globals | Yes | |
CPP_U005 | A project should not contain unused tag declarations | Yes | |
CPP_U006 | A project shall not contain unused type declarations | Yes | |
CPP_U007 | Unused Labels | Yes | |
CPP_U008 | Unnecessary Friends | Yes | |
CPP_U009 | Special Member Functions | Yes | |
CPP_U010 | Unused Entities | Yes | |
CPP_V000 | Magic Numbers | Yes | |
CPP_V001 | One Variable per Line | Yes | |
CPP_V002 | Reference Symbols Spacing, (& *) | Yes | |
CPP_V003 | Declare each variable in a separate declaration statement | Yes | |
CPP_V004 | A project shall not contain non-volatile POD variables having only one use. | Yes | |
CPP_V005 | Types or externals declared at the function level. | Yes | |
CPP_V006 | A variable which is not modified shall be const qualified | Yes | |
CPP_V007 | Unused Local Variables | Yes | |
CPP_V008 | Unused Static Global | Yes | |
CPP_V009 | Using-directives shall not be used. | Yes | |
CPP_V010 | Variables should be commented | Yes | |
CPP_V011 | All variables shall have a defined value before they are used | Yes | |
CPP_V012 | Explicit Virtual | Yes | |
CPP_V013 | There shall be no more than one definition of each virtual function on each path through the inheritance hierarchy | Yes | |
CPP_V014 | A virtual function shall only be overridden by a pure virtual function if it is itself declared as pure virtual | Yes | |
CPP_V015 | There shall be no unused parameters (named or unnamed) in the set of parameters for a virtual function and all the functions that override it | Yes | |
CPP_V016 | Virtual Call in Constructor/Destructor | Yes | |
CPP_V017 | A project shall not contain instances of non-volatile variables being given values that are not subsequently used | Yes | |
CPP_V018 | Auto Variable | Yes | |
CPP_V019 | Initializing Variables Without Using Braced-Initialization | Yes | |
CPP_V020 | Class members that are not dependent on template class parameters should be defined in a separate base class | Yes | |
CPP_V021 | Variables should not be altered more than once in an expression | Yes | |
CPP_V022 | Variables shall not be implicitly captured in a lambda expression | Yes | |
CPP_V023 | Literal values shall not be used apart from type initialization, otherwise symbolic names shall be used instead | Yes | |
CPP_V024 | Variables of type char shall be explicitly qualified as signed or unsigned when used to store numbers | Yes | |
CPP_V025 | Every variable shall be declared with a specific type | Yes | |
CPP_V026 | Local variables shall be initialized when declared | Yes | |
CPP_V027 | Globals in header files shall be ifdef'd | Yes | |
CPP_V028 | Constants should be declared as const values as opposed to #define directives. | Yes | |
CPP_V029 | The const_cast operator should be used exclusively for altering the constness attribute of a variable. | Yes | |
CPP_V030 | The dynamic_cast operator should be used exclusively for casting within an inheritance hierarchy. | Yes | |
CPP_V031 | The static_cast operator should be used for routine cast operations not provided by const_cast and dynamic_cast. | Yes | |
CPP_V032 | Use of the reinterpret_cast operator should be avoided | Yes | |
CPP_V033 | Typedef'd variables in a class shall be placed in an include file | Yes | |
CPP_V034 | STL containers (vector, list, map, etc.) should be used instead of C-style arrays whenever possible. | Yes | |
CPP_V035 | Objects that do not outlive a function shall have automatic storage duration | Yes | |
CPP_V036 | Static data member initialization should be placed in the class .cpp file | Yes | |
CPP_V037 | Initializer lists should be used to initialize member variables over direct assignment. | Yes | |
CPP_V038 | The concept of information hiding should be implemented. | Yes | |
CPP_V039 | Within an object, most instance variables should be accessed directly. Methods should be used to set variables whose values are determined by an algorithm. | Yes | |
CPP_V042 | An object shall not be accessed outside of its lifetime | No | |
CPP_VF000 | Every class that contains virtual functions shall provide a virtual destructor | Yes | |
CPP_VF001 | Access levels should not be mixed (public, protected, private) when overriding virtual functions. | Yes | |
CPP_VF002 | Virtual Call in Constructor/Destructor | Yes | |
CRITICAL_PATH_CMP | Critical Path Comparison | Yes | Informational |
CSHARP_N000 | Naming Convention: Classes | Yes | |
CSHARP_N001 | Naming Convention: Consts | Yes | |
CSHARP_N002 | Naming Convention: Enumerators | Yes | |
CSHARP_N003 | Naming Convention: Events | Yes | |
CSHARP_N004 | Naming Convention: Fields | Yes | |
CSHARP_N005 | Naming Convention: Files | Yes | |
CSHARP_N006 | Naming Convention: Indexers | Yes | |
CSHARP_N007 | Naming Convention: Methods | Yes | |
CSHARP_N008 | Naming Convention: Namespaces | Yes | |
CSHARP_N009 | Naming Convention: Parameters | Yes | |
CSHARP_N010 | Naming Convention: Properties | Yes | |
CSHARP_N011 | Naming Convention: Type | Yes | |
CSHARP_N012 | Naming Convention: Variables | Yes | |
DCL30-C-B | Declare objects with appropriate storage durations - returning addresses | Yes | High |
DCL41-C | Do not declare variables inside a switch statement before the first case label | Yes | Medium |
ERR33-C | Detect and handle standard library errors | Yes | High |
ERR34-C | Detect errors when converting a string to a number | Yes | Medium |
EXP30-C-B | Do not depend on the order of evaluation for side effects - other | Yes | Medium |
EXP32-C | Do not access a volatile object through a nonvolatile reference | Yes | Low |
EXP42-C | Do not compare padding data | Yes | Medium |
FIO38-C | Do not copy a FILE object | Yes | Low |
FLP30-C | Do not use floating-point variables as loop counters | Yes | Low |
FLP37-C | Do not use object representations to compare floating-point values | Yes | Low |
FORTRAN_N000 | Naming Convention: Block Data | Yes | |
FORTRAN_N001 | Naming Convention: Common Entities | Yes | |
FORTRAN_N002 | Naming Convention: Dummy Arguments | Yes | |
FORTRAN_N003 | Naming Convention: Entries | Yes | |
FORTRAN_N004 | Naming Convention: Functions | Yes | |
FORTRAN_N005 | Naming Convention: Interfaces | Yes | |
FORTRAN_N006 | Naming Convention: Main Programs | Yes | |
FORTRAN_N007 | Naming Convention: Modules | Yes | |
FORTRAN_N008 | Naming Convention: Pointer Blocks | Yes | |
FORTRAN_N009 | Naming Convention: Subroutines | Yes | |
FORTRAN_N010 | Naming Convention: Types | Yes | |
FORTRAN_N011 | Naming Convention: Variables | Yes | |
INT33-C | Division by Zero | Yes | Low |
INT36-C | Converting a pointer to integer or integer to pointer | Yes | Low |
JAVA_01 | All fixed values will be defined final. | Yes | |
JAVA_02 | Unused Instance Variables. | Yes | |
JAVA_03 | Single exit point at end | Yes | |
JAVA_04 | Defined methods shall be called at least once. | Yes | |
JAVA_05 | Unused Local Variables | Yes | |
JAVA_06 | Package names shall be in all lowercase alphabetic characters and integers | Yes | |
JAVA_07 | If multiple classes are imported, the list shall be imported alphabetically | Yes | |
JAVA_08 | Each package group shall be separated with a newline | Yes | |
JAVA_09 | Each Java class shall be assigned to a named package | Yes | |
JAVA_10 | Use package names instead of prefixes on class identifiers | Yes | |
JAVA_11 | A class shall be declared an interface if no method of the class is implemented. | Yes | |
JAVA_12 | If a constructor catches an exception that causes the failure of the object, that exception shall be thrown. | Yes | |
JAVA_13 | Order class definitions by scope | Yes | |
JAVA_14 | Capitalize classes and interfaces | Yes | |
JAVA_15 | Method names should be camelCase | Yes | |
JAVA_16 | Prepend method names with "get" if they return data member values | Yes | |
JAVA_17 | Prepend method names with "set" if they assign data member values | Yes | |
JAVA_18 | Any method that tests the truth or falsity of a condition shall be prepended with a boolean expression | Yes | |
JAVA_19 | A method definition statement and member (nested) class definition statement shall begin at the standard indentation relative to the enclosing class definition statement. | Yes | |
JAVA_20 | The last call of the finalizer shall be to super.finalize(), unless Object is the immediate superclass | Yes | |
JAVA_21 | Finalizers shall catch and manage their own exceptions as well as any propagated exceptions that may be thrown from functions called by the finalizer. | Yes | |
JAVA_22 | A variable’s use shall not be redefined within a method. | Yes | |
JAVA_23 | Only one variable shall be specified for every declaration key word. | Yes | |
JAVA_24 | Each new block shall be indented one increment further than its parent block. | Yes | |
JAVA_25 | Each statement shall be indented to the level of its block. | Yes | |
JAVA_26 | There shall be at most one statement per line. | Yes | |
JAVA_27 | A wrapped line shall be indented one increment further than its originating line. | Yes | |
JAVA_28 | A new instance of java.lang.Exception shall not be thrown. | Yes | |
JAVA_29 | Braces shall be used for all control structures, even if there is only one statement. | Yes | |
JAVA_30 | White space before a comma or semicolon shall not be used. | Yes | |
JAVA_31 | The loop control variable shall not be modified in the body of a for loop. | Yes | |
JAVA_32 | The last choice of a switch or case statement shall end with a break statement. | Yes | |
JAVA_33 | Statements under case labels shall be indented one level. | Yes | |
JAVA_34 | In a switch statement, when a default case is presented, it shall be the last case. | Yes | |
JAVA_35 | For a do-while loop, the ending brace shall be on the same line as the while. | Yes | |
JAVA_36 | Ternary operators shall not be nested inside other ternary operators. | Yes | |
JAVA_37 | Calculations that resolve to the same value shall not be performed inside a loop. | Yes | |
JAVA_38 | For the control structures the terminating brace shall appear on a separate line at the same indentation as the initiating keyword. | Yes | |
JAVA_39 | White space shall not be used: between the name of an array and open bracket that introduces its index (e.g., array[i]), or between unary operators and the objects they operate on (e.g., -1). | Yes | |
JAVA_40 | Spaces shall be placed after commas. | Yes | |
JAVA_41 | Any method that returns the object converted to another type shall be prepended with the word "to" (e.g., c.toString()). | Yes | |
JAVA_42 | The end of a closing brace shall be at the same indentation as the blocks' declaring line. | Yes | |
JAVA_43 | Method declarations shall have at least one blank line between them to improve readability. | Yes | |
JAVA_44 | Spaces shall be placed around all binary operators. | Yes | |
JAVA_DCL00 | Prevent class initialization cycles | Yes | |
JAVA_DCL02 | Do not modify the collection's elements during an enhanced for statement | Yes | |
JAVA_ENV02 | Do not trust the values of environment variables | Yes | |
JAVA_ENV03 | Do not grant dangerous combinations of permissions | Yes | |
JAVA_ENV06 | Production code must not contain debugging entry points | Yes | |
JAVA_ERR00 | Do not suppress or ignore checked exceptions | Yes | |
JAVA_ERR01 | Do not allow exceptions to expose sensitive information | Yes | |
JAVA_ERR02 | Prevent exceptions while logging data | Yes | |
JAVA_ERR03 | Restore prior object state on method failure | Yes | |
JAVA_ERR04 | Do not complete abruptly from a finally block | Yes | |
JAVA_ERR05 | Do not let checked exceptions escape from a finally block | Yes | |
JAVA_ERR06 | Do not throw undeclared checked exceptions | Yes | |
JAVA_ERR07 | Do not throw RuntimeException, Exception, or Throwable | Yes | |
JAVA_ERR08 | Do not catch NullPointerException or any of its ancestors | Yes | |
JAVA_ERR09 | Do not allow untrusted code to terminate the JVM | Yes | |
JAVA_EXP00 | Do not ignore values returned by methods. | Yes | |
JAVA_EXP02 | Do not use the Object.equals() method to compare two arrays. | Yes | |
JAVA_EXP03 | Do not use the equality operators when comparing values of boxed primitives | Yes | |
JAVA_EXP04 | Do not pass arguments to certain Java Collections Framework methods that are a different type than the collection parameter type | Yes | |
JAVA_EXP05 | Do not follow a write by a subsequent write or read of the same object within an expression | Yes | |
JAVA_EXP06 | Expressions used in assertions must not produce side effects | Yes | |
JAVA_FIO00 | Do not operate on files in shared directories | Yes | |
JAVA_FIO01 | Create files with appropriate access permissions | Yes | |
JAVA_FIO02 | Detect and handle file-related errors | Yes | |
JAVA_FIO03 | Remove temporary files before termination | Yes | |
JAVA_FIO04 | Release resources when they are no longer needed | Yes | |
JAVA_FIO05 | Do not expose buffers or their backing arrays methods to untrusted code | Yes | |
JAVA_FIO09 | Do not rely on the write() method to output integers outside the range 0 to 255 | Yes | |
JAVA_FIO10 | Ensure the array is filled when using read() to fill an array | Yes | |
JAVA_FIO13 | Do not log sensitive information outside a trust boundary | Yes | |
JAVA_FIO14 | Perform proper cleanup at program termination | Yes | |
JAVA_IDS00 | Prevent SQL Injection | Yes | |
JAVA_IDS01 | Normalize strings before validating them | Yes | |
JAVA_IDS04 | Safely extract files from ZipInputStream | Yes | |
JAVA_IDS06 | Exclude unsanitized user input from format strings | Yes | |
JAVA_IDS08 | Sanitize untrusted data included in a regular expression | Yes | |
JAVA_IDS11 | Perform any string modifications before validation | Yes | |
JAVA_IDS16 | Prevent XML Injection | Yes | |
JAVA_JNI00 | Define wrappers around native methods | Yes | |
JAVA_LCK00 | Use private final lock objects to synchronize classes that may interact with untrusted code | Yes | |
JAVA_LCK01 | Do not synchronize on objects that may be reused | Yes | |
JAVA_LCK02 | Do not synchronize on the class object returned by getClass() | Yes | |
JAVA_LCK04 | Do not synchronize on a collection view if the backing collection is accessible | Yes | |
JAVA_LCK05 | Synchronize access to static fields that can be modified by untrusted code | Yes | |
JAVA_LCK06 | Do not use an instance lock to protect shared static data | Yes | |
JAVA_LCK07 | Avoid deadlock by requesting and releasing locks in the same order | Yes | |
JAVA_LCK08 | Ensure actively held locks are released on exceptional conditions | Yes | |
JAVA_LCK09 | Do not perform operations that can block while holding a lock | Yes | |
JAVA_LCK10 | Use a correct form of the double-checked locking idiom | Yes | |
JAVA_LCK11 | Avoid client-side locking when using classes that do not commit to their locking strategy | Yes | |
JAVA_MET00 | Validate method arguments | Yes | |
JAVA_MET01 | Never use assertions to validate method arguments | Yes | |
JAVA_MET02 | Do not use deprecated or obsolete classes or methods | Yes | |
JAVA_MET03 | Methods that perform a security check must be declared private or final. | Yes | |
JAVA_MET04 | Do not increase the accessibility of overridden or hidden methods | Yes | |
JAVA_MET05 | Ensure that constructors do not call overridable methods | Yes | |
JAVA_MET06 | Do not invoke overridable methods in clone() | Yes | |
JAVA_MET07 | Never declare a class method that hides a method declared in a superclass or superinterface | Yes | |
JAVA_MET08 | Preserve the equality contract when overriding the equals() method | Yes | |
JAVA_MET09 | Classes that define an equals() method must also define a hashCode() method | Yes | |
JAVA_MET10 | Follow the general contract when implementing the compareTo() method | Yes | |
JAVA_MET11 | Ensure that keys used in comparison operations are immutable | Yes | |
JAVA_MET12 | Do not use finalizers | Yes | |
JAVA_MSC00 | Use SSLSocket rather than Socket for secure data exchange | Yes | |
JAVA_MSC01 | Do not use an empty infinite loop | Yes | |
JAVA_MSC02 | Generate strong random numbers | Yes | |
JAVA_N000 | Naming Convention: Classes | Yes | |
JAVA_N001 | Naming Convention: Files | Yes | |
JAVA_N002 | Naming Convention: Interface | Yes | |
JAVA_N003 | Naming Convention: Methods | Yes | |
JAVA_N004 | Naming Convention: Packages | Yes | |
JAVA_N005 | Naming Convention: Parameters | Yes | |
JAVA_N006 | Naming Convention: Variables | Yes | |
JAVA_N007 | Constants shall be in all uppercase, with underscores separating each component word | Yes | |
JAVA_NUM00 | Detect or prevent integer overflow | Yes | |
JAVA_NUM02 | Ensure that division and remainder operations do not result in divide-by-zero errors | Yes | |
JAVA_NUM07 | Do not attempt comparisons with NaN | Yes | |
JAVA_NUM09 | Do not use floating-point variables as loop counters | Yes | |
JAVA_NUM10 | Do not construct BigDecimal objects from floating-point literals | Yes | |
JAVA_NUM11 | Do not compare or inspect the string representation of floating-point values | Yes | |
JAVA_NUM12 | Ensure conversions of numeric types to narrower types do not result in lost or misinterpreted data | Yes | |
JAVA_NUM13 | Avoid loss of precision when converting primitive integers to floating-point | Yes | |
JAVA_OBJ01 | Limit accessibility of fields | Yes | |
JAVA_OBJ04 | Provide mutable classes with copy functionality to safely allow passing instances to untrusted code | Yes | |
JAVA_OBJ05 | Do not return references to private mutable class members | Yes | |
JAVA_OBJ07 | Sensitive classes must not let themselves be copied | Yes | |
JAVA_OBJ08 | Do not expose private members of an outer class from within a nested class | Yes | |
JAVA_OBJ09 | Compare classes and not class names | Yes | |
JAVA_OBJ10 | Do not use public static nonfinal fields | Yes | |
JAVA_OBJ11 | Be wary of letting constructors throw exceptions | Yes | |
JAVA_OBJ13 | Ensure that references to mutable objects are not exposed | Yes | |
JAVA_SEC01 | Do not allow tainted variables in privileged blocks | Yes | |
JAVA_SEC07 | Call the superclass's getPermissions() method when writing a custom class loader | Yes | |
JAVA_SER01 | Do not deviate from the proper signatures of serialization methods | Yes | |
JAVA_SER04 | Do not allow serialization and deserialization to bypass the security manager | Yes | |
JAVA_SER05 | Do not serialize instances of inner classes | Yes | |
JAVA_SER06 | Make defensive copies of private mutable components during deserialization | Yes | |
JAVA_SER07 | Do not use the default serialized form for classes with implementation-defined invariants | Yes | |
JAVA_SER09 | Do not invoke overridable methods from the readObject() method | Yes | |
JAVA_SER12 | Prevent deserialization of untrusted data | Yes | |
JAVA_STR01 | Do not assume that a Java char fully represents a Unicode code point | Yes | |
JAVA_STR03 | Do not encode noncharacter data as a string | Yes | |
JAVA_THI00 | Do not invoke Thread.run() | Yes | |
JAVA_THI01 | Do not invoke ThreadGroup methods | Yes | |
JAVA_THI02 | Notify all waiting threads rather than a single thread. | Yes | |
JAVA_THI03 | Always invoke wait() and await() methods inside a loop | Yes | |
JAVA_THI04 | Ensure that threads performing blocking operations can be terminated | Yes | |
JAVA_THI05 | Do not use Thread.stop() to terminate threads. | Yes | |
JAVA_TPS00 | Use thread pools to enable graceful degradation of service during traffic bursts | Yes | |
JAVA_TPS01 | Do not execute interdependent tasks in a bounded thread pool | Yes | |
JAVA_TPS02 | Ensure that tasks submitted to a thread pool are interruptible | Yes | |
JAVA_TPS03 | Ensure that tasks executing in a thread pool do not fail silently | Yes | |
JAVA_TPS04 | Ensure ThreadLocal variables are reinitialized when using thread pools | Yes | |
JAVA_TSM00 | Do not override thread-safe methods with methods that are not thread-safe | Yes | |
JAVA_TSM01 | Do not let the this reference escape during object construction | Yes | |
JAVA_TSM02 | Do not use background threads during class initialization | Yes | |
JAVA_TSM03 | Do not publish partially initialized objects | Yes | |
JAVA_VNA00 | Ensure visibility when accessing shared primitive variables | Yes | |
JAVA_VNA01 | Ensure visibility of shared references to immutable objects | Yes | |
JAVA_VNA02 | Ensure that compound operations on shared variables are atomic | Yes | |
JAVA_VNA03 | Do not assume that a group of calls to independently atomic methods is atomic | Yes | |
JAVA_VNA04 | Ensure that calls to chained methods are atomic | Yes | |
JAVA_VNA05 | Ensure atomicity when reading and writing 64-bit values | Yes | |
METRIC_00 | Program Unit Call Count | Yes | |
METRIC_01 | Program Unit Callby Count | Yes | |
METRIC_02 | Program Unit Comment to Code Ratio | Yes | |
METRIC_03 | Program Unit Cyclomatic Complexity | Yes | |
METRIC_04 | Program Unit Max Length | Yes | |
METRIC_05 | Program Unit Max Nesting Depth | Yes | |
METRIC_06 | Program Unit Parameters Count | Yes | |
METRIC_07 | Program Unit Path Count | Yes | |
METRIC_08 | Program Unit Statement Count | Yes | |
METRIC_09 | Coupling Between Object Classes | Yes | |
METRIC_10 | Coupled Packages | Yes | |
METRIC_11 | Depth of Inheritance Tree | Yes | |
METRIC_12 | Lack of Cohesion in Methods | Yes | |
METRIC_13 | Maintainability Index | Yes | |
MSC30-C | Do not use the rand() function for generating pseudorandom numbers | Yes | Medium |
POS44-C | Do not use signals to terminate threads | Yes | Low |
POS47-C | Do not use threads that can be canceled asynchronously | Yes | Medium |
Uncommented Print Statements | Yes | ||
PYTH_01 | Unnecessary Imports | Yes | |
RECOMMENDED_00 | Commented Out Code | Yes | |
RECOMMENDED_01 | Definitions in Header Files | Yes | |
RECOMMENDED_02 | Files too long | Yes | |
RECOMMENDED_03 | Floating Equality Test | Yes | |
RECOMMENDED_04 | Functions Too Long | Yes | |
RECOMMENDED_05 | Functions shall not be declared implicitly | Yes | |
RECOMMENDED_06 | Goto Statements | Yes | |
RECOMMENDED_07 | Macros shall not be #define'd or #undef'd within a block | Yes | |
RECOMMENDED_08 | Magic Numbers | Yes | |
RECOMMENDED_09 | Nested Comments | Yes | |
RECOMMENDED_10 | Overly Complex Functions | Yes | |
RECOMMENDED_11 | Trigraphs shall not be used | Yes | |
RECOMMENDED_12 | Unreachable Code | Yes | |
RECOMMENDED_13 | Unused Functions | Yes | |
RECOMMENDED_14 | Unused C and C++ Local Variables | Yes | |
RECOMMENDED_15 | Unused Static Globals | Yes | |
RECOMMENDED_16 | Variables should be commented | Yes | |
RECOMMENDED_17 | Upper limit shall not be modified within the bounds of the loop | Yes | |
RECOMMENDED_18 | Unused Local Variables | Yes | |
RECOMMENDED_19 | Comments Indicating Future Fixes | Yes | |
RECOMMENDED_20 | Duplicate Code | Yes | |
STI_DATA_RACE | Data Race | Yes | Informational |
STR38-C | Do not confuse narrow and wide character strings and functions | Yes | High |
UND_ERROR | Analysis Error | Yes | Urgent |
UND_WARNING | Analysis Warning | Yes | |
VHDL_1 | VHDL_1 Unused declarations | Yes | |
VHDL_2 | VHDL_2 Unconnected input ports | Yes | |
VHDL_3 | VHDL_3 Unconnected output ports | Yes | |
VHDL_4 | VHDL_4 Incomplete sensitivity lists shall not contain signals not needed by process | No | |
VHDL_5 | VHDL_5 Processes and for loops without labels | Yes | |
VHDL_6 | VHDL_6 Inference of latches | Yes | |
VHDL_7 | VHDL_7 Multiple drivers | Yes | |
VHDL_8 | VHDL_8 Hard coded numeric values | Yes | |
VHDL_9 | VHDL_9 Duplicate signal assignments | Yes | |
VHDL_10 | VHDL_10 Signals not initialized before use | Yes | |
VHDL_11 | VHDL_11 Nested case statements | Yes | |
VHDL_12 | VHDL_12 Commented out code | Yes | |
VHDL_13 | VHDL_13 Cyclomatic Complexity | Yes | |
VHDL_14 | VHDL_14 Functions shall not have more than 8 input parameters | Yes | |
VHDL_15 | VHDL_15 Source code line length shall not exceed 150 characters | Yes | |
VHDL_16 | VHDL_16 Tabs shall not be used for indentation | Yes | |
VHDL_17 | VHDL_17 Files shall not have more than 4500 executable statements | Yes | |
VHDL_18 | VHDL_18 There shall not be multiple statements on a single line | Yes | |
VHDL_19 | VHDL_19 Else and Elsif statements shall be on their own lines | Yes | |
VHDL_20 | VHDL_20 Nested if statements | Yes | |
VHDL_21 | VHDL_21 Duplicate statements in a case statement | Yes | |
VHDL_22 | VHDL_22 Incomplete case statements | Yes | |
VHDL_23 | VHDL_23 Unreachable case items | No | |
VHDL_24 | VHDL_24 Do not use While loop | Yes | |
VHDL_25 | VHDL_25 Do not use Loop without For | Yes | |
VHDL_26 | VHDL_26 Do not use Wait | Yes | |
VHDL_27 | VHDL_27 Do not use Delay | Yes | |
VHDL_28 | VHDL_28 Unlabeled Processes | Yes | |
VHDL_N001 | Naming Convention: Architectures | Yes | |
VHDL_N002 | Naming Convention: Configurations | Yes | |
VHDL_N003 | Naming Convention: Entities | Yes | |
VHDL_N004 | Naming Convention: Files | Yes | |
VHDL_N005 | Naming Convention: Packages | Yes | |
VHDL_N006 | Naming Convention: Processes | Yes | |
VHDL_N007 | Naming Convention: Subtypes | Yes | |
VHDL_N008 | Naming Convention: Types | Yes | |
VHDL_N009 | Naming Convention: Functions | Yes | |
VHDL_N010 | Naming Convention: Signals | Yes |