Optimize ParserFileStream making unused temp copies of path opject

This commit is contained in:
Jan 2021-02-10 15:36:22 +01:00
parent f91c7f6afc
commit e93c20faf8

View File

@ -75,7 +75,8 @@ bool ParserFilesystemStream::IncludeFile(const std::string& filename)
if (m_files.empty())
return false;
const auto newFilePath = fs::path(m_files.top().m_file_path).remove_filename().concat(filename);
auto newFilePath = fs::path(m_files.top().m_file_path);
newFilePath.remove_filename().concat(filename);
FileInfo fileInfo(newFilePath.string());