testing std::string and std::vector configuration a little

This commit is contained in:
Daniel Marjamäki 2017-03-05 22:23:45 +01:00
parent 5ea9519586
commit d535f17489
1 changed files with 18 additions and 0 deletions

View File

@ -3244,3 +3244,21 @@ void getline()
in.close();
}
void stdstring() {
std::string s;
// test that return type from s.empty() is bool
// cppcheck-suppress assignBoolToPointer
char *p = s.empty();
(void)p;
// cppcheck-suppress ignoredReturnValue
s.size();
}
void stdvector() {
std::vector<int> v;
// cppcheck-suppress ignoredReturnValue
v.size();
}