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
#include <cstddef>
#include <cstdint>
#include <iterator>
+#include <optional>
#include <string>
#include <vector>
///
/// It is an error to call this for operand bundle types that may have
/// multiple instances of them on the same instruction.
- Optional<OperandBundleUse> getOperandBundle(StringRef Name) const {
+ std::optional<OperandBundleUse> getOperandBundle(StringRef Name) const {
assert(countOperandBundlesOfType(Name) < 2 && "Precondition violated!");
for (unsigned i = 0, e = getNumOperandBundles(); i != e; ++i) {