diff --git a/llvm/lib/CodeGen/WinEHPrepare.cpp b/llvm/lib/CodeGen/WinEHPrepare.cpp index cc225a500922..2601d7a98be9 100644 --- a/llvm/lib/CodeGen/WinEHPrepare.cpp +++ b/llvm/lib/CodeGen/WinEHPrepare.cpp @@ -875,7 +875,7 @@ bool WinEHPrepare::outlineHandler(ActionHandler *Action, Function *SrcFn, // save the association of the blocks in LPadTargetBlocks. The // return instructions which are created from these branches will be // replaced after all landing pads have been outlined. - for (auto &MapEntry : VMap) { + for (const auto &MapEntry : VMap) { // VMap maps all values and blocks that were just cloned, but dead // blocks which were pruned will map to nullptr. if (!isa(MapEntry.first) || MapEntry.second == nullptr)