# This file was generated from template 'codesonar/presets/misra2012-0.conf.in' # # This conf file configures CodeSonar to generate warnings for various # MISRA C:2012 rules. This set is for the original edition before any # amendments were published. # Configuration settings required by one or more MISRA checks. SCOPE_CHECK_SUGGESTS_LOCAL_STATIC = Yes BOOL_TYPES += bool,true,false # Explicitly enable all warning classes that correspond to one or more # MISRA C:2012 rules, for C compilation units. # # (If any of these classes is already enabled for C++ compilation # units, it will remain enabled.) # # - Some of the the MISRA-related classes are enabled by default, but # others are not. Classes that are enabled by default are indicated with a # comment directly above the WARNING_FILTER setting. # - If you also want to enable a class for C++ compilation units, # delete "language=c" from the corresponding WARNING_FILTER setting. # # This part of this file was generated from 'cso_wcmanifest.py' # # At least one of the classes enabled by this preset requires unnormalized C ASTs RETAIN_UNNORMALIZED_C_AST = Yes # At least one of the classes enabled by this preset is incompatible with incremental analysis. INCREMENTAL_BUILD = No # Misra2012:20.11: A macro parameter immediately following a # operator shall not immediately be followed by a ## operator WARNING_FILTER += allow class="## Follows # Operator" language=c # Misra2012:3.1: The character sequences /* and // shall not be used within a comment WARNING_FILTER += allow class="/* in // Comment" language=c # Misra2012:3.1: The character sequences /* and // shall not be used within a comment WARNING_FILTER += allow class="// in Comment" language=c # Misra2012:D.4.11: The validity of values passed to library functions shall be checked WARNING_FILTER += allow class="Addition Overflow of Allocation Size" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Arctangent Domain Error" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Argument Too High" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Argument Too Low" language=c # Misra2012:17.5: The function argument corresponding to a parameter declared to have an array type shall have an appropriate number of elements WARNING_FILTER += allow class="Array Parameter Mismatch" language=c # Misra2012:13.4: The result of an assignment operator should not be used WARNING_FILTER += allow class="Assignment Result in Expression" language=c # Misra2012:15.2: The goto statement shall jump to a label declared later in the same function WARNING_FILTER += allow class="Backwards goto" language=c # Misra2012:D.4.6: typedefs that indicate size and signedness should be used in place of the basic numerical types WARNING_FILTER += allow class="Basic Numerical Type Used" language=c # Misra2012:6.1: Bit-fields shall only be declared with an appropriate type WARNING_FILTER += allow class="Bit-field Signedness Not Explicit" language=c # Misra2012:19.2: The union keyword should not be used WARNING_FILTER += allow class="Bit-field in Union" language=c # Misra2012:15.6: The body of an iteration-statement or a selection-statement shall be a compound-statement WARNING_FILTER += allow class="Body Is Not Compound Statement" language=c # Misra2012:16.7: A switch-expression shall not have essentially Boolean type WARNING_FILTER += allow class="Boolean switch Expression" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:18.1: A pointer resulting from arithmetic on a pointer operand shall address an element of the same array as that pointer operand # Misra2012:18.2: Subtraction between pointers shall only be applied to pointers that address elements of the same array # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Buffer Overrun" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:18.1: A pointer resulting from arithmetic on a pointer operand shall address an element of the same array as that pointer operand # Misra2012:18.2: Subtraction between pointers shall only be applied to pointers that address elements of the same array # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Buffer Underrun" language=c # Misra2012:1.2: Language extensions should not be used WARNING_FILTER += allow class="C++ Comment in C" language=c # Misra2012:10.3: The value of an expression shall not be assigned to an object with a narrower essential type or of a different essential type category # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Cast Alters Value" language=c # Misra2012:11.8: A conversion shall not remove any const, volatile or _Atomic qualification from the type pointed to by a pointer WARNING_FILTER += allow class="Cast Removes const Qualifier" language=c # Misra2012:11.8: A conversion shall not remove any const, volatile or _Atomic qualification from the type pointed to by a pointer WARNING_FILTER += allow class="Cast Removes volatile Qualifier" language=c # Misra2012:11.6: A cast shall not be performed between pointer to void and an arithmetic type WARNING_FILTER += allow class="Cast: Arithmetic Type/Void Pointer" language=c # Misra2012:11.7: A cast shall not be performed between pointer to object and a non-integer arithmetic type WARNING_FILTER += allow class="Cast: Non-integer Arithmetic Type/Object Pointer" language=c # Misra2012:11.3: A conversion shall not be performed between a pointer to object type and a pointer to a different object type WARNING_FILTER += allow class="Cast: Object Pointers" language=c # Misra2012:20.1: #include directives should only be preceded by preprocessor directives or comments WARNING_FILTER += allow class="Code Before #include" language=c # Misra2012:10.3: The value of an expression shall not be assigned to an object with a narrower essential type or of a different essential type category # Misra2012:12.4: Evaluation of constant expressions should not lead to unsigned integer wrap-around # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Coercion Alters Value" language=c # Misra2012:11.9: The macro NULL shall be the only permitted form of integer null pointer constant WARNING_FILTER += allow class="Coercion: Integer Constant to Pointer" language=c # Misra2012:D.4.4: Sections of code should not be "commented out" WARNING_FILTER += allow class="Commented-out Code" language=c # Misra2012:18.3: The relational operators >, >=, < and <= shall not be applied to expressions of pointer type except where they point into the same object # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Comparison of Unrelated Pointers" language=c # Misra2012:D.2.1: All source files shall compile without any compilation errors WARNING_FILTER += allow class="Compilation Error in File" language=c # Misra2012:14.4: The controlling expression of an if statement and the controlling expression of an iteration-statement shall have essentially Boolean type WARNING_FILTER += allow class="Condition Is Not Boolean" language=c # Misra2012:7.3: The lowercase character "l" shall not be used in a literal suffix WARNING_FILTER += allow class="Confusing Literal Suffix" language=c # Misra2012:11.1: Conversions shall not be performed between a pointer to a function and any other type WARNING_FILTER += allow class="Conversion from Function Pointer" language=c # Misra2012:11.1: Conversions shall not be performed between a pointer to a function and any other type WARNING_FILTER += allow class="Conversion to Function Pointer" language=c # Misra2012:11.2: Conversions shall not be performed between a pointer to an incomplete type and any other type WARNING_FILTER += allow class="Conversion: Pointer to Incomplete" language=c # Misra2012:11.4: A conversion should not be performed between a pointer to object and an integer type WARNING_FILTER += allow class="Conversion: Pointer/Integer" language=c # Misra2012:11.5: A conversion should not be performed from pointer to void into pointer to object WARNING_FILTER += allow class="Conversion: Void Pointer to Object Pointer" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:11.1: Conversions shall not be performed between a pointer to a function and any other type # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Dangerous Function Cast" language=c # Misra2012:20.2: The ', " or \ characters and the /* or // character sequences shall not occur in a header file name WARNING_FILTER += allow class="Dangerous Include File Name" language=c # Misra2012:18.7: Flexible array members shall not be declared WARNING_FILTER += allow class="Declaration of Flexible Array Member" language=c # Misra2012:21.2: A reserved identifier or reserved macro name shall not be declared WARNING_FILTER += allow class="Declaration of Reserved Name" language=c # Misra2012:18.8: Variable-length array types shall not be used WARNING_FILTER += allow class="Declaration of Variable Length Array" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Division By Zero" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Double Close" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Double Free" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Double Lock" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Double Unlock" language=c # Misra2012:21.3: The memory allocation and deallocation functions of shall not be used # Misra2012:D.4.12: Dynamic memory allocation shall not be used WARNING_FILTER += allow class="Dynamic Allocation After Initialization" language=c # Misra2012:2.2: A project shall not contain dead code WARNING_FILTER += allow class="Explicit Zero Alignment" language=c # Misra2012:10.6: The value of a composite expression shall not be assigned to an object with wider essential type WARNING_FILTER += allow class="Expression Value Widened by Assignment" language=c # Misra2012:10.7: If a composite expression is used as one operand of an operator in which the usual arithmetic conversions are performed then the other operand shall not have wider essential type WARNING_FILTER += allow class="Expression Value Widened by Other Operand" language=c # Misra2012:8.11: When an array with external linkage is declared, its size should be explicitly specified WARNING_FILTER += allow class="Extern Array Without Size" language=c # Misra2012:22.5: A pointer to a FILE object shall not be dereferenced WARNING_FILTER += allow class="FILE* Dereference" language=c # Misra2012:22.3: The same file shall not be open for read and write access at the same time on different streams # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="File Open for Both Read and Write" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Float Division By Zero" language=c # Misra2012:14.1: A loop counter shall not have essentially floating type WARNING_FILTER += allow class="Float-typed Loop Counter" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Floating Point Domain Error" language=c # Misra2012:10.1: Operands shall not be of an inappropriate essential type WARNING_FILTER += allow class="Floating Point Equality" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Floating Point Range Error" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Free Null Pointer" language=c # Misra2012:2.2: A project shall not contain dead code # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Function Call Has No Effect" language=c # Misra2012:11.1: Conversions shall not be performed between a pointer to a function and any other type WARNING_FILTER += allow class="Function Pointer Conversion" language=c # Misra2012:D.4.9: A function should be used in preference to a function-like macro where they are interchangeable WARNING_FILTER += allow class="Function-Like Macro" language=c # Misra2012:1.2: Language extensions should not be used WARNING_FILTER += allow class="GNU Extension" language=c # Misra2012:1.2: Language extensions should not be used WARNING_FILTER += allow class="GNU Typeof" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Gamma on Zero" language=c # Misra2012:8.3: All declarations of an object or function shall use the same names and type qualifiers WARNING_FILTER += allow class="Global Variable Declared with Different Types" language=c # Misra2012:15.1: The goto statement should not be used WARNING_FILTER += allow class="Goto Statement" language=c # Misra2012:17.7: The value returned by a function having non-void return type shall be used # Misra2012:D.4.7: If a function returns error information, then that error information shall be tested # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Ignored Return Value" language=c # Misra2012:17.3: A function shall not be declared implicitly # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Implicit Function Declaration" language=c # Misra2012:8.1: Types shall be explicitly specified # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Implicit int on main" language=c # Misra2012:10.3: The value of an expression shall not be assigned to an object with a narrower essential type or of a different essential type category WARNING_FILTER += allow class="Inappropriate Assignment Type" language=c # Misra2012:6.1: Bit-fields shall only be declared with an appropriate type WARNING_FILTER += allow class="Inappropriate Bit-field Type" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Inappropriate C Atomic Initialization" language=c # Misra2012:10.5: The value of an expression should not be cast to an inappropriate essential type WARNING_FILTER += allow class="Inappropriate Cast Type" language=c # Misra2012:10.8: The value of a composite expression shall not be cast to a different essential type category or a wider essential type WARNING_FILTER += allow class="Inappropriate Cast Type: Expression" language=c # Misra2012:10.2: Expressions of essentially character type shall not be used inappropriately in addition and subtraction operations WARNING_FILTER += allow class="Inappropriate Character Arithmetic" language=c # "Inappropriate Include File Specification" is not enabled by this preset. # - All of its relevant categories are more closely related to other classes that are enabled by the preset. # - Misra2012:20.3 is better matched by "Malformed #include" # Misra2012:10.1: Operands shall not be of an inappropriate essential type WARNING_FILTER += allow class="Inappropriate Operand Type" language=c # Misra2012:D.4.10: Precautions shall be taken in order to prevent the contents of a header file being included more than once WARNING_FILTER += allow class="Include File Without Guard" language=c # Misra2012:8.2: Function types shall be in prototype form with named parameters # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Incomplete Function Prototype" language=c # Misra2012:8.12: Within an enumerator list, the value of an implicitly-specified enumeration constant shall be unique WARNING_FILTER += allow class="Inconsistent Enumerator Initialization" language=c # Misra2012:8.3: All declarations of an object or function shall use the same names and type qualifiers WARNING_FILTER += allow class="Inconsistent Function Declarations" language=c # Misra2012:8.3: All declarations of an object or function shall use the same names and type qualifiers WARNING_FILTER += allow class="Inconsistent Object Declarations" language=c # Misra2012:13.2: The value of an expression and its persistent side effects shall be the same under all permitted evaluation orders and shall be independent from thread interleaving WARNING_FILTER += allow class="Indeterminate Order of Evaluation" language=c # Misra2012:D.4.3: Assembly language shall be encapsulated and isolated WARNING_FILTER += allow class="Inline Assembly Code" language=c # Misra2012:8.10: An inline function shall be declared with the static storage class WARNING_FILTER += allow class="Inline Function Not static" language=c # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Integer Overflow of Allocation Size" language=c # Misra2012:20.13: A line whose first token is # shall be a valid preprocessing directive WARNING_FILTER += allow class="Invalid Preprocessor Directive" language=c # Misra2012:15.3: Any label referenced by a goto statement shall be declared in the same block, or in any block enclosing the goto statement WARNING_FILTER += allow class="Label Not In Enclosing Block" language=c # Misra2012:22.1: All resources obtained dynamically by means of Standard Library functions shall be explicitly released # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Leak" language=c # Misra2012:5.8: Identifiers that define objects or functions with external linkage shall be unique # Misra2012:5.9: Identifiers that define objects or functions with internal linkage should be unique WARNING_FILTER += allow class="Library Function Override" language=c # Misra2012:3.2: Line-splicing shall not be used in // comments WARNING_FILTER += allow class="Line Splicing in Comment" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Logarithm on Negative Value" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Logarithm on Zero" language=c # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="MAX_PATH Exceeded" language=c # Misra2012:20.10: The # and ## preprocessor operators should not be used # Misra2012:20.12: A macro parameter used as an operand to the # or ## operators, which is itself subject to further macro replacement, shall only be used as an operand to these operators WARNING_FILTER += allow class="Macro Argument is both Mixed and Expanded" language=c # Misra2012:21.1: #define and #undef shall not be used on a reserved identifier or reserved macro name WARNING_FILTER += allow class="Macro Definition of Reserved Name" language=c # Misra2012:20.4: A macro shall not be defined with the same name as a keyword WARNING_FILTER += allow class="Macro Name is C Keyword" language=c # Misra2012:20.7: Expressions resulting from the expansion of macro parameters shall be enclosed in parentheses WARNING_FILTER += allow class="Macro Parameter Not Parenthesized" language=c # Misra2012:20.5: #undef should not be used # Misra2012:21.1: #define and #undef shall not be used on a reserved identifier or reserved macro name WARNING_FILTER += allow class="Macro Undefinition of Reserved Name" language=c # Misra2012:20.10: The # and ## preprocessor operators should not be used WARNING_FILTER += allow class="Macro Uses # Operator" language=c # Misra2012:20.10: The # and ## preprocessor operators should not be used # Misra2012:20.12: A macro parameter used as an operand to the # or ## operators, which is itself subject to further macro replacement, shall only be used as an operand to these operators WARNING_FILTER += allow class="Macro Uses ## Operator" language=c # Misra2012:20.3: The #include directive shall be followed by either a or "filename" sequence WARNING_FILTER += allow class="Malformed #include" language=c # Misra2012:14.2: A for loop shall be well-formed WARNING_FILTER += allow class="Malformed for-loop Condition" language=c # Misra2012:14.2: A for loop shall be well-formed WARNING_FILTER += allow class="Malformed for-loop Initialization" language=c # Misra2012:14.2: A for loop shall be well-formed WARNING_FILTER += allow class="Malformed for-loop Step" language=c # Misra2012:16.1: All switch statements shall be well-formed WARNING_FILTER += allow class="Malformed switch Statement" language=c # Misra2012:1.2: Language extensions should not be used WARNING_FILTER += allow class="Microsoft Extension" language=c # Misra2012:10.4: Both operands of an operator in which the usual arithmetic conversions are performed shall have the same essential type category WARNING_FILTER += allow class="Mismatched Operand Types" language=c # Misra2012:15.5: A function should have a single point of exit at the end WARNING_FILTER += allow class="Misplaced Return Statement" language=c # Misra2012:16.2: A switch label shall only be used when the most closely-enclosing compound statement is the body of a switch statement WARNING_FILTER += allow class="Misplaced case" language=c # Misra2012:16.5: A default label shall appear as either the first or the last switch label of a switch statement WARNING_FILTER += allow class="Misplaced default" language=c # Misra2012:9.2: The initializer for an aggregate or union shall be enclosed in braces WARNING_FILTER += allow class="Missing Braces in Initialization" language=c # Misra2012:8.1: Types shall be explicitly specified # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Missing Declaration Specifiers" language=c # Misra2012:8.5: An external object or function shall be declared once in one and only one file WARNING_FILTER += allow class="Missing External Declaration" language=c # Misra2012:8.6: An identifier with external linkage shall have exactly one external definition WARNING_FILTER += allow class="Missing External Definition" language=c # Misra2012:15.7: All if ... else if constructs shall be terminated with an else statement WARNING_FILTER += allow class="Missing Final else" language=c # Misra2012:7.2: A "u" or "U" suffix shall be applied to all integer constants that are represented in an unsigned type WARNING_FILTER += allow class="Missing Literal Suffix" language=c # Misra2012:12.1: The precedence of operators within expressions should be made explicit WARNING_FILTER += allow class="Missing Parentheses" language=c # Misra2012:17.4: All exit paths from a function with non-void return type shall have an explicit return statement with an expression # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Missing Return Statement" language=c # Misra2012:D.4.7: If a function returns error information, then that error information shall be tested WARNING_FILTER += allow class="Missing Test of Error Code" language=c # Misra2012:8.1: Types shall be explicitly specified # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Missing Type Specifier" language=c # Misra2012:16.3: An unconditional break statement shall terminate every switch-clause WARNING_FILTER += allow class="Missing break" language=c # Misra2012:16.4: Every switch statement shall have a default label WARNING_FILTER += allow class="Missing default" language=c # Misra2012:14.2: A for loop shall be well-formed WARNING_FILTER += allow class="Missing for-loop Step" language=c # Misra2012:14.2: A for loop shall be well-formed WARNING_FILTER += allow class="Missing for-loop Termination" language=c # Misra2012:D.4.3: Assembly language shall be encapsulated and isolated WARNING_FILTER += allow class="Mixed Assembly and Code" language=c # Misra2012:17.8: A function parameter should not be modified WARNING_FILTER += allow class="Modified Parameter" language=c # Misra2012:15.4: There should be no more than one break or goto statement used to terminate any iteration statement WARNING_FILTER += allow class="Multiple Abnormal Loop Exits" language=c # Misra2012:8.5: An external object or function shall be declared once in one and only one file WARNING_FILTER += allow class="Multiple Declarations of a Global" language=c # Misra2012:8.5: An external object or function shall be declared once in one and only one file WARNING_FILTER += allow class="Multiple External Declarations" language=c # Misra2012:8.6: An identifier with external linkage shall have exactly one external definition WARNING_FILTER += allow class="Multiple External Definitions" language=c # Misra2012:15.5: A function should have a single point of exit at the end WARNING_FILTER += allow class="Multiple Return Statements" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Negative Character Value" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:12.2: The right hand operand of a shift operator shall lie in the range zero to one less than the width in bits of the essential type of the left hand operand # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Negative Shift Amount" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Negative file descriptor" language=c # Misra2012:3.1: The character sequences /* and // shall not be used within a comment # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Nested Comment" language=c # Misra2012:20.14: 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 WARNING_FILTER += allow class="No Matching #endif" language=c # Misra2012:20.14: 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 WARNING_FILTER += allow class="No Matching #if" language=c # Misra2012:8.4: A compatible declaration shall be visible when an object or function with external linkage is defined WARNING_FILTER += allow class="No Previous Declaration" language=c # Misra2012:20.8: The controlling expression of a #if or #elif preprocessing directive shall evaluate to 0 or 1 WARNING_FILTER += allow class="Non-Boolean Preprocessor Expression" language=c # Misra2012:7.4: A string literal shall not be assigned to an object unless the object's type is "pointer to const-qualified char" WARNING_FILTER += allow class="Non-const String Literal" language=c # Misra2012:5.1: External identifiers shall be distinct WARNING_FILTER += allow class="Non-distinct Identifiers: External Names" language=c # Misra2012:5.4: Macro identifiers shall be distinct WARNING_FILTER += allow class="Non-distinct Identifiers: Macro/Macro" language=c # Misra2012:5.5: Identifiers shall be distinct from macro names WARNING_FILTER += allow class="Non-distinct Identifiers: Macro/Other" language=c # Misra2012:5.3: An identifier declared in an inner scope shall not hide an identifier declared in an outer scope WARNING_FILTER += allow class="Non-distinct Identifiers: Nested Scope" language=c # Misra2012:5.2: Identifiers declared in the same scope and name space shall be distinct WARNING_FILTER += allow class="Non-distinct Identifiers: Same Scope" language=c # Misra2012:5.8: Identifiers that define objects or functions with external linkage shall be unique WARNING_FILTER += allow class="Non-unique Identifiers: External Name" language=c # Misra2012:5.9: Identifiers that define objects or functions with internal linkage should be unique WARNING_FILTER += allow class="Non-unique Identifiers: Internal Name" language=c # Misra2012:5.7: A tag name shall be a unique identifier WARNING_FILTER += allow class="Non-unique Identifiers: Tag" language=c # Misra2012:5.6: A typedef name shall be a unique identifier WARNING_FILTER += allow class="Non-unique Identifiers: Typedef" language=c # Misra2012:D.4.7: If a function returns error information, then that error information shall be tested WARNING_FILTER += allow class="Non-zero Error Code" language=c # Misra2012:8.1: Types shall be explicitly specified # This check is enabled by default for the language(s) C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Nonstandard Implicit Integer" language=c # Misra2012:1.1: The program shall contain no violations of the standard C syntax and constraints, and shall not exceed the implementation's translation limits WARNING_FILTER += allow class="Not All Warnings Are Enabled" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Null Pointer Dereference" language=c # Misra2012:7.1: Octal constants shall not be used WARNING_FILTER += allow class="Octal Constant" language=c # Misra2012:9.4: An element of an object shall not be initialized more than once WARNING_FILTER += allow class="Over-initialized Element" language=c # Misra2012:19.1: An object shall not be assigned or copied to an overlapping object # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Overlapping Memory Regions" language=c # Misra2012:8.1: Types shall be explicitly specified # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Parameter Identifier List Needs Function Definition" language=c # Misra2012:9.3: Arrays shall not be partially initialized WARNING_FILTER += allow class="Partially Uninitialized Array" language=c # Misra2012:8.13: A pointer should point to a const-qualified type whenever possible WARNING_FILTER += allow class="Pointed-to Type Could Be const" language=c # Misra2012:18.1: A pointer resulting from arithmetic on a pointer operand shall address an element of the same array as that pointer operand # Misra2012:18.2: Subtraction between pointers shall only be applied to pointers that address elements of the same array # Misra2012:18.4: The +, -, += and -= operators should not be applied to an expression of pointer type WARNING_FILTER += allow class="Pointer Arithmetic" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:18.1: A pointer resulting from arithmetic on a pointer operand shall address an element of the same array as that pointer operand # Misra2012:18.2: Subtraction between pointers shall only be applied to pointers that address elements of the same array WARNING_FILTER += allow class="Pointer Before Beginning of Object" language=c # Misra2012:11.4: A conversion should not be performed between a pointer to object and an integer type # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Pointer Conversion Loses Bits" language=c # Misra2012:11.4: A conversion should not be performed between a pointer to object and an integer type WARNING_FILTER += allow class="Pointer Conversion to Same Size Integer" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:18.1: A pointer resulting from arithmetic on a pointer operand shall address an element of the same array as that pointer operand # Misra2012:18.2: Subtraction between pointers shall only be applied to pointers that address elements of the same array WARNING_FILTER += allow class="Pointer Past End of Object" language=c # Misra2012:18.8: Variable-length array types shall not be used WARNING_FILTER += allow class="Pointer to Variably-modified Array Type" language=c # Misra2012:21.10: The Standard Library time and date functions shall not be used WARNING_FILTER += allow class="Potential Timebomb" language=c # Misra2012:20.6: Tokens that look like a preprocessing directive shall not occur within a macro argument WARNING_FILTER += allow class="Preprocessing Directives in Macro Argument" language=c # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Raises FE_INVALID" language=c # Misra2012:17.2: Functions shall not call themselves, either directly or indirectly WARNING_FILTER += allow class="Recursion" language=c # Misra2012:14.3: Controlling expressions shall not be invariant # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Redundant Condition" language=c # Misra2012:8.14: The restrict type qualifier shall not be used WARNING_FILTER += allow class="Restrict Qualifier Used" language=c # Misra2012:18.6: The address of an object with automatic or thread-local storage shall not be copied to another object that persists after the first object has ceased to exist # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Return Pointer to Local" language=c # Misra2012:8.7: Functions and objects should not be defined with external linkage if they are referenced in only one translation unit # Misra2012:8.8: The static storage class specifier shall be used in all declarations of objects and functions that have internal linkage WARNING_FILTER += allow class="Scope Could Be File Static" language=c # Misra2012:8.7: Functions and objects should not be defined with external linkage if they are referenced in only one translation unit # Misra2012:8.8: The static storage class specifier shall be used in all declarations of objects and functions that have internal linkage # Misra2012:8.9: An object should be declared at block scope if its identifier only appears in a single function WARNING_FILTER += allow class="Scope Could Be Local Static" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:12.2: The right hand operand of a shift operator shall lie in the range zero to one less than the width in bits of the essential type of the left hand operand # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Shift Amount Exceeds Bit Width" language=c # Misra2012:13.3: A full expression containing an increment (++) or decrement (--) operator should have no other potential side effects other than that caused by the increment or decrement operator WARNING_FILTER += allow class="Side Effects in Expression with Decrement" language=c # Misra2012:13.3: A full expression containing an increment (++) or decrement (--) operator should have no other potential side effects other than that caused by the increment or decrement operator WARNING_FILTER += allow class="Side Effects in Expression with Increment" language=c # Misra2012:13.1: Initializer lists shall not contain persistent side effects WARNING_FILTER += allow class="Side Effects in Initializer List" language=c # Misra2012:13.5: The right hand operand of a logical && or || operator shall not contain persistent side effects WARNING_FILTER += allow class="Side Effects in Logical Operand" language=c # Misra2012:13.6: The operand of the sizeof operator shall not contain any expression which has potential side effects WARNING_FILTER += allow class="Side Effects in sizeof" language=c # Misra2012:6.2: Single-bit named bit fields shall not be of a signed type # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Signed One Bit Field" language=c # Misra2012:D.4.13: Functions which are designed to provide operations on a resource should be called in an appropriate sequence WARNING_FILTER += allow class="Socket In Wrong State" language=c # Misra2012:17.6: The declaration of an array parameter shall not contain the static keyword between the [ ] WARNING_FILTER += allow class="Static Array Parameter" language=c # Misra2012:18.2: Subtraction between pointers shall only be applied to pointers that address elements of the same array # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Subtraction of Unrelated Pointers" language=c # Misra2012:18.1: A pointer resulting from arithmetic on a pointer operand shall address an element of the same array as that pointer operand # Misra2012:18.2: Subtraction between pointers shall only be applied to pointers that address elements of the same array # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Tainted Buffer Access" language=c # Misra2012:D.4.13: Functions which are designed to provide operations on a resource should be called in an appropriate sequence # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Thread is not Joinable" language=c # Misra2012:16.6: Every switch statement shall have at least two switch-clauses WARNING_FILTER += allow class="Too Few Cases in switch" language=c # Misra2012:18.5: Declarations should contain no more than two levels of pointer nesting WARNING_FILTER += allow class="Too Much Indirection in Declaration" language=c # Misra2012:4.2: Trigraphs should not be used WARNING_FILTER += allow class="Trigraph" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:22.2: A block of memory shall only be freed if it was allocated by means of a Standard Library function # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Type Mismatch" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:18.1: A pointer resulting from arithmetic on a pointer operand shall address an element of the same array as that pointer operand # Misra2012:18.2: Subtraction between pointers shall only be applied to pointers that address elements of the same array # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Type Overrun" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:18.1: A pointer resulting from arithmetic on a pointer operand shall address an element of the same array as that pointer operand # Misra2012:18.2: Subtraction between pointers shall only be applied to pointers that address elements of the same array # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Type Underrun" language=c # Misra2012:D.4.5: Identifiers in the same name space with overlapping visibility should be typographically unambiguous WARNING_FILTER += allow class="Typographically Ambiguous Identifiers" language=c # Misra2012:8.1: Types shall be explicitly specified # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Undeclared Parameter" language=c # Misra2012:20.9: All identifiers used in the controlling expression of #if or #elif preprocessing directives shall be #define'd before evaluation # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Undefined Macro in #if" language=c # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Undefined Power of Zero" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # Misra2012:9.1: The value of an object with automatic storage duration shall not be read before it has been set # Misra2012:D.4.1: Run-time failures shall be minimized # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Uninitialized Variable" language=c # Misra2012:19.2: The union keyword should not be used WARNING_FILTER += allow class="Union Type" language=c # Misra2012:2.1: A project shall not contain unreachable code # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Unreachable Call" language=c # Misra2012:2.1: A project shall not contain unreachable code # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Unreachable Computation" language=c # Misra2012:2.1: A project shall not contain unreachable code # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Unreachable Conditional" language=c # Misra2012:2.1: A project shall not contain unreachable code WARNING_FILTER += allow class="Unreachable Control Flow" language=c # Misra2012:2.1: A project shall not contain unreachable code # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Unreachable Data Flow" language=c # Misra2012:9.5: Where designated initializers are used to initialize an array object the size of the array shall be specified explicitly WARNING_FILTER += allow class="Unspecified Array Size with Designator Initialization" language=c # Misra2012:1.3: There shall be no occurrence of undefined or critical unspecified behaviour # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Unterminated C String" language=c # Misra2012:4.1: Octal and hexadecimal escape sequences shall be terminated WARNING_FILTER += allow class="Unterminated Escape Sequence" language=c # Misra2012:2.6: A function should not contain unused label declarations WARNING_FILTER += allow class="Unused Label" language=c # Misra2012:2.5: A project should not contain unused macro definitions WARNING_FILTER += allow class="Unused Macro" language=c # Misra2012:2.7: A function should not contain unused parameters WARNING_FILTER += allow class="Unused Parameter" language=c # Misra2012:2.4: A project should not contain unused tag declarations WARNING_FILTER += allow class="Unused Tag" language=c # Misra2012:2.3: A project should not contain unused type declarations WARNING_FILTER += allow class="Unused Type" language=c # Misra2012:2.2: A project shall not contain dead code # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Unused Value" language=c # Misra2012:22.6: The value of a pointer to a FILE shall not be used after the associated stream has been closed # This check is enabled by default for the language(s) C, C++, x86, x86_64 # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Use After Close" language=c # Misra2012:20.5: #undef should not be used WARNING_FILTER += allow class="Use of #undef" language=c # Misra2012:21.12: The standard header file shall not be used WARNING_FILTER += allow class="Use of Exception Handling Function" language=c # Misra2012:21.4: The standard header file shall not be used WARNING_FILTER += allow class="Use of " language=c # Misra2012:21.5: The standard header file shall not be used WARNING_FILTER += allow class="Use of " language=c # Misra2012:17.1: The standard header file shall not be used WARNING_FILTER += allow class="Use of Feature" language=c # Misra2012:21.6: The Standard Library input/output functions shall not be used WARNING_FILTER += allow class="Use of Input/Output" language=c # Misra2012:21.6: The Standard Library input/output functions shall not be used WARNING_FILTER += allow class="Use of Input/Output Macro" language=c # Misra2012:21.3: The memory allocation and deallocation functions of shall not be used WARNING_FILTER += allow class="Use of Allocator/Deallocator" language=c # Misra2012:21.3: The memory allocation and deallocation functions of shall not be used WARNING_FILTER += allow class="Use of Allocator/Deallocator Macro" language=c # Misra2012:21.11: The standard header file should not be used WARNING_FILTER += allow class="Use of " language=c # Misra2012:21.10: The Standard Library time and date functions shall not be used WARNING_FILTER += allow class="Use of Time/Date Function" language=c # Misra2012:21.6: The Standard Library input/output functions shall not be used WARNING_FILTER += allow class="Use of Input/Output" language=c # Misra2012:21.6: The Standard Library input/output functions shall not be used WARNING_FILTER += allow class="Use of Input/Output Macro" language=c # Misra2012:12.3: The comma operator should not be used WARNING_FILTER += allow class="Use of Comma Operator" language=c # Misra2012:21.8: The Standard Library termination functions of shall not be used # Misra2012:D.4.1: Run-time failures shall be minimized WARNING_FILTER += allow class="Use of abort" language=c # Misra2012:21.7: The atof, atoi, atol and atoll functions of shall not be used WARNING_FILTER += allow class="Use of atof" language=c # Misra2012:21.7: The atof, atoi, atol and atoll functions of shall not be used WARNING_FILTER += allow class="Use of atoi" language=c # Misra2012:21.7: The atof, atoi, atol and atoll functions of shall not be used WARNING_FILTER += allow class="Use of atol" language=c # Misra2012:21.7: The atof, atoi, atol and atoll functions of shall not be used WARNING_FILTER += allow class="Use of atoll" language=c # Misra2012:21.9: The library functions bsearch and qsort of shall not be used WARNING_FILTER += allow class="Use of bsearch" language=c # Misra2012:21.8: The Standard Library termination functions of shall not be used WARNING_FILTER += allow class="Use of exit" language=c # Misra2012:21.8: The Standard Library termination functions of shall not be used WARNING_FILTER += allow class="Use of getenv" language=c # Misra2012:21.4: The standard header file shall not be used WARNING_FILTER += allow class="Use of longjmp" language=c # Misra2012:18.6: The address of an object with automatic or thread-local storage shall not be copied to another object that persists after the first object has ceased to exist WARNING_FILTER += allow class="Use of putenv" language=c # Misra2012:21.9: The library functions bsearch and qsort of shall not be used WARNING_FILTER += allow class="Use of qsort" language=c # Misra2012:21.3: The memory allocation and deallocation functions of shall not be used # Misra2012:D.4.12: Dynamic memory allocation shall not be used WARNING_FILTER += allow class="Use of realloc" language=c # Misra2012:21.4: The standard header file shall not be used WARNING_FILTER += allow class="Use of setjmp" language=c # Misra2012:2.2: A project shall not contain dead code # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="Useless Assignment" language=c # Misra2012:1.1: The program shall contain no violations of the standard C syntax and constraints, and shall not exceed the implementation's translation limits WARNING_FILTER += allow class="Warnings Not Treated As Errors" language=c # Misra2012:22.4: There shall be no attempt to write to a stream which has been opened as read-only WARNING_FILTER += allow class="Write to Read Only File" language=c # Misra2012:D.4.13: Functions which are designed to provide operations on a resource should be called in an appropriate sequence WARNING_FILTER += allow class="chroot without chdir" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="cosh on High Number" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="cosh on Low Number" language=c # Misra2012:D.4.1: Run-time failures shall be minimized # Misra2012:D.4.11: The validity of values passed to library functions shall be checked # This check is enabled by default for the language(s) C, C++ # It may remain in effect even if the following line is commented out. WARNING_FILTER += allow class="sqrt on Negative Value" language=c # # The remainder of this file was generated from template 'codesonar/presets/misra2012-0.conf.in' # WARNING_FILTER += discard class="Basic Numerical Type Used" line_contents=~\<(main|argc|argv)\>