if (!Stmt)
continue;
- StmtToBlock[Stmt.value().getStmt()] = Block;
+ StmtToBlock[Stmt->getStmt()] = Block;
}
if (const Stmt *TerminatorStmt = Block->getTerminatorStmt())
StmtToBlock[TerminatorStmt] = Block;
auto StatusString = clang::dataflow::debugString(Result.getStatus());
auto Solution = Result.getSolution();
- auto SolutionString = Solution ? "\n" + debugString(Solution.value()) : "";
+ auto SolutionString = Solution ? "\n" + debugString(*Solution) : "";
return formatv(
Template,
if (!MaybePredState)
continue;
- TypeErasedDataflowAnalysisState PredState = MaybePredState.value();
+ TypeErasedDataflowAnalysisState PredState = *MaybePredState;
if (BuiltinTransferOpts) {
if (const Stmt *PredTerminatorStmt = Pred->getTerminatorStmt()) {
const StmtToEnvMapImpl StmtToEnv(AC.CFCtx, AC.BlockStates);
const Optional<bool> V = handleDeclForVisitation(*TL);
if (!V)
continue;
- return V.value();
+ return *V;
}
} else if (VisitDeclContext(
CXXUnit->getASTContext().getTranslationUnitDecl()))
const Optional<bool> V = handleDeclForVisitation(D);
if (!V)
continue;
- return V.value();
+ return *V;
}
return false;
}
const Optional<bool> V = shouldVisitCursor(Cursor);
if (!V)
return std::nullopt;
- if (!V.value())
+ if (!*V)
return false;
if (Visit(Cursor, true))
return true;
const Optional<bool> &V = shouldVisitCursor(Cursor);
if (!V)
continue;
- if (!V.value())
+ if (!*V)
return false;
if (Visit(Cursor, true))
return true;
EXPECT_TRUE(FoundFile.has_value());
EXPECT_TRUE(IsFrameworkFound);
- auto &FE = FoundFile.value();
+ auto &FE = *FoundFile;
auto FI = Search.getExistingFileInfo(FE);
EXPECT_TRUE(FI);
EXPECT_TRUE(FI->IsValid);
EXPECT_TRUE(FoundFile.has_value());
EXPECT_TRUE(IsMapped);
- auto &FE = FoundFile.value();
+ auto &FE = *FoundFile;
auto FI = Search.getExistingFileInfo(FE);
EXPECT_TRUE(FI);
EXPECT_TRUE(FI->IsValid);