Improved testing of std.cfg.
This commit is contained in:
parent
f3505f617b
commit
5e50166135
|
@ -3888,6 +3888,9 @@
|
|||
<function name="find" action="find"/>
|
||||
</access>
|
||||
</container>
|
||||
<container id="stdComplex" startPattern="std :: complex <" endPattern="> !!::">
|
||||
<type templateParameter="1"/>
|
||||
</container>
|
||||
<container id="stdAllString" inherits="stdContainer">
|
||||
<type string="std-like"/>
|
||||
<size>
|
||||
|
|
|
@ -3378,3 +3378,11 @@ void invalidFunctionArgBool_abs(bool b, double x, double y)
|
|||
// cppcheck-suppress invalidFunctionArgBool
|
||||
(void)abs(x<y); // #5635
|
||||
}
|
||||
|
||||
void ignoredReturnValue_abs(int i)
|
||||
{
|
||||
// cppcheck-suppress ignoredReturnValue
|
||||
abs(i);
|
||||
// cppcheck-suppress constStatement
|
||||
abs(-100);
|
||||
}
|
||||
|
|
|
@ -2709,3 +2709,20 @@ void uninitvar_setbase(void)
|
|||
std::cout << std::setbase(p);
|
||||
}
|
||||
|
||||
void invalidFunctionArgBool_abs(bool b, double x, double y)
|
||||
{
|
||||
// cppcheck-suppress invalidFunctionArgBool
|
||||
(void)std::abs(true); // #6990
|
||||
// cppcheck-suppress invalidFunctionArgBool
|
||||
(void)std::abs(b); // #6990
|
||||
// cppcheck-suppress invalidFunctionArgBool
|
||||
(void)std::abs(x<y); // #5635
|
||||
}
|
||||
|
||||
void ignoredReturnValue_abs(int i)
|
||||
{
|
||||
// cppcheck-suppress ignoredReturnValue
|
||||
std::abs(i);
|
||||
// cppcheck-suppress constStatement
|
||||
std::abs(-199);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue