Clang: Limit the usage of qMakePair and std::make_pair

Change-Id: Ida094760023047ecb8ba29e60d5e81f766981b65
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
Jarek Kobus
2022-09-30 14:11:20 +02:00
parent 93dc9ce591
commit 95e54055ef
8 changed files with 29 additions and 39 deletions

View File

@@ -200,7 +200,7 @@ void ClangdFindReferences::Private::handleFindUsagesResult(const QList<Location>
});
for (const Location &loc : locations)
fileData[loc.uri()].rangesAndLineText << qMakePair(loc.range(), QString());
fileData[loc.uri()].rangesAndLineText.push_back({loc.range(), {}});
for (auto it = fileData.begin(); it != fileData.end();) {
const Utils::FilePath filePath = it.key().toFilePath();
if (!filePath.exists()) { // https://github.com/clangd/clangd/issues/935