Skip to content

Commit 3a36e92

Browse files
authored
checkers.cpp: Update file using tools/get_checkers.py (danmar#7684)
1 parent e17d94c commit 3a36e92

File tree

2 files changed

+161
-167
lines changed

2 files changed

+161
-167
lines changed

lib/checkers.cpp

Lines changed: 142 additions & 143 deletions
Original file line numberDiff line numberDiff line change
@@ -25,189 +25,189 @@ namespace checkers {
2525
const std::map<std::string, std::string> allCheckers{
2626
{"Check64BitPortability::pointerassignment","portability"},
2727
{"CheckAssert::assertWithSideEffects","warning"},
28-
{"CheckBool::checkIncrementBoolean","style"},
28+
{"CheckAutoVariables::assignFunctionArg","style,warning"},
29+
{"CheckAutoVariables::autoVariables",""},
30+
{"CheckAutoVariables::checkVarLifetime",""},
31+
{"CheckBool::checkAssignBoolToFloat","style,c++"},
32+
{"CheckBool::checkAssignBoolToPointer",""},
2933
{"CheckBool::checkBitwiseOnBoolean","style,inconclusive"},
34+
{"CheckBool::checkComparisonOfBoolExpressionWithInt","warning"},
35+
{"CheckBool::checkComparisonOfBoolWithBool","style,c++"},
3036
{"CheckBool::checkComparisonOfBoolWithInt","warning,c++"},
3137
{"CheckBool::checkComparisonOfFuncReturningBool","style,c++"},
32-
{"CheckBool::checkComparisonOfBoolWithBool","style,c++"},
33-
{"CheckBool::checkAssignBoolToPointer",""},
34-
{"CheckBool::checkComparisonOfBoolExpressionWithInt","warning"},
38+
{"CheckBool::checkIncrementBoolean","style"},
3539
{"CheckBool::pointerArithBool",""},
36-
{"CheckBool::checkAssignBoolToFloat","style,c++"},
3740
{"CheckBool::returnValueOfFunctionReturningBool","style"},
38-
{"CheckExceptionSafety::destructors","warning"},
39-
{"CheckExceptionSafety::deallocThrow","warning"},
40-
{"CheckExceptionSafety::checkRethrowCopy","style"},
41+
{"CheckBufferOverrun::analyseWholeProgram",""},
42+
{"CheckBufferOverrun::argumentSize","warning"},
43+
{"CheckBufferOverrun::arrayIndex",""},
44+
{"CheckBufferOverrun::arrayIndexThenCheck",""},
45+
{"CheckBufferOverrun::bufferOverflow",""},
46+
{"CheckBufferOverrun::negativeArraySize",""},
47+
{"CheckBufferOverrun::objectIndex",""},
48+
{"CheckBufferOverrun::pointerArithmetic","portability"},
49+
{"CheckBufferOverrun::stringNotZeroTerminated","warning,inconclusive"},
50+
{"CheckClass::analyseWholeProgram",""},
51+
{"CheckClass::checkConst","style,inconclusive"},
52+
{"CheckClass::checkConstructors","style,warning"},
53+
{"CheckClass::checkCopyConstructors","warning"},
54+
{"CheckClass::checkDuplInheritedMembers","warning"},
55+
{"CheckClass::checkExplicitConstructors","style"},
56+
{"CheckClass::checkMemset",""},
57+
{"CheckClass::checkMissingOverride","style,c++03"},
58+
{"CheckClass::checkReturnByReference","performance"},
59+
{"CheckClass::checkSelfInitialization",""},
60+
{"CheckClass::checkThisUseAfterFree","warning"},
61+
{"CheckClass::checkUnsafeClassRefMember","warning,safeChecks"},
62+
{"CheckClass::checkUselessOverride","style"},
63+
{"CheckClass::checkVirtualFunctionCallInConstructor","warning"},
64+
{"CheckClass::initializationListUsage","performance"},
65+
{"CheckClass::initializerListOrder","style,inconclusive"},
66+
{"CheckClass::operatorEqRetRefThis","style"},
67+
{"CheckClass::operatorEqToSelf","warning"},
68+
{"CheckClass::privateFunctions","style"},
69+
{"CheckClass::thisSubtraction","warning"},
70+
{"CheckClass::virtualDestructor",""},
71+
{"CheckCondition::alwaysTrueFalse","style"},
72+
{"CheckCondition::assignIf","style"},
73+
{"CheckCondition::checkAssignmentInCondition","style"},
74+
{"CheckCondition::checkBadBitmaskCheck","style"},
75+
{"CheckCondition::checkCompareValueOutOfTypeRange","style,platform"},
76+
{"CheckCondition::checkDuplicateConditionalAssign","style"},
77+
{"CheckCondition::checkIncorrectLogicOperator","style,warning"},
78+
{"CheckCondition::checkInvalidTestForOverflow","warning"},
79+
{"CheckCondition::checkModuloAlwaysTrueFalse","warning"},
80+
{"CheckCondition::checkPointerAdditionResultNotNull","warning"},
81+
{"CheckCondition::clarifyCondition","style"},
82+
{"CheckCondition::comparison","style"},
83+
{"CheckCondition::duplicateCondition","style"},
84+
{"CheckCondition::multiCondition","style"},
85+
{"CheckCondition::multiCondition2","warning"},
4186
{"CheckExceptionSafety::checkCatchExceptionByValue","style"},
87+
{"CheckExceptionSafety::checkRethrowCopy","style"},
88+
{"CheckExceptionSafety::deallocThrow","warning"},
89+
{"CheckExceptionSafety::destructors","warning"},
4290
{"CheckExceptionSafety::nothrowThrows",""},
43-
{"CheckExceptionSafety::unhandledExceptionSpecification","style,inconclusive"},
4491
{"CheckExceptionSafety::rethrowNoCurrentException",""},
45-
{"CheckFunctions::checkProhibitedFunctions",""},
46-
{"CheckFunctions::invalidFunctionUsage",""},
92+
{"CheckExceptionSafety::unhandledExceptionSpecification","style,inconclusive"},
4793
{"CheckFunctions::checkIgnoredReturnValue","style,warning"},
48-
{"CheckFunctions::checkMissingReturn",""},
4994
{"CheckFunctions::checkMathFunctions","style,warning,c99,c++11"},
50-
{"CheckFunctions::memsetZeroBytes","warning"},
95+
{"CheckFunctions::checkMissingReturn",""},
96+
{"CheckFunctions::checkProhibitedFunctions",""},
97+
{"CheckFunctions::invalidFunctionUsage",""},
5198
{"CheckFunctions::memsetInvalid2ndParam","warning,portability"},
99+
{"CheckFunctions::memsetZeroBytes","warning"},
52100
{"CheckFunctions::returnLocalStdMove","performance,c++11"},
53101
{"CheckFunctions::useStandardLibrary","style"},
54102
{"CheckIO::checkCoutCerrMisusage","c"},
55103
{"CheckIO::checkFileUsage",""},
56-
{"CheckIO::invalidScanf",""},
57104
{"CheckIO::checkWrongPrintfScanfArguments",""},
58-
{"CheckMemoryLeakInFunction::checkReallocUsage",""},
105+
{"CheckIO::invalidScanf",""},
106+
{"CheckLeakAutoVar::check","notclang"},
59107
{"CheckMemoryLeakInClass::check",""},
60-
{"CheckMemoryLeakStructMember::check",""},
108+
{"CheckMemoryLeakInFunction::checkReallocUsage",""},
61109
{"CheckMemoryLeakNoVar::check",""},
62110
{"CheckMemoryLeakNoVar::checkForUnsafeArgAlloc",""},
63-
{"CheckPostfixOperator::postfixOperator","performance"},
64-
{"CheckSizeof::checkSizeofForNumericParameter","warning"},
65-
{"CheckSizeof::checkSizeofForArrayParameter","warning"},
66-
{"CheckSizeof::checkSizeofForPointerSize","warning"},
67-
{"CheckSizeof::sizeofsizeof","warning"},
68-
{"CheckSizeof::sizeofCalculation","warning"},
69-
{"CheckSizeof::sizeofFunction","warning"},
70-
{"CheckSizeof::suspiciousSizeofCalculation","warning,inconclusive"},
71-
{"CheckSizeof::sizeofVoid","portability"},
72-
{"CheckString::stringLiteralWrite",""},
73-
{"CheckString::checkAlwaysTrueOrFalseStringCompare","warning"},
74-
{"CheckString::checkSuspiciousStringCompare","warning"},
75-
{"CheckString::strPlusChar",""},
76-
{"CheckString::checkIncorrectStringCompare","warning"},
77-
{"CheckString::overlappingStrcmp","warning"},
78-
{"CheckString::sprintfOverlappingData",""},
79-
{"CheckVaarg::va_start_argument",""},
80-
{"CheckVaarg::va_list_usage","notclang"},
81-
{"CheckUnusedFunctions::check","unusedFunction"},
82-
{"CheckAutoVariables::assignFunctionArg","style,warning"},
83-
{"CheckAutoVariables::autoVariables",""},
84-
{"CheckAutoVariables::checkVarLifetime",""},
85-
{"CheckBufferOverrun::arrayIndex",""},
86-
{"CheckBufferOverrun::pointerArithmetic","portability"},
87-
{"CheckBufferOverrun::bufferOverflow",""},
88-
{"CheckBufferOverrun::arrayIndexThenCheck",""},
89-
{"CheckBufferOverrun::stringNotZeroTerminated","warning,inconclusive"},
90-
{"CheckBufferOverrun::argumentSize","warning"},
91-
{"CheckBufferOverrun::analyseWholeProgram",""},
92-
{"CheckBufferOverrun::objectIndex",""},
93-
{"CheckBufferOverrun::negativeArraySize",""},
94-
{"CheckCondition::assignIf","style"},
95-
{"CheckCondition::checkBadBitmaskCheck","style"},
96-
{"CheckCondition::comparison","style"},
97-
{"CheckCondition::duplicateCondition","style"},
98-
{"CheckCondition::multiCondition","style"},
99-
{"CheckCondition::multiCondition2","warning"},
100-
{"CheckCondition::checkIncorrectLogicOperator","style,warning"},
101-
{"CheckCondition::checkModuloAlwaysTrueFalse","warning"},
102-
{"CheckCondition::clarifyCondition","style"},
103-
{"CheckCondition::alwaysTrueFalse","style"},
104-
{"CheckCondition::checkInvalidTestForOverflow","warning"},
105-
{"CheckCondition::checkPointerAdditionResultNotNull","warning"},
106-
{"CheckCondition::checkDuplicateConditionalAssign","style"},
107-
{"CheckCondition::checkAssignmentInCondition","style"},
108-
{"CheckCondition::checkCompareValueOutOfTypeRange","style,platform"},
109-
{"CheckLeakAutoVar::check","notclang"},
110-
{"CheckNullPointer::nullPointer",""},
111-
{"CheckNullPointer::nullConstantDereference",""},
112-
{"CheckNullPointer::arithmetic",""},
111+
{"CheckMemoryLeakStructMember::check",""},
113112
{"CheckNullPointer::analyseWholeProgram","unusedfunctions"},
113+
{"CheckNullPointer::arithmetic",""},
114+
{"CheckNullPointer::nullConstantDereference",""},
115+
{"CheckNullPointer::nullPointer",""},
116+
{"CheckOther::checkAccessOfMovedVariable","c++11,warning"},
114117
{"CheckOther::checkCastIntToCharAndBack","warning"},
115-
{"CheckOther::clarifyCalculation","style"},
116-
{"CheckOther::clarifyStatement","warning"},
117-
{"CheckOther::checkSuspiciousSemicolon","warning,inconclusive"},
118-
{"CheckOther::warningOldStylePointerCast","style,c++"},
119-
{"CheckOther::warningDangerousTypeCast","warning,c++"},
120-
{"CheckOther::warningIntToPointerCast","portability"},
121-
{"CheckOther::suspiciousFloatingPointCast","style"},
122-
{"CheckOther::invalidPointerCast","portability"},
123-
{"CheckOther::checkRedundantAssignment","style"},
124-
{"CheckOther::redundantBitwiseOperationInSwitch","warning"},
125-
{"CheckOther::checkSuspiciousCaseInSwitch","warning,inconclusive"},
126-
{"CheckOther::checkUnreachableCode","style"},
127-
{"CheckOther::checkVariableScope","style,notclang"},
128-
{"CheckOther::checkPassByReference","performance,c++"},
129-
{"CheckOther::checkConstVariable","style,c++"},
130-
{"CheckOther::checkConstPointer","style"},
131118
{"CheckOther::checkCharVariable","warning,portability"},
132-
{"CheckOther::checkIncompleteStatement","warning"},
133-
{"CheckOther::checkZeroDivision",""},
134-
{"CheckOther::checkNanInArithmeticExpression","style"},
135-
{"CheckOther::checkMisusedScopedObject","style,c++"},
119+
{"CheckOther::checkComparePointers",""},
120+
{"CheckOther::checkComparisonFunctionIsAlwaysTrueOrFalse","warning"},
121+
{"CheckOther::checkConstPointer","style"},
122+
{"CheckOther::checkConstVariable","style,c++"},
136123
{"CheckOther::checkDuplicateBranch","style,inconclusive"},
137-
{"CheckOther::checkInvalidFree",""},
138124
{"CheckOther::checkDuplicateExpression","style,warning"},
139-
{"CheckOther::checkComparisonFunctionIsAlwaysTrueOrFalse","warning"},
140-
{"CheckOther::checkSignOfUnsignedVariable","style"},
141-
{"CheckOther::checkRedundantCopy","c++,performance,inconclusive"},
142-
{"CheckOther::checkNegativeBitwiseShift",""},
143-
{"CheckOther::checkIncompleteArrayFill","warning,portability,inconclusive"},
144-
{"CheckOther::checkVarFuncNullUB","portability"},
145-
{"CheckOther::checkRedundantPointerOp","style"},
146-
{"CheckOther::checkInterlockedDecrement","windows-platform"},
147-
{"CheckOther::checkUnusedLabel","style,warning"},
148125
{"CheckOther::checkEvaluationOrder",""},
149-
{"CheckOther::checkAccessOfMovedVariable","c++11,warning"},
150126
{"CheckOther::checkFuncArgNamesDifferent","style,warning,inconclusive"},
151-
{"CheckOther::checkShadowVariables","style"},
127+
{"CheckOther::checkIncompleteArrayFill","warning,portability,inconclusive"},
128+
{"CheckOther::checkIncompleteStatement","warning"},
129+
{"CheckOther::checkInterlockedDecrement","windows-platform"},
130+
{"CheckOther::checkInvalidFree",""},
152131
{"CheckOther::checkKnownArgument","style"},
153132
{"CheckOther::checkKnownPointerToBool","style"},
154-
{"CheckOther::checkComparePointers",""},
133+
{"CheckOther::checkMisusedScopedObject","style,c++"},
155134
{"CheckOther::checkModuloOfOne","style"},
135+
{"CheckOther::checkNanInArithmeticExpression","style"},
136+
{"CheckOther::checkNegativeBitwiseShift",""},
156137
{"CheckOther::checkOverlappingWrite",""},
157-
{"CheckStl::outOfBounds",""},
158-
{"CheckStl::outOfBoundsIndexExpression",""},
138+
{"CheckOther::checkPassByReference","performance,c++"},
139+
{"CheckOther::checkRedundantAssignment","style"},
140+
{"CheckOther::checkRedundantCopy","c++,performance,inconclusive"},
141+
{"CheckOther::checkRedundantPointerOp","style"},
142+
{"CheckOther::checkShadowVariables","style"},
143+
{"CheckOther::checkSignOfUnsignedVariable","style"},
144+
{"CheckOther::checkSuspiciousCaseInSwitch","warning,inconclusive"},
145+
{"CheckOther::checkSuspiciousSemicolon","warning,inconclusive"},
146+
{"CheckOther::checkUnreachableCode","style"},
147+
{"CheckOther::checkUnusedLabel","style,warning"},
148+
{"CheckOther::checkVarFuncNullUB","portability"},
149+
{"CheckOther::checkVariableScope","style,notclang"},
150+
{"CheckOther::checkZeroDivision",""},
151+
{"CheckOther::clarifyCalculation","style"},
152+
{"CheckOther::clarifyStatement","warning"},
153+
{"CheckOther::invalidPointerCast","portability"},
154+
{"CheckOther::redundantBitwiseOperationInSwitch","warning"},
155+
{"CheckOther::suspiciousFloatingPointCast","style"},
156+
{"CheckOther::warningDangerousTypeCast","warning,c++"},
157+
{"CheckOther::warningIntToPointerCast","portability"},
158+
{"CheckOther::warningOldStylePointerCast","style,c++"},
159+
{"CheckPostfixOperator::postfixOperator","performance"},
160+
{"CheckSizeof::checkSizeofForArrayParameter","warning"},
161+
{"CheckSizeof::checkSizeofForNumericParameter","warning"},
162+
{"CheckSizeof::checkSizeofForPointerSize","warning"},
163+
{"CheckSizeof::sizeofCalculation","warning"},
164+
{"CheckSizeof::sizeofFunction","warning"},
165+
{"CheckSizeof::sizeofVoid","portability"},
166+
{"CheckSizeof::sizeofsizeof","warning"},
167+
{"CheckSizeof::suspiciousSizeofCalculation","warning,inconclusive"},
168+
{"CheckStl::checkDereferenceInvalidIterator","warning"},
169+
{"CheckStl::checkDereferenceInvalidIterator2",""},
170+
{"CheckStl::checkFindInsert","performance"},
171+
{"CheckStl::checkMutexes","warning"},
172+
{"CheckStl::erase",""},
173+
{"CheckStl::eraseIteratorOutOfBounds",""},
174+
{"CheckStl::if_find","warning,performance"},
175+
{"CheckStl::invalidContainer",""},
159176
{"CheckStl::iterators",""},
160-
{"CheckStl::misMatchingContainers",""},
177+
{"CheckStl::knownEmptyContainer","style"},
161178
{"CheckStl::misMatchingContainerIterator",""},
162-
{"CheckStl::invalidContainer",""},
163-
{"CheckStl::stlOutOfBounds",""},
179+
{"CheckStl::misMatchingContainers",""},
180+
{"CheckStl::missingComparison","warning"},
164181
{"CheckStl::negativeIndex",""},
165-
{"CheckStl::erase",""},
166-
{"CheckStl::stlBoundaries",""},
167-
{"CheckStl::if_find","warning,performance"},
168-
{"CheckStl::checkFindInsert","performance"},
169-
{"CheckStl::size","performance,c++03"},
182+
{"CheckStl::outOfBounds",""},
183+
{"CheckStl::outOfBoundsIndexExpression",""},
170184
{"CheckStl::redundantCondition","style"},
171-
{"CheckStl::missingComparison","warning"},
185+
{"CheckStl::size","performance,c++03"},
186+
{"CheckStl::stlBoundaries",""},
187+
{"CheckStl::stlOutOfBounds",""},
172188
{"CheckStl::string_c_str",""},
173-
{"CheckStl::uselessCalls","performance,warning"},
174-
{"CheckStl::checkDereferenceInvalidIterator","warning"},
175-
{"CheckStl::checkDereferenceInvalidIterator2",""},
176189
{"CheckStl::useStlAlgorithm","style"},
177-
{"CheckStl::knownEmptyContainer","style"},
178-
{"CheckStl::eraseIteratorOutOfBounds",""},
179-
{"CheckStl::checkMutexes","warning"},
180-
{"CheckType::checkTooBigBitwiseShift","platform"},
190+
{"CheckStl::uselessCalls","performance,warning"},
191+
{"CheckString::checkAlwaysTrueOrFalseStringCompare","warning"},
192+
{"CheckString::checkIncorrectStringCompare","warning"},
193+
{"CheckString::checkSuspiciousStringCompare","warning"},
194+
{"CheckString::overlappingStrcmp","warning"},
195+
{"CheckString::sprintfOverlappingData",""},
196+
{"CheckString::strPlusChar",""},
197+
{"CheckString::stringLiteralWrite",""},
198+
{"CheckType::checkFloatToIntegerOverflow",""},
181199
{"CheckType::checkIntegerOverflow","platform"},
182-
{"CheckType::checkSignConversion","warning"},
183200
{"CheckType::checkLongCast","style"},
184-
{"CheckType::checkFloatToIntegerOverflow",""},
201+
{"CheckType::checkSignConversion","warning"},
202+
{"CheckType::checkTooBigBitwiseShift","platform"},
203+
{"CheckUninitVar::analyseWholeProgram",""},
185204
{"CheckUninitVar::check",""},
186205
{"CheckUninitVar::valueFlowUninit",""},
187-
{"CheckUninitVar::analyseWholeProgram",""},
188-
{"CheckClass::checkConstructors","style,warning"},
189-
{"CheckClass::checkExplicitConstructors","style"},
190-
{"CheckClass::checkCopyConstructors","warning"},
191-
{"CheckClass::initializationListUsage","performance"},
192-
{"CheckClass::privateFunctions","style"},
193-
{"CheckClass::checkMemset",""},
194-
{"CheckClass::operatorEqRetRefThis","style"},
195-
{"CheckClass::operatorEqToSelf","warning"},
196-
{"CheckClass::virtualDestructor",""},
197-
{"CheckClass::thisSubtraction","warning"},
198-
{"CheckClass::checkConst","style,inconclusive"},
199-
{"CheckClass::initializerListOrder","style,inconclusive"},
200-
{"CheckClass::checkSelfInitialization",""},
201-
{"CheckClass::checkVirtualFunctionCallInConstructor","warning"},
202-
{"CheckClass::checkDuplInheritedMembers","warning"},
203-
{"CheckClass::checkMissingOverride","style,c++03"},
204-
{"CheckClass::checkUselessOverride","style"},
205-
{"CheckClass::checkReturnByReference","performance"},
206-
{"CheckClass::checkThisUseAfterFree","warning"},
207-
{"CheckClass::checkUnsafeClassRefMember","warning,safeChecks"},
208-
{"CheckClass::analyseWholeProgram",""},
206+
{"CheckUnusedFunctions::check","unusedFunction"},
209207
{"CheckUnusedVar::checkFunctionVariableUsage","style"},
210208
{"CheckUnusedVar::checkStructMemberUsage","style"},
209+
{"CheckVaarg::va_list_usage","notclang"},
210+
{"CheckVaarg::va_start_argument",""},
211211
};
212212

213213
const std::map<std::string, std::string> premiumCheckers{
@@ -991,7 +991,7 @@ namespace checkers {
991991
{"PremiumMetrics::HIS::StmtFile",""},
992992
{"PremiumMetrics::HIS::VOCF",""},
993993
{"PremiumMetrics::HIS::return",""},
994-
{"PremiumMetrics::cyclomaticComplexity",""}
994+
{"PremiumMetrics::cyclomaticComplexity",""},
995995
};
996996

997997
const char Req[] = "Required";
@@ -2666,7 +2666,6 @@ std::vector<checkers::Info> checkers::certCInfo{
26662666
{"STR04-C", "L3"},
26672667
{"STR05-C", "L3"},
26682668
{"STR06-C", "L2"},
2669-
{"STR07-C", "L1"},
26702669
{"STR08-C", "L2"},
26712670
{"STR09-C", "L3"},
26722671
{"STR10-C", "L3"},

0 commit comments

Comments
 (0)