diff --git a/bolt/lib/Core/Exceptions.cpp b/bolt/lib/Core/Exceptions.cpp index f8e07f2fa171f7..657c3137ae9d62 100644 --- a/bolt/lib/Core/Exceptions.cpp +++ b/bolt/lib/Core/Exceptions.cpp @@ -398,8 +398,8 @@ void BinaryFunction::updateEHRanges() { // Same symbol is used for the beginning and the end of the range. MCSymbol *EHSymbol; - if (auto InstrLabel = BC.MIB->getLabel(Instr)) { - EHSymbol = *InstrLabel; + if (MCSymbol *InstrLabel = BC.MIB->getLabel(Instr)) { + EHSymbol = InstrLabel; } else { std::unique_lock Lock(BC.CtxMutex); EHSymbol = BC.Ctx->createNamedTempSymbol("EH");