[mlir] Use std::nullopt instead of None (NFC)

This patch mechanically replaces None with std::nullopt where the
compiler would warn if None were deprecated.  The intent is to reduce
the amount of manual work required in migrating from Optional to
std::optional.

This is part of an effort to migrate from llvm::Optional to
std::optional:

https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasvalue-getvalue-getvalueor/63716
This commit is contained in:
Kazu Hirata
2022-12-03 18:50:27 -08:00
parent 1d650d4f1d
commit 1a36588ec6
197 changed files with 594 additions and 581 deletions

View File

@@ -608,7 +608,7 @@ void ForeachOp::build(
OpBuilder &builder, OperationState &result, Value tensor,
function_ref<void(OpBuilder &, Location, ValueRange, Value, ValueRange)>
bodyBuilder) {
build(builder, result, tensor, llvm::None, bodyBuilder);
build(builder, result, tensor, std::nullopt, bodyBuilder);
}
void ForeachOp::build(