# This file was generated from template 'codesonar/presets/autosarc++14.conf.in' # # This conf file configures CodeSonar to generate warnings for various # AUTOSAR:2017 rules. # Configuration settings required by one or more AUTOSAR checks. SCOPE_CHECK_SUGGESTS_LOCAL_STATIC = Yes BOOL_TYPES += bool,true,false # Explicitly enable all warning classes that correspond to one or more # AUTOSAR 2017 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 AUTOSAR-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 # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:M16-3-1: There shall be at most one occurrence of the # or ## operators in a single macro definition. WARNING_FILTER += allow class="## Follows # Operator" language=c++ # AUTOSARC++14:A4-7-1: An integer expression shall not lead to data loss. WARNING_FILTER += allow class="Addition Overflow of Size" language=c++ # AUTOSARC++14:M7-3-3: There shall be no unnamed namespaces in header files. WARNING_FILTER += allow class="Anonymous Namespace in Header File" language=c++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A18-1-1: C-style arrays shall not be used. WARNING_FILTER += allow class="Array Parameter" language=c++ # AUTOSARC++14:A18-1-1: C-style arrays shall not be used. WARNING_FILTER += allow class="Array Parameter Mismatch" language=c++ # AUTOSARC++14:A18-1-1: C-style arrays shall not be used. WARNING_FILTER += allow class="Array to Pointer Conversion on Temporary Object" language=c++ # AUTOSARC++14:A18-1-1: C-style arrays shall not be used. # AUTOSARC++14:M5-2-12: An identifier with array type passed as a function argument shall not decay to a pointer. WARNING_FILTER += allow class="Array to Pointer Decay" language=c++ # AUTOSARC++14:M7-4-2: Assembler instructions shall only be introduced using the asm declaration. WARNING_FILTER += allow class="Assembly Pragma" language=c++ # AUTOSARC++14:M6-2-1: Assignment operators shall not be used in sub-expressions. WARNING_FILTER += allow class="Assignment Result in Expression" language=c++ # AUTOSARC++14:M6-6-2: The goto statement shall jump to a label declared later in the same function body. WARNING_FILTER += allow class="Backwards goto" language=c++ # AUTOSARC++14:A2-13-1: Only those escape sequences that are defined in ISO/IEC 14882:2014 shall be used. # 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="Bad Character Value" language=c++ # AUTOSARC++14:A2-3-1: Only those characters specified in the C++ Language Standard basic source character set shall be used in the source code. WARNING_FILTER += allow class="Bad Token" language=c++ # AUTOSARC++14:A3-9-1: Fixed width integer types from , indicating the size and signedness, shall be used in place of the basic numerical types. WARNING_FILTER += allow class="Basic Numerical Type Used" language=c++ # AUTOSARC++14:A9-5-1: Unions shall not be used. WARNING_FILTER += allow class="Bit-field in Union" language=c++ # AUTOSARC++14:M6-3-1: The statement forming the body of a switch, while, do ... while or for statement shall be a compound statement. # AUTOSARC++14:M6-4-1: 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. WARNING_FILTER += allow class="Body Is Not Compound Statement" language=c++ # AUTOSARC++14:M6-4-7: The condition of a switch statement shall not have bool type. WARNING_FILTER += allow class="Boolean switch Expression" language=c++ # AUTOSARC++14:A8-5-3: A variable of type auto shall not be initialized using {} or ={} braced-initialization. WARNING_FILTER += allow class="Braced Initializer with auto" language=c++ # AUTOSARC++14:M15-0-3: Control shall not be transferred into a try or catch block using a goto or a switch statement. # 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="Branch Into Handler" language=c++ # AUTOSARC++14:M15-0-3: Control shall not be transferred into a try or catch block using a goto or a switch statement. # 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="Branch Into try Block" language=c++ # AUTOSARC++14:A27-0-2: A C-style string shall guarantee sufficient space for data and the null terminator. # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M5-0-16: A pointer operand and any pointer resulting from pointer arithmetic using that operand shall both address elements of the same array. # 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++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M5-0-16: A pointer operand and any pointer resulting from pointer arithmetic using that operand shall both address elements of the same array. # 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++ # AUTOSARC++14:A27-0-4: C-style strings shall not be used. WARNING_FILTER += allow class="C String" language=c++ # AUTOSARC++14:A5-2-2: Traditional C-style casts shall not be used. WARNING_FILTER += allow class="C-style Cast" language=c++ # AUTOSARC++14:A4-7-1: An integer expression shall not lead to data loss. # AUTOSARC++14:A7-2-1: An expression with enum underlying type shall only have values corresponding to the enumerators of the enumeration. # AUTOSARC++14:M5-0-9: An explicit integral conversion shall not change the signedness of the underlying type of a cvalue expression. # AUTOSARC++14:M5-2-2: A pointer to a virtual base class shall only be cast to a pointer to a derived class by means of dynamic_cast. # 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++ # AUTOSARC++14:A5-2-3: A cast shall not remove any const or volatile qualification from the type of a pointer or reference. WARNING_FILTER += allow class="Cast Removes const Qualifier" language=c++ # AUTOSARC++14:A5-2-3: A cast shall not remove any const or volatile qualification from the type of a pointer or reference. WARNING_FILTER += allow class="Cast Removes volatile Qualifier" language=c++ # AUTOSARC++14:A5-2-4: reinterpret_cast shall not be used. # AUTOSARC++14:M5-2-2: A pointer to a virtual base class shall only be cast to a pointer to a derived class by means of dynamic_cast. WARNING_FILTER += allow class="Cast: Virtual Base to Derived" language=c++ # AUTOSARC++14:A5-2-4: reinterpret_cast shall not be used. WARNING_FILTER += allow class="Cast: reinterpret_cast" language=c++ # AUTOSARC++14:A18-5-11: "operator new" and "operator delete" shall be defined together. # 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="Class With operator delete but No operator new" language=c++ # AUTOSARC++14:A18-5-11: "operator new" and "operator delete" shall be defined together. # 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="Class With operator new but No operator delete" language=c++ # AUTOSARC++14:M16-0-1: #include directives in a file shall only be preceded by other pre-processor directives or comments. WARNING_FILTER += allow class="Code Before #include" language=c++ # AUTOSARC++14:A4-7-1: An integer expression shall not lead to data loss. # AUTOSARC++14:A7-2-1: An expression with enum underlying type shall only have values corresponding to the enumerators of the enumeration. # AUTOSARC++14:M5-0-4: An implicit integral conversion shall not change the signedness of the underlying type. # AUTOSARC++14:M5-0-6: An implicit integral or floating-point conversion shall not reduce the size of the underlying 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="Coercion Alters Value" language=c++ # AUTOSARC++14:M4-10-2: Literal zero (0) shall not be used as the null-pointer-constant. WARNING_FILTER += allow class="Coercion: Integer Constant to Pointer" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. # 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="Command Injection" language=c++ # AUTOSARC++14:A2-7-2: Sections of code shall not be "commented out". WARNING_FILTER += allow class="Commented-out Code" language=c++ # AUTOSARC++14:M5-0-18: >, >=, <, <= shall not be applied to objects of pointer type, except where they point to 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="Comparison of Unrelated Pointers" language=c++ # AUTOSARC++14:A13-2-3: A relational operator shall return a boolean value. # AUTOSARC++14:A5-0-2: The condition of an if-statement and the condition of an iteration statement shall have type bool. WARNING_FILTER += allow class="Condition Is Not Boolean" language=c++ # AUTOSARC++14:M2-13-4: Literal suffixes shall be upper case. WARNING_FILTER += allow class="Confusing Literal Suffix" language=c++ # AUTOSARC++14:M5-2-11: The comma operator, && operator and the || operator shall not be overloaded. # AUTOSARC++14:M5-3-3: The unary & operator shall not be overloaded. WARNING_FILTER += allow class="Confusing Operator Overload" language=c++ # AUTOSARC++14:M6-6-3: The continue statement shall only be used within a well-formed for loop. WARNING_FILTER += allow class="Continue Statement" language=c++ # AUTOSARC++14:A13-5-2: All user-defined conversion operators shall be defined explicit. # AUTOSARC++14:A13-5-3: User-defined conversion operators should not be used. WARNING_FILTER += allow class="Conversion Operator Not Explicit" language=c++ # AUTOSARC++14:M5-2-6: A cast shall not convert a pointer to a function to any other pointer type, including a pointer to function type. # AUTOSARC++14:M8-4-4: A function identifier shall either be used to call the function or it shall be preceded by &. WARNING_FILTER += allow class="Conversion from Function Pointer" language=c++ # AUTOSARC++14:M8-4-4: A function identifier shall either be used to call the function or it shall be preceded by &. WARNING_FILTER += allow class="Conversion to Function Pointer" language=c++ # AUTOSARC++14:A5-0-2: The condition of an if-statement and the condition of an iteration statement shall have type bool. # AUTOSARC++14:M5-0-14: The first operand of a conditional-operator shall have type bool. # AUTOSARC++14:M5-3-1: Each operand of the ! operator, the logical && or the logical || operators shall have type bool. WARNING_FILTER += allow class="Conversion to Type bool" language=c++ # AUTOSARC++14:M5-2-8: An object with integer type or pointer to void type shall not be converted to an object with pointer type. # AUTOSARC++14:M5-2-9: A cast shall not convert a pointer type to an integral type. WARNING_FILTER += allow class="Conversion: Pointer/Integer" language=c++ # AUTOSARC++14:M5-2-8: An object with integer type or pointer to void type shall not be converted to an object with pointer type. WARNING_FILTER += allow class="Conversion: Void Pointer to Object Pointer" language=c++ # AUTOSARC++14:A12-8-1: Move and copy constructors shall move and respectively copy base classes and data members of a class, without any side effects. WARNING_FILTER += allow class="Copy Operation Parameter Is Not const" language=c++ # AUTOSARC++14:A5-2-2: Traditional C-style casts shall not be used. # AUTOSARC++14:M5-2-6: A cast shall not convert a pointer to a function to any other pointer type, including a pointer to function type. # AUTOSARC++14:M8-4-4: A function identifier shall either be used to call the function or it shall be preceded by &. # 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++ # AUTOSARC++14:A16-2-1: The ', ", /*, //, \ characters shall not occur in a header file name or in #include directive. WARNING_FILTER += allow class="Dangerous Include File Name" language=c++ # AUTOSARC++14:A18-1-1: C-style arrays shall not be used. WARNING_FILTER += allow class="Declaration of Flexible Array Member" language=c++ # AUTOSARC++14:M17-0-2: The names of standard library macros and objects shall not be reused. # AUTOSARC++14:M17-0-3: The names of standard library functions shall not be overridden. WARNING_FILTER += allow class="Declaration of Reserved Name" language=c++ # AUTOSARC++14:A18-1-1: C-style arrays shall not be used. WARNING_FILTER += allow class="Declaration of Variable Length Array" language=c++ # AUTOSARC++14:A0-1-3: Every function defined in an anonymous namespace, or static function with internal linkage, or private member function shall be used. # AUTOSARC++14:M0-1-3: A project shall not contain unused variables. # AUTOSARC++14:M0-1-4: A project shall not contain non-volatile POD variables having only one use. WARNING_FILTER += allow class="Declared but Not Referenced" language=c++ # AUTOSARC++14:A26-5-2: Random number engines shall not be default-initialized. WARNING_FILTER += allow class="Default Initialization of Random Number Generator" language=c++ # AUTOSARC++14:A26-5-2: Random number engines shall not be default-initialized. WARNING_FILTER += allow class="Default Seed in PRNG" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A18-1-3: The std::auto_ptr type shall not be used. # 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="Deprecated Entity" language=c++ # AUTOSARC++14:A5-2-4: reinterpret_cast shall not be used. # AUTOSARC++14:M5-2-2: A pointer to a virtual base class shall only be cast to a pointer to a derived class by means of dynamic_cast. WARNING_FILTER += allow class="Derived Class From Virtual Base" language=c++ # AUTOSARC++14:A5-6-1: The right hand operand of the integer division or remainder operators shall not be equal to zero. # 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++ # AUTOSARC++14:A18-5-7: If non-realtime implementation of dynamic memory management functions is used in the project, then memory shall only be allocated and deallocated during non-realtime program phases. WARNING_FILTER += allow class="Dynamic Allocation After Initialization" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A15-4-1: Dynamic exception-specification shall not be used. WARNING_FILTER += allow class="Dynamic Exception Specification Not Permitted" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A15-4-1: Dynamic exception-specification shall not be used. # 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="Dynamic Exception Specifications Deprecated" language=c++ # AUTOSARC++14:A8-4-1: Functions shall not be defined using the ellipsis notation. WARNING_FILTER += allow class="Ellipsis" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A15-4-1: Dynamic exception-specification shall not be used. # 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="Empty throw Specification Not C++20" language=c++ # AUTOSARC++14:A7-2-2: Enumeration underlying base type shall be explicitly defined. WARNING_FILTER += allow class="Enumeration Has Implicit Underlying Type" language=c++ # AUTOSARC++14:M0-1-9: There shall be no dead code. WARNING_FILTER += allow class="Explicit Zero Alignment" language=c++ # AUTOSARC++14:M5-0-3: A cvalue expression shall not be implicitly converted to a different underlying type. # AUTOSARC++14:M5-0-5: There shall be no implicit floating-integral conversions. WARNING_FILTER += allow class="Expression Value Widened by Assignment" language=c++ # AUTOSARC++14:M5-0-3: A cvalue expression shall not be implicitly converted to a different underlying type. # AUTOSARC++14:M5-0-5: There shall be no implicit floating-integral conversions. WARNING_FILTER += allow class="Expression Value Widened by Other Operand" language=c++ # AUTOSARC++14:A18-1-1: C-style arrays shall not be used. # AUTOSARC++14:A3-1-4: When an array with external linkage is declared, its size shall be stated explicitly. WARNING_FILTER += allow class="Extern Array Without Size" language=c++ # AUTOSARC++14:M3-9-3: The underlying bit representations of floating-point values shall not be used. WARNING_FILTER += allow class="Float Pointer Conversion" language=c++ # AUTOSARC++14:A6-5-2: A for loop shall contain a single loop-counter which shall not have floating-point type. WARNING_FILTER += allow class="Float-typed Loop Counter" language=c++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:M6-2-2: Floating-point expressions shall not be directly or indirectly tested for equality or inequality. WARNING_FILTER += allow class="Floating Point Equality" language=c++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:M7-3-2: The identifier main shall not be used for a function other than the global function main. WARNING_FILTER += allow class="Forbidden Function Name in Namespace" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. # 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="Format String Injection" language=c++ # AUTOSARC++14:M0-1-8: All functions with void return type shall have external side effect(s). # AUTOSARC++14:M0-1-9: There shall be no 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++ # AUTOSARC++14:A3-1-1: It shall be possible to include any header file in multiple translation units without violating the One Definition Rule. WARNING_FILTER += allow class="Function Defined in Header File" language=c++ # AUTOSARC++14:M5-2-6: A cast shall not convert a pointer to a function to any other pointer type, including a pointer to function type. # AUTOSARC++14:M8-4-4: A function identifier shall either be used to call the function or it shall be preceded by &. WARNING_FILTER += allow class="Function Pointer Conversion" language=c++ # AUTOSARC++14:A1-4-1: Code metrics and their valid boundaries shall be defined and code shall comply with defined boundaries of code metrics. WARNING_FILTER += allow class="Function Too Long" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Function-Like Macro" language=c++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:M3-2-1: All declarations of an object or function shall have compatible types. # AUTOSARC++14:M3-9-1: 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. WARNING_FILTER += allow class="Global Variable Declared with Different Types" language=c++ # AUTOSARC++14:A18-5-5: Memory management functions shall ensure the following: (a) deterministic behavior resulting with the existence of worst-case execution time, (b) avoiding memory fragmentation, (c) avoid running out of memory, (d) avoiding mismatched allocations or deallocations, (e) no dependence on non-deterministic calls to kernel. # 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="GlobalHandle on GMEM_FIXED Memory" language=c++ # AUTOSARC++14:A18-5-5: Memory management functions shall ensure the following: (a) deterministic behavior resulting with the existence of worst-case execution time, (b) avoiding memory fragmentation, (c) avoid running out of memory, (d) avoiding mismatched allocations or deallocations, (e) no dependence on non-deterministic calls to kernel. # 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="GlobalLock on GMEM_FIXED Memory" language=c++ # AUTOSARC++14:A18-5-5: Memory management functions shall ensure the following: (a) deterministic behavior resulting with the existence of worst-case execution time, (b) avoiding memory fragmentation, (c) avoid running out of memory, (d) avoiding mismatched allocations or deallocations, (e) no dependence on non-deterministic calls to kernel. # 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="GlobalUnlock on GMEM_FIXED Memory" language=c++ # AUTOSARC++14:A6-6-1: The goto statement shall not be used. WARNING_FILTER += allow class="Goto Statement" language=c++ # AUTOSARC++14:A0-1-2: The value returned by a function having a non-void return type that is not an overloaded operator shall be used. # AUTOSARC++14:M0-3-2: If a function generates 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++ # AUTOSARC++14:M8-4-4: A function identifier shall either be used to call the function or it shall be preceded by &. WARNING_FILTER += allow class="Implicit Address of Function" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # 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++ # AUTOSARC++14:M10-1-1: Classes should not be derived from virtual bases. WARNING_FILTER += allow class="Implicit Inheritance from Stateful Virtual Base" language=c++ # AUTOSARC++14:A5-1-2: Variables shall not be implicitly captured in a lambda expression. WARNING_FILTER += allow class="Implicit Lambda Capture" language=c++ # AUTOSARC++14:A5-1-2: Variables shall not be implicitly captured in a lambda expression. WARNING_FILTER += allow class="Implicit Lambda Capture of this" language=c++ # AUTOSARC++14:A13-2-1: An assignment operator shall return a reference to "this". WARNING_FILTER += allow class="Inappropriate Assignment Operator Return" language=c++ # AUTOSARC++14:M5-0-11: The plain char type shall only be used for the storage and use of character values. # AUTOSARC++14:M5-0-12: Signed char and unsigned char type shall only be used for the storage and use of numeric values. # AUTOSARC++14:M5-0-3: A cvalue expression shall not be implicitly converted to a different underlying type. # AUTOSARC++14:M5-0-5: There shall be no implicit floating-integral conversions. # AUTOSARC++14:M5-0-6: An implicit integral or floating-point conversion shall not reduce the size of the underlying type. WARNING_FILTER += allow class="Inappropriate Assignment Type" language=c++ # AUTOSARC++14:M5-0-7: There shall be no explicit floating-integral conversions of a cvalue expression. # AUTOSARC++14:M5-0-8: An explicit integral or floating-point conversion shall not increase the size of the underlying type of a cvalue expression. WARNING_FILTER += allow class="Inappropriate Cast Type: Expression" language=c++ # AUTOSARC++14:M4-5-3: Expressions with type (plain) char and wchar_t shall not be used as operands to built-in operators other than the assignment operator =, the equality operators == and ! =, and the unary & operator. # AUTOSARC++14:M5-0-11: The plain char type shall only be used for the storage and use of character values. # AUTOSARC++14:M5-0-12: Signed char and unsigned char type shall only be used for the storage and use of numeric values. WARNING_FILTER += allow class="Inappropriate Character Arithmetic" language=c++ # AUTOSARC++14:A25-4-1: Ordering predicates used with associative containers and STL sorting and related algorithms shall adhere to a strict weak ordering relation. WARNING_FILTER += allow class="Inappropriate Compare Object" language=c++ # AUTOSARC++14:A5-10-1: A pointer to member virtual function shall only be tested for equality with null-pointer-constant. WARNING_FILTER += allow class="Inappropriate Comparison of Virtual Member Function" language=c++ # AUTOSARC++14:M7-3-1: The global namespace shall only contain main, namespace declarations and extern "C" declarations. WARNING_FILTER += allow class="Inappropriate Declaration in Global Namespace" language=c++ # AUTOSARC++14:M5-0-11: The plain char type shall only be used for the storage and use of character values. # AUTOSARC++14:M5-0-12: Signed char and unsigned char type shall only be used for the storage and use of numeric values. # AUTOSARC++14:M5-0-3: A cvalue expression shall not be implicitly converted to a different underlying type. # AUTOSARC++14:M5-0-5: There shall be no implicit floating-integral conversions. # AUTOSARC++14:M5-0-6: An implicit integral or floating-point conversion shall not reduce the size of the underlying type. WARNING_FILTER += allow class="Inappropriate Numeric Assignment" language=c++ # AUTOSARC++14:A4-5-1: 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 <, <=, >, >=. # AUTOSARC++14:M4-5-1: 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. # AUTOSARC++14:M4-5-3: Expressions with type (plain) char and wchar_t shall not be used as operands to built-in operators other than the assignment operator =, the equality operators == and ! =, and the unary & operator. # AUTOSARC++14:M5-0-11: The plain char type shall only be used for the storage and use of character values. # AUTOSARC++14:M5-0-12: Signed char and unsigned char type shall only be used for the storage and use of numeric values. # AUTOSARC++14:M5-0-14: The first operand of a conditional-operator shall have type bool. # AUTOSARC++14:M5-0-20: Non-constant operands to a binary bitwise operator shall have the same underlying type. # AUTOSARC++14:M5-0-21: Bitwise operators shall only be applied to operands of unsigned underlying type. # AUTOSARC++14:M5-3-1: Each operand of the ! operator, the logical && or the logical || operators shall have type bool. # AUTOSARC++14:M5-3-2: The unary minus operator shall not be applied to an expression whose underlying type is unsigned. WARNING_FILTER += allow class="Inappropriate Operand Type" language=c++ # AUTOSARC++14:M19-3-1: The error indicator errno shall not be used. WARNING_FILTER += allow class="Inappropriate Test of Error Code" language=c++ # AUTOSARC++14:A2-11-1: Volatile keyword shall not be used. WARNING_FILTER += allow class="Inappropriate Volatile Declaration" language=c++ # AUTOSARC++14:A15-4-2: If a function is declared to be noexcept, noexcept(true) or noexcept(), then it shall not exit with an exception. # AUTOSARC++14:A15-4-4: A declaration of non-throwing function shall contain noexcept specification. # AUTOSARC++14:A18-5-9: Custom implementations of dynamic memory allocation and deallocation functions shall meet the semantic requirements specified in the corresponding "Required behaviour" clause from the C++ Standard. WARNING_FILTER += allow class="Inappropriate throw in noexcept Function" language=c++ # AUTOSARC++14:M16-2-3: Include guards shall be provided. WARNING_FILTER += allow class="Include File Without Guard" language=c++ # AUTOSARC++14:A15-4-3: 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. # 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="Incompatible Exception Specification" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # 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++ # AUTOSARC++14:A7-2-4: In an enumeration, either (1) none, (2) the first or (3) all enumerators shall be initialized. WARNING_FILTER += allow class="Inconsistent Enumerator Initialization" language=c++ # AUTOSARC++14:M3-2-1: All declarations of an object or function shall have compatible types. # AUTOSARC++14:M3-9-1: 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. # AUTOSARC++14:M8-4-2: The identifiers used for the parameters in a re-declaration of a function shall be identical to those in the declaration. WARNING_FILTER += allow class="Inconsistent Function Declarations" language=c++ # AUTOSARC++14:M3-2-1: All declarations of an object or function shall have compatible types. # AUTOSARC++14:M3-9-1: 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. WARNING_FILTER += allow class="Inconsistent Object Declarations" language=c++ # AUTOSARC++14:A5-0-1: The value of an expression shall be the same under any order of evaluation that the standard permits. WARNING_FILTER += allow class="Indeterminate Order of Evaluation" language=c++ # AUTOSARC++14:A7-4-1: The asm declaration shall not be used. # AUTOSARC++14:M7-4-3: Assembly language shall be encapsulated and isolated. WARNING_FILTER += allow class="Inline Assembly Code" language=c++ # AUTOSARC++14:A27-0-3: Alternate input and output operations on a file stream shall not be used without an intervening flush or positioning call. # 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="Input After Output Without Positioning" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:M16-0-8: If the # token appears as the first token on a line, then it shall be immediately followed by a pre-processing token. WARNING_FILTER += allow class="Invalid Preprocessor Directive" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. # 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="LDAP Injection" language=c++ # AUTOSARC++14:M6-6-1: Any label referenced by a goto statement shall be declared in the same block, or in a block enclosing the goto statement. WARNING_FILTER += allow class="Label Not In Enclosing Block" language=c++ # AUTOSARC++14:A5-1-3: Parameter list (possibly empty) shall be included in every lambda expression. WARNING_FILTER += allow class="Lambda Has No Parameter List" language=c++ # AUTOSARC++14:A5-1-6: Return type of a non-void return type lambda expression should be explicitly specified. WARNING_FILTER += allow class="Lambda Has No Return Type" language=c++ # AUTOSARC++14:A18-5-5: Memory management functions shall ensure the following: (a) deterministic behavior resulting with the existence of worst-case execution time, (b) avoiding memory fragmentation, (c) avoid running out of memory, (d) avoiding mismatched allocations or deallocations, (e) no dependence on non-deterministic calls to kernel. # 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++ # AUTOSARC++14:A17-0-1: Reserved identifiers, macros and functions in the C++ standard library shall not be defined, redefined or undefined. # AUTOSARC++14:A2-10-5: An identifier name of a function with static storage duration or a non-member object with external or internal linkage should not be reused. WARNING_FILTER += allow class="Library Function Override" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. # 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="Library Injection" language=c++ # AUTOSARC++14:A2-7-1: The character \ shall not occur as a last character of a C++ comment. WARNING_FILTER += allow class="Line Splicing in Comment" language=c++ # AUTOSARC++14:A13-1-2: User defined suffixes of the user defined literal operators shall start with underscore followed by one or more letters. # 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="Literal Suffix No Underscore" language=c++ # AUTOSARC++14:A18-5-5: Memory management functions shall ensure the following: (a) deterministic behavior resulting with the existence of worst-case execution time, (b) avoiding memory fragmentation, (c) avoid running out of memory, (d) avoiding mismatched allocations or deallocations, (e) no dependence on non-deterministic calls to kernel. # 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="LocalHandle on LMEM_FIXED Memory" language=c++ # AUTOSARC++14:A18-5-5: Memory management functions shall ensure the following: (a) deterministic behavior resulting with the existence of worst-case execution time, (b) avoiding memory fragmentation, (c) avoid running out of memory, (d) avoiding mismatched allocations or deallocations, (e) no dependence on non-deterministic calls to kernel. # 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="LocalLock on LMEM_FIXED Memory" language=c++ # AUTOSARC++14:A18-5-5: Memory management functions shall ensure the following: (a) deterministic behavior resulting with the existence of worst-case execution time, (b) avoiding memory fragmentation, (c) avoid running out of memory, (d) avoiding mismatched allocations or deallocations, (e) no dependence on non-deterministic calls to kernel. # 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="LocalUnlock on LMEM_FIXED Memory" language=c++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A2-13-5: Hexadecimal constants should be upper case. WARNING_FILTER += allow class="Lower Case in Hexadecimal Literal" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:M16-3-2: The # and ## operators should not be used. WARNING_FILTER += allow class="Macro Argument is both Mixed and Expanded" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:A17-0-1: Reserved identifiers, macros and functions in the C++ standard library shall not be defined, redefined or undefined. WARNING_FILTER += allow class="Macro Definition of Reserved Name" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Macro Does Not End With } or )" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Macro Does Not Start With { or (" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:M16-0-6: 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 ##. WARNING_FILTER += allow class="Macro Parameter Not Parenthesized" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Macro Undefined in Function Body" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:A17-0-1: Reserved identifiers, macros and functions in the C++ standard library shall not be defined, redefined or undefined. WARNING_FILTER += allow class="Macro Undefinition of Reserved Name" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:M16-3-2: The # and ## operators should not be used. WARNING_FILTER += allow class="Macro Uses # Operator" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:M16-3-2: The # and ## operators should not be used. WARNING_FILTER += allow class="Macro Uses ## Operator" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Macro Uses Unary * Operator" language=c++ # AUTOSARC++14:M6-5-3: The loop-counter shall not be modified within condition or statement. # AUTOSARC++14:M6-5-5: A loop-control-variable other than the loop-counter shall not be modified within condition or expression. WARNING_FILTER += allow class="Malformed for-loop Condition" language=c++ # AUTOSARC++14:A6-5-4: For-init-statement and expression should not perform actions other than loop-counter initialization and modification. # AUTOSARC++14:M6-5-3: The loop-counter shall not be modified within condition or statement. WARNING_FILTER += allow class="Malformed for-loop Initialization" language=c++ # AUTOSARC++14:A6-5-4: For-init-statement and expression should not perform actions other than loop-counter initialization and modification. # AUTOSARC++14:M6-5-4: The loop-counter shall be modified by one of: --, ++, - = n, or + = n; where n remains constant for the duration of the loop. # AUTOSARC++14:M6-5-5: A loop-control-variable other than the loop-counter shall not be modified within condition or expression. WARNING_FILTER += allow class="Malformed for-loop Step" language=c++ # AUTOSARC++14:M6-4-3: A switch statement shall be a well-formed switch statement. WARNING_FILTER += allow class="Malformed switch Statement" language=c++ # AUTOSARC++14:M15-3-7: Where multiple handlers are provided in a single try-catch statement or function-try-block, any ellipsis (catch-all) handler shall occur last. # 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="Masked by Default Handler" language=c++ # AUTOSARC++14:M15-3-6: Where multiple handlers are provided in a single try-catch statement or function-try-block for a derived class and some or all of its bases, the handlers shall be ordered most-derived to base class. # 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="Masked by Handler" language=c++ # AUTOSARC++14:M9-3-3: 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. WARNING_FILTER += allow class="Member Function Could Be const" language=c++ # AUTOSARC++14:M9-3-3: 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. WARNING_FILTER += allow class="Member Function Could Be static" language=c++ # AUTOSARC++14:M8-3-1: 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. WARNING_FILTER += allow class="Method Default Value Mismatch" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:M5-0-11: The plain char type shall only be used for the storage and use of character values. # AUTOSARC++14:M5-0-12: Signed char and unsigned char type shall only be used for the storage and use of numeric values. # AUTOSARC++14:M5-0-3: A cvalue expression shall not be implicitly converted to a different underlying type. # AUTOSARC++14:M5-0-5: There shall be no implicit floating-integral conversions. WARNING_FILTER += allow class="Mismatched Operand Types" language=c++ # AUTOSARC++14:A13-6-1: 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. WARNING_FILTER += allow class="Misplaced Digit Separator" language=c++ # AUTOSARC++14:A7-3-1: All overloads of a function shall be visible from where it is called. WARNING_FILTER += allow class="Misplaced Using Declaration" language=c++ # AUTOSARC++14:M6-4-4: 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++ # AUTOSARC++14:M6-4-6: The final clause of a switch statement shall be the default-clause. WARNING_FILTER += allow class="Misplaced default" language=c++ # AUTOSARC++14:M8-5-2: Braces shall be used to indicate and match the structure in the non-zero initialization of arrays and structures. WARNING_FILTER += allow class="Missing Braces in Initialization" language=c++ # AUTOSARC++14:M3-2-3: A type, object or function that is used in multiple translation units shall be declared in one and only one file. WARNING_FILTER += allow class="Missing External Declaration" language=c++ # AUTOSARC++14:M3-2-2: The One Definition Rule shall not be violated. # AUTOSARC++14:M3-2-4: An identifier with external linkage shall have exactly one definition. WARNING_FILTER += allow class="Missing External Definition" language=c++ # AUTOSARC++14:M6-4-2: All if ... else if constructs shall be terminated with an else clause. WARNING_FILTER += allow class="Missing Final else" language=c++ # AUTOSARC++14:M2-13-3: A "U" suffix shall be applied to all octal or hexadecimal integer literals of unsigned type. WARNING_FILTER += allow class="Missing Literal Suffix" language=c++ # AUTOSARC++14:A5-2-6: The operands of a logical && or || shall be parenthesized if the operands contain binary operators. # AUTOSARC++14:M5-0-2: Limited dependence should be placed on C++ operator precedence rules in expressions. WARNING_FILTER += allow class="Missing Parentheses" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A8-4-2: 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++ # AUTOSARC++14:M0-3-2: If a function generates error information, then that error information shall be tested. WARNING_FILTER += allow class="Missing Test of Error Code" language=c++ # AUTOSARC++14:A12-0-1: 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. WARNING_FILTER += allow class="Missing User-defined Operations" language=c++ # AUTOSARC++14:M6-4-5: An unconditional throw or break statement shall terminate every non-empty switch-clause. WARNING_FILTER += allow class="Missing break" language=c++ # AUTOSARC++14:M6-4-6: The final clause of a switch statement shall be the default-clause. WARNING_FILTER += allow class="Missing default" language=c++ # AUTOSARC++14:A18-5-4: If a project has sized or unsized version of operator "delete" globally defined, then both sized and unsized versions shall be defined. WARNING_FILTER += allow class="Missing delete" language=c++ # AUTOSARC++14:A15-4-4: A declaration of non-throwing function shall contain noexcept specification. # AUTOSARC++14:A18-1-6: All std::hash specializations for user-defined types shall have a noexcept function call operator. WARNING_FILTER += allow class="Missing noexcept" language=c++ # AUTOSARC++14:A15-4-4: A declaration of non-throwing function shall contain noexcept specification. # AUTOSARC++14:A18-5-9: Custom implementations of dynamic memory allocation and deallocation functions shall meet the semantic requirements specified in the corresponding "Required behaviour" clause from the C++ Standard. WARNING_FILTER += allow class="Missing throw in operator new" language=c++ # AUTOSARC++14:M7-4-3: Assembly language shall be encapsulated and isolated. WARNING_FILTER += allow class="Mixed Assembly and Code" language=c++ # AUTOSARC++14:A2-13-2: String literals with different encoding prefixes shall not be concatenated. # 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="Mixed Encodings in String Concatenation" language=c++ # AUTOSARC++14:A17-6-1: Non-standard entities shall not be added to standard namespaces. WARNING_FILTER += allow class="Modification of Standard Namespaces" language=c++ # AUTOSARC++14:A12-8-4: Move constructor shall not initialize its class members and base classes using copy semantics. WARNING_FILTER += allow class="Move Constructor With Copy Semantics" language=c++ # AUTOSARC++14:A7-1-7: Each expression statement and identifier declaration shall be placed on a separate line. WARNING_FILTER += allow class="Multiple Declarations On Line" language=c++ # AUTOSARC++14:M3-2-3: A type, object or function that is used in multiple translation units shall be declared in one and only one file. WARNING_FILTER += allow class="Multiple Declarations of a Global" language=c++ # AUTOSARC++14:M3-2-3: A type, object or function that is used in multiple translation units shall be declared in one and only one file. WARNING_FILTER += allow class="Multiple External Declarations" language=c++ # AUTOSARC++14:M3-2-2: The One Definition Rule shall not be violated. # AUTOSARC++14:M3-2-4: An identifier with external linkage shall have exactly one definition. WARNING_FILTER += allow class="Multiple External Definitions" language=c++ # AUTOSARC++14:A10-1-1: Class shall not be derived from more than one base class which is not an interface class. WARNING_FILTER += allow class="Multiple Inheritance with Too Many Protected Base Classes" language=c++ # AUTOSARC++14:A4-7-1: An integer expression shall not lead to data loss. WARNING_FILTER += allow class="Multiplication Overflow of Size" language=c++ # AUTOSARC++14:M4-10-1: NULL shall not be used as an integer value. WARNING_FILTER += allow class="NULL Used as Integer" language=c++ # AUTOSARC++14:A21-8-1: Arguments to character-handling functions shall be representable as an unsigned char. # 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++ # AUTOSARC++14:M5-8-1: 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. # 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++ # AUTOSARC++14:M2-7-1: The character sequence /* shall not be used within a C-style 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++ # AUTOSARC++14:A5-16-1: The ternary conditional operator shall not be used as a sub-expression. WARNING_FILTER += allow class="Nested Conditional Operator" language=c++ # AUTOSARC++14:M3-1-2: Functions shall not be declared at block scope. WARNING_FILTER += allow class="Nested Function Declaration" language=c++ # AUTOSARC++14:A18-5-11: "operator new" and "operator delete" shall be defined together. # 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="No Corresponding Member delete" language=c++ # AUTOSARC++14:M16-1-2: All #else, #elif and #endif pre-processor directives shall reside in the same file as the #if or #ifdef directive to which they are related. WARNING_FILTER += allow class="No Matching #endif" language=c++ # AUTOSARC++14:M16-1-2: All #else, #elif and #endif pre-processor directives shall reside in the same file as the #if or #ifdef directive to which they are related. WARNING_FILTER += allow class="No Matching #if" language=c++ # AUTOSARC++14:A27-0-2: A C-style string shall guarantee sufficient space for data and the null terminator. # 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="No Space For Null Terminator" language=c++ # AUTOSARC++14:A25-1-1: Non-static data members or captured values of predicate function objects that are state related to this object's identity shall not be copied. WARNING_FILTER += allow class="Non-const Predicate Function Object" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A2-13-4: String literals shall not be assigned to non-constant pointers. WARNING_FILTER += allow class="Non-const String Literal" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A2-10-1: 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++ # AUTOSARC++14:A2-10-6: A class or enumeration name shall not be hidden by a variable, function or enumerator declaration in the same scope. WARNING_FILTER += allow class="Non-distinct Identifiers: Same Scope" language=c++ # AUTOSARC++14:A12-4-2: If a public destructor of a class is non-virtual, then the class should be declared final. WARNING_FILTER += allow class="Non-final Class has Non-Virtual Public Destructor" language=c++ # AUTOSARC++14:A2-10-4: The identifier name of a non-member object with static storage duration or static function shall not be reused within a namespace. WARNING_FILTER += allow class="Non-unique Identifiers: Internal Name" language=c++ # AUTOSARC++14:M0-3-2: If a function generates error information, then that error information shall be tested. # AUTOSARC++14:M19-3-1: The error indicator errno shall not be used. WARNING_FILTER += allow class="Non-zero Error Code" language=c++ # AUTOSARC++14:M19-3-1: The error indicator errno shall not be used. WARNING_FILTER += allow class="Non-zero Error Code Assignment" language=c++ # AUTOSARC++14:A1-1-2: A warning level of the compilation process shall be set in compliance with project policies. WARNING_FILTER += allow class="Not All Warnings Are Enabled" language=c++ # AUTOSARC++14:A5-3-2: Null pointers shall not be dereferenced. # 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++ # AUTOSARC++14:A3-1-1: It shall be possible to include any header file in multiple translation units without violating the One Definition Rule. WARNING_FILTER += allow class="Object Defined in Header File" language=c++ # AUTOSARC++14:A12-8-6: Copy and move constructors and copy assignment and move assignment operators shall be declared protected or defined "=delete" in base class. # AUTOSARC++14:A15-3-5: A class type exception shall be caught by reference or const reference. # 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="Object Slicing" language=c++ # AUTOSARC++14:M2-13-2: Octal constants (other than zero) and octal escape sequences (other than "\0" ) shall not be used. WARNING_FILTER += allow class="Octal Constant" language=c++ # AUTOSARC++14:A8-5-1: In an initialization list, the order of initialization shall be following: (1) virtual base classes in depth and left to right order of the inheritance graph, (2) direct base classes in left to right order of inheritance list, (3) non-static data members in the order they were declared in the class definition. # 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="Out of Order Member Initializers" language=c++ # AUTOSARC++14:A27-0-3: Alternate input and output operations on a file stream shall not be used without an intervening flush or positioning call. # 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="Output After Input Without Positioning" language=c++ # AUTOSARC++14:M0-2-1: An object shall not be assigned 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++ # AUTOSARC++14:A10-2-1: Non-virtual public or protected member functions shall not be redefined in derived classes. WARNING_FILTER += allow class="Override of Non-Virtual Method" language=c++ # AUTOSARC++14:A8-4-12: A std::unique_ptr shall be passed to a function as: (1) a copy to express the function assumes ownership (2) an lvalue reference to express that the function replaces the managed object. WARNING_FILTER += allow class="Parameter is const Reference to Smart Pointer" language=c++ # AUTOSARC++14:M7-1-2: 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. WARNING_FILTER += allow class="Pointed-to Type Could Be const" language=c++ # AUTOSARC++14:A5-0-4: Pointer arithmetic shall not be used with pointers to non-final classes. # AUTOSARC++14:M5-0-15: Array indexing shall be the only form of pointer arithmetic. # AUTOSARC++14:M5-0-16: A pointer operand and any pointer resulting from pointer arithmetic using that operand shall both address elements of the same array. WARNING_FILTER += allow class="Pointer Arithmetic" language=c++ # AUTOSARC++14:M5-0-16: A pointer operand and any pointer resulting from pointer arithmetic using that operand shall both address elements of the same array. WARNING_FILTER += allow class="Pointer Before Beginning of Object" language=c++ # AUTOSARC++14:M5-2-9: A cast shall not convert a pointer type to an integral 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++ # AUTOSARC++14:M5-2-9: A cast shall not convert a pointer type to an integral type. WARNING_FILTER += allow class="Pointer Conversion to Same Size Integer" language=c++ # AUTOSARC++14:M5-0-16: A pointer operand and any pointer resulting from pointer arithmetic using that operand shall both address elements of the same array. WARNING_FILTER += allow class="Pointer Past End of Object" language=c++ # AUTOSARC++14:A18-1-1: C-style arrays shall not be used. WARNING_FILTER += allow class="Pointer to Variably-modified Array Type" language=c++ # AUTOSARC++14:A18-5-5: Memory management functions shall ensure the following: (a) deterministic behavior resulting with the existence of worst-case execution time, (b) avoiding memory fragmentation, (c) avoid running out of memory, (d) avoiding mismatched allocations or deallocations, (e) no dependence on non-deterministic calls to kernel. # 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="Pool Mismatch" language=c++ # AUTOSARC++14:M18-0-4: The time handling functions of library shall not be used. WARNING_FILTER += allow class="Potential Timebomb" language=c++ # AUTOSARC++14:A6-5-2: A for loop shall contain a single loop-counter which shall not have floating-point type. WARNING_FILTER += allow class="Potential Unbounded Loop" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:M16-0-5: Arguments to a function-like macro shall not contain tokens that look like pre-processing directives. WARNING_FILTER += allow class="Preprocessing Directives in Macro Argument" language=c++ # AUTOSARC++14:A10-3-1: Virtual function declaration shall contain exactly one of the three specifiers: (1) virtual, (2) override, (3) final. # 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="Pure final virtual" language=c++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A7-5-2: Functions shall not call themselves, either directly or indirectly. WARNING_FILTER += allow class="Recursion" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Recursive Macro" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A7-1-4: The register keyword shall not be used. WARNING_FILTER += allow class="Register Keyword" language=c++ # AUTOSARC++14:M7-5-1: A function shall not return a reference or a pointer to an automatic variable (including parameters), defined within the function. # 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++ # AUTOSARC++14:A7-6-1: Functions declared with the [[noreturn]] attribute shall not return. # 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="Return from noreturn" language=c++ # AUTOSARC++14:M5-0-10: 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. WARNING_FILTER += allow class="Risky Integer Promotion" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. # 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="SQL Injection" language=c++ # AUTOSARC++14:M3-4-1: An identifier declared to be an object or type shall be defined in a block that minimizes its visibility. WARNING_FILTER += allow class="Scope Could Be Local Static" language=c++ # AUTOSARC++14:M5-8-1: 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. # 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++ # AUTOSARC++14:M5-2-10: The increment (++) and decrement (--) operators shall not be mixed with other operators in an expression. WARNING_FILTER += allow class="Side Effects in Expression with Decrement" language=c++ # AUTOSARC++14:M5-2-10: The increment (++) and decrement (--) operators shall not be mixed with other operators in an expression. WARNING_FILTER += allow class="Side Effects in Expression with Increment" language=c++ # AUTOSARC++14:M5-14-1: The right hand operand of a logical &&, || operators shall not contain side effects. WARNING_FILTER += allow class="Side Effects in Logical Operand" language=c++ # AUTOSARC++14:M5-3-4: Evaluation of the operand to the sizeof operator shall not contain side effects. WARNING_FILTER += allow class="Side Effects in sizeof" language=c++ # AUTOSARC++14:M9-6-4: Named bit-fields with signed integer type shall have a length of more than one bit. # 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++ # AUTOSARC++14:A18-1-1: C-style arrays shall not be used. WARNING_FILTER += allow class="Static Array Parameter" language=c++ # AUTOSARC++14:A7-1-8: A non-type specifier shall be placed before a type specifier in a declaration. WARNING_FILTER += allow class="Storage Class Not First" language=c++ # AUTOSARC++14:A4-7-1: An integer expression shall not lead to data loss. WARNING_FILTER += allow class="Subtraction Underflow of Size" language=c++ # AUTOSARC++14:M5-0-15: Array indexing shall be the only form of pointer arithmetic. # AUTOSARC++14:M5-0-17: 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++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. WARNING_FILTER += allow class="Tainted Allocation Size" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. # AUTOSARC++14:M5-0-16: A pointer operand and any pointer resulting from pointer arithmetic using that operand shall both 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++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. WARNING_FILTER += allow class="Tainted Configuration Setting" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. # 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="Tainted Environment Variable" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. WARNING_FILTER += allow class="Tainted Filename" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. WARNING_FILTER += allow class="Tainted Network Address" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. WARNING_FILTER += allow class="Tainted Write" language=c++ # AUTOSARC++14:A6-4-1: A switch statement shall have at least two case-clauses, distinct from the default label. WARNING_FILTER += allow class="Too Few Cases in switch" language=c++ # AUTOSARC++14:A5-0-3: The declaration of objects shall contain no more than two levels of pointer indirection. WARNING_FILTER += allow class="Too Much Indirection in Declaration" language=c++ # AUTOSARC++14:A2-5-1: Trigraphs shall not be used. WARNING_FILTER += allow class="Trigraph" language=c++ # AUTOSARC++14:A4-7-1: An integer expression shall not lead to data loss. WARNING_FILTER += allow class="Truncation of Size" language=c++ # AUTOSARC++14:A18-5-3: The form of the delete expression shall match the form of the new expression used to allocate the memory. # AUTOSARC++14:A18-5-5: Memory management functions shall ensure the following: (a) deterministic behavior resulting with the existence of worst-case execution time, (b) avoiding memory fragmentation, (c) avoid running out of memory, (d) avoiding mismatched allocations or deallocations, (e) no dependence on non-deterministic calls to kernel. # 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++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M5-0-16: A pointer operand and any pointer resulting from pointer arithmetic using that operand shall both 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="Type Overrun" language=c++ # AUTOSARC++14:M5-0-16: A pointer operand and any pointer resulting from pointer arithmetic using that operand shall both 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="Type Underrun" language=c++ # AUTOSARC++14:M2-10-1: Different identifiers shall be typographically unambiguous. WARNING_FILTER += allow class="Typographically Ambiguous Identifiers" language=c++ # AUTOSARC++14:M16-0-7: Undefined macro identifiers shall not be used in #if or #elif pre-processor directives, except as operands to the defined operator. # 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++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A12-8-3: Moved-from object shall not be read-accessed. # AUTOSARC++14:A8-5-0: All memory shall be initialized before it is read. # 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++ # AUTOSARC++14:A9-5-1: Unions shall not be used. WARNING_FILTER += allow class="Union Type" language=c++ # AUTOSARC++14:A2-13-1: Only those escape sequences that are defined in ISO/IEC 14882:2014 shall be used. # 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="Universal Character Name Names Invalid Code Point" language=c++ # AUTOSARC++14:A10-3-1: Virtual function declaration shall contain exactly one of the three specifiers: (1) virtual, (2) override, (3) final. WARNING_FILTER += allow class="Unnecessary override Specifier" language=c++ # AUTOSARC++14:A10-3-1: Virtual function declaration shall contain exactly one of the three specifiers: (1) virtual, (2) override, (3) final. WARNING_FILTER += allow class="Unnecessary virtual Specifier" language=c++ # AUTOSARC++14:A3-3-2: Static and thread-local objects shall be constant-initialized. WARNING_FILTER += allow class="Unordered Initialization" language=c++ # AUTOSARC++14:M0-1-1: A project shall not contain unreachable code. # AUTOSARC++14:M0-1-2: A project shall not contain infeasible paths. # 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++ # AUTOSARC++14:M0-1-1: A project shall not contain unreachable code. # AUTOSARC++14:M0-1-2: A project shall not contain infeasible paths. # 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++ # AUTOSARC++14:M0-1-1: A project shall not contain unreachable code. # AUTOSARC++14:M0-1-2: A project shall not contain infeasible paths. # 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++ # AUTOSARC++14:M0-1-1: A project shall not contain unreachable code. # AUTOSARC++14:M0-1-2: A project shall not contain infeasible paths. WARNING_FILTER += allow class="Unreachable Control Flow" language=c++ # AUTOSARC++14:M0-1-1: A project shall not contain unreachable code. # AUTOSARC++14:M0-1-2: A project shall not contain infeasible paths. # 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++ # AUTOSARC++14:A2-13-1: Only those escape sequences that are defined in ISO/IEC 14882:2014 shall be used. # 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="Unrecognized Character Escape" language=c++ # AUTOSARC++14:A7-2-3: Enumerations shall be declared as scoped enum classes. WARNING_FILTER += allow class="Unscoped Enumeration" language=c++ # AUTOSARC++14:A27-0-2: A C-style string shall guarantee sufficient space for data and the null terminator. # 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++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. WARNING_FILTER += allow class="Untrusted Library Load" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. WARNING_FILTER += allow class="Untrusted Network Host" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. WARNING_FILTER += allow class="Untrusted Network Port" language=c++ # AUTOSARC++14:A27-0-1: Inputs from independent components shall be validated. WARNING_FILTER += allow class="Untrusted Process Creation" language=c++ # AUTOSARC++14:A0-1-4: There shall be no unused named parameters in non-virtual functions. # AUTOSARC++14:A0-1-5: There shall be no unused named parameters in the set of parameters for a virtual function and all the functions that override it. # AUTOSARC++14:M0-1-2: A project shall not contain infeasible paths. WARNING_FILTER += allow class="Unused Parameter" language=c++ # AUTOSARC++14:A0-1-6: There should be no unused type declarations. WARNING_FILTER += allow class="Unused Type" language=c++ # AUTOSARC++14:A0-1-1: A project shall not contain instances of non-volatile variables being given values that are not subsequently used. # AUTOSARC++14:M0-1-9: There shall be no 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++ # AUTOSARC++14:M0-1-3: A project shall not contain unused variables. WARNING_FILTER += allow class="Unused Variable" language=c++ # AUTOSARC++14:A3-8-1: An object shall not be accessed outside of its lifetime. # 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++ # AUTOSARC++14:A12-8-5: A copy assignment and a move assignment operators shall handle self-assignment. # AUTOSARC++14:A23-0-2: Elements of a container shall only be accessed via valid references, iterators, and pointers. # AUTOSARC++14:A3-8-1: An object shall not be accessed outside of its lifetime. # 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 Free" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #elif" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #elifdef" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #elifndef" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #else" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:A16-6-1: #error directive shall not be used. WARNING_FILTER += allow class="Use of #error" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #if" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #ifdef" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #import" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #include_next" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #line" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. # AUTOSARC++14:A16-7-1: The #pragma directive shall not be used. WARNING_FILTER += allow class="Use of #pragma" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #undef" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #using" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Use of #warning" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. WARNING_FILTER += allow class="Use of Exception Handling Function" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A18-0-1: The C library facilities shall only be accessed through C++ library headers. WARNING_FILTER += allow class="Use of " language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A18-0-1: The C library facilities shall only be accessed through C++ library headers. WARNING_FILTER += allow class="Use of " language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. WARNING_FILTER += allow class="Use of Feature" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:M27-0-1: The stream input/output library shall not be used. WARNING_FILTER += allow class="Use of Input/Output" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:M27-0-1: The stream input/output library shall not be used. WARNING_FILTER += allow class="Use of Input/Output Macro" language=c++ # AUTOSARC++14:A18-5-1: Functions malloc, calloc, realloc and free shall not be used. WARNING_FILTER += allow class="Use of Allocator/Deallocator" language=c++ # AUTOSARC++14:A18-5-1: Functions malloc, calloc, realloc and free shall not be used. WARNING_FILTER += allow class="Use of Allocator/Deallocator Macro" language=c++ # AUTOSARC++14:A18-0-1: The C library facilities shall only be accessed through C++ library headers. WARNING_FILTER += allow class="Use of " language=c++ # AUTOSARC++14:M18-0-4: The time handling functions of library shall not be used. WARNING_FILTER += allow class="Use of Time/Date Function" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:M27-0-1: The stream input/output library shall not be used. WARNING_FILTER += allow class="Use of Input/Output" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:M27-0-1: The stream input/output library shall not be used. WARNING_FILTER += allow class="Use of Input/Output Macro" language=c++ # AUTOSARC++14:M5-18-1: The comma operator shall not be used. WARNING_FILTER += allow class="Use of Comma Operator" language=c++ # AUTOSARC++14:A4-10-1: Only nullptr literal shall be used as the null-pointer-constant. # AUTOSARC++14:M15-1-2: NULL shall not be thrown explicitly. # AUTOSARC++14:M4-10-1: NULL shall not be used as an integer value. WARNING_FILTER += allow class="Use of NULL" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. WARNING_FILTER += allow class="Use of OemToAnsi" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. WARNING_FILTER += allow class="Use of OemToChar" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. WARNING_FILTER += allow class="Use of StrCatChainW" language=c++ # AUTOSARC++14:A15-5-2: Program shall not be abruptly terminated. In particular, an implicit or explicit invocation of std::abort(), std::quick_exit(), std::_Exit(), std::terminate() shall not be done. # AUTOSARC++14:M18-0-3: The library functions abort, exit, getenv and system from library shall not be used. WARNING_FILTER += allow class="Use of abort" language=c++ # AUTOSARC++14:A18-0-2: The error state of a conversion from string to a numeric value shall be checked. WARNING_FILTER += allow class="Use of atof" language=c++ # AUTOSARC++14:A18-0-2: The error state of a conversion from string to a numeric value shall be checked. WARNING_FILTER += allow class="Use of atoi" language=c++ # AUTOSARC++14:A18-0-2: The error state of a conversion from string to a numeric value shall be checked. WARNING_FILTER += allow class="Use of atol" language=c++ # AUTOSARC++14:A18-0-2: The error state of a conversion from string to a numeric value shall be checked. WARNING_FILTER += allow class="Use of atoll" language=c++ # AUTOSARC++14:A18-5-2: Non-placement new or delete expressions shall not be used. WARNING_FILTER += allow class="Use of delete" language=c++ # AUTOSARC++14:A15-5-2: Program shall not be abruptly terminated. In particular, an implicit or explicit invocation of std::abort(), std::quick_exit(), std::_Exit(), std::terminate() shall not be done. # AUTOSARC++14:M18-0-3: The library functions abort, exit, getenv and system from library shall not be used. WARNING_FILTER += allow class="Use of exit" language=c++ # AUTOSARC++14:M18-0-3: The library functions abort, exit, getenv and system from library shall not be used. WARNING_FILTER += allow class="Use of getenv" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. WARNING_FILTER += allow class="Use of getopt" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. WARNING_FILTER += allow class="Use of getpass" language=c++ # AUTOSARC++14:A1-1-1: All code shall conform to ISO/IEC 14882:2014 - Programming Language C++ and shall not use deprecated features. # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # 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 of gets" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. WARNING_FILTER += allow class="Use of getwd" language=c++ # AUTOSARC++14:M17-0-5: The setjmp macro and the longjmp function shall not be used. WARNING_FILTER += allow class="Use of longjmp" language=c++ # AUTOSARC++14:A18-5-2: Non-placement new or delete expressions shall not be used. WARNING_FILTER += allow class="Use of new" language=c++ # AUTOSARC++14:M18-2-1: The macro offsetof shall not be used. WARNING_FILTER += allow class="Use of offsetof" language=c++ # AUTOSARC++14:M7-5-2: 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. WARNING_FILTER += allow class="Use of putenv" language=c++ # AUTOSARC++14:A26-5-1: Pseudorandom numbers shall not be generated using std::rand(). WARNING_FILTER += allow class="Use of rand" language=c++ # AUTOSARC++14:A18-5-1: Functions malloc, calloc, realloc and free shall not be used. WARNING_FILTER += allow class="Use of realloc" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. WARNING_FILTER += allow class="Use of recvmsg" language=c++ # AUTOSARC++14:M17-0-5: The setjmp macro and the longjmp function shall not be used. WARNING_FILTER += allow class="Use of setjmp" language=c++ # AUTOSARC++14:A18-0-3: The library (locale.h) and the setlocale function shall not be used. WARNING_FILTER += allow class="Use of setlocale" language=c++ # AUTOSARC++14:M18-7-1: The signal handling facilities of shall not be used. WARNING_FILTER += allow class="Use of signal" language=c++ # AUTOSARC++14:A18-9-1: The std::bind shall not be used. WARNING_FILTER += allow class="Use of std::bind" language=c++ # AUTOSARC++14:A18-1-2: The std::vector specialization shall not be used. WARNING_FILTER += allow class="Use of std::vector" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strcat" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strchr" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strcmp" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strcoll" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strcpy" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strcspn" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strlen" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strpbrk" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strrchr" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strspn" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strstr" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. # AUTOSARC++14:M18-0-5: The unbounded functions of library shall not be used. WARNING_FILTER += allow class="Use of strtok" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. WARNING_FILTER += allow class="Use of strtrns" language=c++ # AUTOSARC++14:A5-2-5: An array or container shall not be accessed beyond its range. WARNING_FILTER += allow class="Use of syslog" language=c++ # AUTOSARC++14:M18-0-3: The library functions abort, exit, getenv and system from library shall not be used. WARNING_FILTER += allow class="Use of system" language=c++ # AUTOSARC++14:M0-1-9: There shall be no 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++ # AUTOSARC++14:A13-1-2: User defined suffixes of the user defined literal operators shall start with underscore followed by one or more letters. # AUTOSARC++14:A13-1-3: User defined literals operators shall only perform conversion of passed parameters. WARNING_FILTER += allow class="User-defined Literal Operator" language=c++ # AUTOSARC++14:M7-3-6: Using-directives and using-declarations (excluding class scope or function scope using-declarations) shall not be used in header files. WARNING_FILTER += allow class="Using Declaration in Header File" language=c++ # AUTOSARC++14:M7-3-4: Using-directives shall not be used. WARNING_FILTER += allow class="Using Directive" language=c++ # AUTOSARC++14:M7-3-4: Using-directives shall not be used. # AUTOSARC++14:M7-3-6: Using-directives and using-declarations (excluding class scope or function scope using-declarations) shall not be used in header files. WARNING_FILTER += allow class="Using Directive in Header File" language=c++ # AUTOSARC++14:M8-4-4: A function identifier shall either be used to call the function or it shall be preceded by &. # 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="Varargs Function Cast" language=c++ # AUTOSARC++14:A7-1-1: Constexpr or const specifiers shall be used for immutable data declaration. WARNING_FILTER += allow class="Variable Could Be const" language=c++ # AUTOSARC++14:A16-0-1: The pre-processor shall only be used for unconditional and conditional file inclusion and include guards, and using the following directives: (1) #ifndef, (2) #ifdef, (3) #if, (4) #if defined, (5) #elif, (6) #else, (7) #define, (8) #endif, (9) #include. WARNING_FILTER += allow class="Variadic Macro" language=c++ # AUTOSARC++14:M10-1-1: Classes should not be derived from virtual bases. WARNING_FILTER += allow class="Virtual Base Class" language=c++ # AUTOSARC++14:M10-1-1: Classes should not be derived from virtual bases. # AUTOSARC++14:M10-1-2: A base class shall only be declared virtual if it is used in a diamond hierarchy. WARNING_FILTER += allow class="Virtual Base Class not In Diamond" language=c++ # AUTOSARC++14:M12-1-1: An object's dynamic type shall not be used from the body of its constructor or destructor. # 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="Virtual Call in Constructor" language=c++ # AUTOSARC++14:M12-1-1: An object's dynamic type shall not be used from the body of its constructor or destructor. # 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="Virtual Call in Destructor" language=c++ # AUTOSARC++14:A10-3-1: Virtual function declaration shall contain exactly one of the three specifiers: (1) virtual, (2) override, (3) final. WARNING_FILTER += allow class="Virtual Function Missing virtual/override/final" language=c++ # AUTOSARC++14:M10-1-1: Classes should not be derived from virtual bases. # AUTOSARC++14:M10-1-3: An accessible base class shall not be both virtual and non-virtual in the same hierarchy. WARNING_FILTER += allow class="Virtual and Non-Virtual Base Class" language=c++ # AUTOSARC++14:A1-1-2: A warning level of the compilation process shall be set in compliance with project policies. WARNING_FILTER += allow class="Warnings Not Treated As Errors" language=c++ # AUTOSARC++14:M9-6-4: Named bit-fields with signed integer type shall have a length of more than one bit. # 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="Zero Length Bit Field Must Be Unnamed" language=c++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A5-3-3: Pointers to incomplete class types shall not be deleted. # 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="delete of Incomplete Class" language=c++ # AUTOSARC++14:A12-4-1: Destructor of a base class shall be public virtual, public override or protected non-virtual. WARNING_FILTER += allow class="delete with Non-Virtual Destructor" language=c++ # AUTOSARC++14:A7-2-2: Enumeration underlying base type shall be explicitly defined. # AUTOSARC++14:A7-2-3: Enumerations shall be declared as scoped enum classes. # 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="enum Value Out of Integer Range" language=c++ # AUTOSARC++14:A10-3-3: Virtual functions shall not be introduced in a final class. WARNING_FILTER += allow class="override in final Class" language=c++ # AUTOSARC++14:A0-4-4: Range, domain and pole errors shall be checked when using math functions. # 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++ # AUTOSARC++14:A18-9-3: The std::move shall not be used on objects declared const or const&. WARNING_FILTER += allow class="std::move Argument is const" language=c++ # AUTOSARC++14:A7-2-5: Enumerations should be used to represent sets of related named constants. WARNING_FILTER += allow class="switch With Non-enum Expression" language=c++ # AUTOSARC++14:A5-3-1: Evaluation of the operand to the typeid operator shall not contain side effects. WARNING_FILTER += allow class="typeid of Polymorphic Class Type" language=c++ # AUTOSARC++14:A10-3-3: Virtual functions shall not be introduced in a final class. WARNING_FILTER += allow class="virtual in final Class" language=c++ # # The remainder of this file was generated from template 'codesonar/presets/autosarc++14.conf.in' # WARNING_FILTER += discard class="Basic Numerical Type Used" line_contents=~\<(main|argc|argv)\> WARNING_FILTER += discard class="C String" line_contents=~\<(argv|envp)\> procedure=~\<(main|wmain)\>