diff options
Diffstat (limited to 'llvm/tools/llvm-sim/llvm-sim.cpp')
-rw-r--r-- | llvm/tools/llvm-sim/llvm-sim.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/llvm/tools/llvm-sim/llvm-sim.cpp b/llvm/tools/llvm-sim/llvm-sim.cpp index 26e370f..2b717d7 100644 --- a/llvm/tools/llvm-sim/llvm-sim.cpp +++ b/llvm/tools/llvm-sim/llvm-sim.cpp @@ -85,14 +85,13 @@ exportToFile(const StringRef FilePath, Optional<unsigned> End = getPositionInModule((*C.back()).Inst, LLVMInstNum); - assert(Start.hasValue() && + assert(Start && "Could not find instruction number for first instruction"); - assert(End.hasValue() && - "Could not find instruction number for last instruction"); + assert(End && "Could not find instruction number for last instruction"); J.object([&] { - J.attribute("start", Start.getValue()); - J.attribute("end", End.getValue()); + J.attribute("start", Start.value()); + J.attribute("end", End.value()); }); } J.arrayEnd(); |