diff options
author | Militsa Sotirova <militsa.sotirova@mongodb.com> | 2022-09-30 19:16:04 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2022-09-30 20:15:40 +0000 |
commit | 29c5c67ac1e47a716717c9a0e5e398865c789873 (patch) | |
tree | bdb5b31e4e69d41ce6beecaafcf972caba5183a8 | |
parent | c0014a3655c663333d506124284b99cb1bf0fd47 (diff) | |
download | mongo-29c5c67ac1e47a716717c9a0e5e398865c789873.tar.gz |
SERVER-70136 Make loop variable a const reference
-rw-r--r-- | src/mongo/db/query/optimizer/utils/unit_test_utils.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mongo/db/query/optimizer/utils/unit_test_utils.cpp b/src/mongo/db/query/optimizer/utils/unit_test_utils.cpp index c060535acf6..c857f6fd355 100644 --- a/src/mongo/db/query/optimizer/utils/unit_test_utils.cpp +++ b/src/mongo/db/query/optimizer/utils/unit_test_utils.cpp @@ -203,7 +203,7 @@ void serializeMetadata(std::ostream& stream, Metadata metadata) { // The ScanDefinitions are stored in an unordered map, and the order of the ScanDefinitions in // the golden file must be the same every time the test is run. std::map<std::string, ScanDefinition> orderedScanDefs; - for (auto element : metadata._scanDefs) { + for (const auto& element : metadata._scanDefs) { orderedScanDefs.insert(element); } |