diff --git a/llvm/unittests/ProfileData/MemProfTest.cpp b/llvm/unittests/ProfileData/MemProfTest.cpp index 5886d3e2bcf84..3d975f96ed96c 100644 --- a/llvm/unittests/ProfileData/MemProfTest.cpp +++ b/llvm/unittests/ProfileData/MemProfTest.cpp @@ -161,9 +161,8 @@ TEST(MemProf, FillsValue) { /*KeepName=*/true); llvm::DenseMap Records; - for (const auto &Pair : Reader) { + for (const auto &Pair : Reader) Records.insert({Pair.first, Pair.second}); - } // Mock program pseudocode and expected memprof record contents. // @@ -396,9 +395,8 @@ TEST(MemProf, SymbolizationFilter) { RawMemProfReader Reader(std::move(Symbolizer), Seg, Prof, CSM); llvm::SmallVector Records; - for (const auto &KeyRecordPair : Reader) { + for (const auto &KeyRecordPair : Reader) Records.push_back(KeyRecordPair.second); - } ASSERT_THAT(Records, SizeIs(1)); ASSERT_THAT(Records[0].AllocSites, SizeIs(1)); @@ -428,9 +426,8 @@ TEST(MemProf, BaseMemProfReader) { MemProfReader Reader(std::move(MemProfData)); llvm::SmallVector Records; - for (const auto &KeyRecordPair : Reader) { + for (const auto &KeyRecordPair : Reader) Records.push_back(KeyRecordPair.second); - } ASSERT_THAT(Records, SizeIs(1)); ASSERT_THAT(Records[0].AllocSites, SizeIs(1)); @@ -463,9 +460,8 @@ TEST(MemProf, BaseMemProfReaderWithCSIdMap) { MemProfReader Reader(std::move(MemProfData)); llvm::SmallVector Records; - for (const auto &KeyRecordPair : Reader) { + for (const auto &KeyRecordPair : Reader) Records.push_back(KeyRecordPair.second); - } ASSERT_THAT(Records, SizeIs(1)); ASSERT_THAT(Records[0].AllocSites, SizeIs(1));