Fix not correct adding input suffix when expanding nested macro

This commit is contained in:
Jan 2023-12-30 16:45:06 +01:00
parent 70d4d77266
commit edb88273e7
No known key found for this signature in database
GPG Key ID: 44B581F78FF5C57C

View File

@ -837,8 +837,8 @@ void DefinesStreamProxy::ProcessNestedMacros(ParserLine& line, unsigned& linePos
if (usesDefines) if (usesDefines)
{ {
// Make sure we account for all text between the last macro and the end // Make sure we account for all text between the last macro and the end
if (lastDefineEnd < line.m_line.size()) if (lastDefineEnd < input.size())
ss << std::string(line.m_line, lastDefineEnd, line.m_line.size() - lastDefineEnd); ss << std::string(input, lastDefineEnd, input.size() - lastDefineEnd);
input = ss.str(); input = ss.str();
} }
} }