SymbolDatabase: Better handling when return type of function is PodType

This commit is contained in:
Daniel Marjamäki 2019-09-28 14:57:24 +02:00
parent 6a5b590d7f
commit 4138bf7fb3
1 changed files with 7 additions and 0 deletions

View File

@ -5532,6 +5532,13 @@ void SymbolDatabase::setValueTypeInTokenList(bool reportDebugWarnings)
// library function
else if (tok->previous()) {
const std::string& typestr(mSettings->library.returnValueType(tok->previous()));
if (!typestr.empty()) {
ValueType valuetype;
if (valuetype.fromLibraryType(typestr, mSettings)) {
setValueType(tok, valuetype);
}
}
if (typestr.empty() || typestr == "iterator") {
if (Token::simpleMatch(tok->astOperand1(), ".") &&
tok->astOperand1()->astOperand1() &&