67 Rules
| ID | Name | Severity |
|---|---|---|
| 592 | Ensure you provide a user-defined copy constructor or disable copy when a class allocates memory in its constructor |
high
|
| 7988 | DEPRECATED: Avoid using snprintf() function family |
medium
|
| 1065000 | Avoid using "continue" statement |
medium
|
| 1065002 | "enum" members other than the first one should not be explicitly initialized unless all members are explicitly initialized. |
medium
|
| 1065004 | Ensure that dynamically allocated memory on local pointer in functions/methods is freed. |
medium
|
| 1065006 | Avoid iterator invalidation. |
high
|
| 1065008 | Avoid use of unvalidated input in array indexing and memory allocation |
medium
|
| 1065010 | Avoid using <cstdio> stream input output library (C++) |
medium
|
| 1065012 | Avoid using 'setjmp' or 'longjmp' (C/C++) |
medium
|
| 1065014 | Avoid using the library functions bsearch and qsort from <stdlib.h> (C/C++) |
medium
|
| 1065016 | Avoid using atof,atol, atoll or atoi functions from <stdlib.h> (C/C++) |
medium
|
| 1065018 | Avoid using offsetof from <cstddef> |
medium
|
| 1065020 | Avoid using <ctime> (C++) |
medium
|
| 1065022 | Avoid using <stdio.h> (C/C++) |
medium
|
| 1065024 | Avoid using the standard library time and date functions from "<time.h>" (C/C++) |
medium
|
| 1065026 | Ensure exception objects are always caught by reference (C++) |
medium
|
| 1065028 | Ensure Switch statements have at least 2 case clauses (C/C++) |
medium
|
| 1065030 | All if … else if constructs shall be terminated with an else clause (C/C++) |
medium
|
| 1065032 | Avoid flexible array members (C/C++) |
medium
|
| 1065034 | Avoid throwing an exception object of pointer type (C++) |
medium
|
| 1065036 | Avoid using '//' and '/*' within comments (C/C++) |
medium
|
| 1065038 | Avoid using 'signal.h' (C/C++) |
medium
|
| 1065040 | Avoid anonymous namespaces in header files (C++) |
medium
|
| 1065042 | Avoid non-void return type function without an explicit return of an expression (C/C++) |
medium
|
| 1065044 | Avoid other than main(), namespace declarations and extern "C" declarations in the global namespace (C/C++) |
medium
|
| 1065046 | Avoid using the unbounded functions of <cstring> library |
medium
|
| 1065048 | Where multiple handlers are provided in a single try-catch statement or function-try-block, any ellipsis (catch-all) handler shall occur last. |
medium
|
| 1065050 | Avoid using "sizeof" on expressions that contain side effects |
medium
|
| 1065052 | Avoid using Octal constants or escape sequences (C/C++) |
medium
|
| 1065054 | Do not override the standard library functions (C/C++) |
medium
|
| 1065056 | Avoid throwing exceptions outside of main() |
medium
|
| 1065058 | Ensure that there is at least one exception handler to catch-all otherwise unhandled exceptions in the main function(C++) |
medium
|
| 1065060 | Avoid loops with floating point counter (C/C++) |
medium
|
| 1065062 | Avoid testing floating point numbers for equality |
high
|
| 1065064 | Avoid doing assignments in sub-expressions (C++) |
medium
|
| 1065066 | Avoid having a method call or additional expressions in a statement using "++" or "--" operators (C/C++) |
medium
|
| 1065068 | Avoid using Digraphs (C++) |
medium
|
| 1065070 | Avoid using Trigraphs |
medium
|
| 1065072 | Avoid using Unions |
medium
|
| 1065074 | All constructors that are callable with a single argument of fundamental type shall be declared explicit. |
medium
|
| 1065076 | Avoid declaring data members in non-POD classes as public or protected |
medium
|
| 1065078 | A base class shall be declared virtual only if it is used in a diamond hierarchy |
medium
|
| 1065080 | Avoid using C-style and functional notation casts (C++) |
medium
|
| 1065082 | Handlers of a function-try-block implementation of a class constructor ordestructor shall not reference non-static members from this class or its bases. |
medium
|
| 1065084 | Avoid performing conversion from a function pointer to any other type (C/C++) |
medium
|
| 1065086 | Avoid casting and converting a pointer type to an integral type (C/C++) |
medium
|
| 1065088 | Member functions shall not return non-const handles to class-data. |
medium
|
| 1065090 | Avoid using 'enum' types as operands for arithmetic contexts |
medium
|
| 1065092 | Avoid having boolean operators with non-boolean operands (C/C++) |
medium
|
| 1065094 | Avoid having expressions with bool type to be used as operands on operators other than =, &&, ||, !, ==, !=, the unary & operator, and the conditional operator |
medium
|
| 1065096 | Avoid dynamic_cast to convert current object to its derived class from its constructor or destructor |
medium
|
| 1065098 | Avoid delete operators to exit with an exception. |
medium
|
| 1065100 | Avoid move constructor and move assignment operator to exit with an exception |
medium
|
| 1065102 | Avoid checking Integer overflow without explicit cast |
high
|
| 1065104 | Converting a multiplication to a larger type should be done before the multiplication takes place |
medium
|
| 1065106 | Avoid comparing types of different widths in a loop |
medium
|
| 1065108 | Bit-fields shall be either unsigned integral, or enumeration (with underlying type of unsigned integral type). |
medium
|
| 1065110 | Ensure arrays and containers are accessed using unsigned values |
critical
|
| 1065114 | Avoid lines starting with "#" with invalid pre-processing directive |
medium
|
| 1065116 | Undefined macro identifiers shall not be used in #if or #elif preprocessor directives, except as operands to the defined operator |
medium
|
| 1065118 | Arguments to a function-like macro shall not contain tokens that look like preprocessing directives. |
medium
|
| 1065120 | Avoid using # OR ## operators more than once while defining macros |
medium
|
| 1065122 | Avoid #define or #undef macros anywhere other than global namespace |
medium
|
| 1065126 | Avoid using goto to jump backwards into a statement in the same function(C/C++) |
medium
|
| 1065128 | Avoid having unused labels in your program (C/C++) |
medium
|
| 1065130 | Avoid defining, redefining or undefining standard macros from standard library |
medium
|
| 1065132 | Avoid using typeid in polymorphic class from the body of its constructor or destructor. |
medium
|