diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2023-04-14 21:41:27 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2023-06-22 18:20:56 +0000 |
commit | bdd1243df58e60e85101c09001d9812a789b6bc4 (patch) | |
tree | a1ce621c7301dd47ba2ddc3b8eaa63b441389481 /contrib/llvm-project/llvm/lib/DebugInfo/GSYM/FunctionInfo.cpp | |
parent | 781624ca2d054430052c828ba8d2c2eaf2d733e7 (diff) | |
parent | e3b557809604d036af6e00c60f012c2025b59a5e (diff) |
Diffstat (limited to 'contrib/llvm-project/llvm/lib/DebugInfo/GSYM/FunctionInfo.cpp')
-rw-r--r-- | contrib/llvm-project/llvm/lib/DebugInfo/GSYM/FunctionInfo.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/contrib/llvm-project/llvm/lib/DebugInfo/GSYM/FunctionInfo.cpp b/contrib/llvm-project/llvm/lib/DebugInfo/GSYM/FunctionInfo.cpp index 4f5d240cdf72..51058fc09cf1 100644 --- a/contrib/llvm-project/llvm/lib/DebugInfo/GSYM/FunctionInfo.cpp +++ b/contrib/llvm-project/llvm/lib/DebugInfo/GSYM/FunctionInfo.cpp @@ -12,6 +12,7 @@ #include "llvm/DebugInfo/GSYM/LineTable.h" #include "llvm/DebugInfo/GSYM/InlineInfo.h" #include "llvm/Support/DataExtractor.h" +#include <optional> using namespace llvm; using namespace gsym; @@ -178,8 +179,8 @@ llvm::Expected<LookupResult> FunctionInfo::lookup(DataExtractor &Data, Offset - 4); LR.FuncName = GR.getString(NameOffset); bool Done = false; - Optional<LineEntry> LineEntry; - Optional<DataExtractor> InlineInfoData; + std::optional<LineEntry> LineEntry; + std::optional<DataExtractor> InlineInfoData; while (!Done) { if (!Data.isValidOffsetForDataOfSize(Offset, 8)) return createStringError(std::errc::io_error, @@ -226,7 +227,7 @@ llvm::Expected<LookupResult> FunctionInfo::lookup(DataExtractor &Data, return LR; } - Optional<FileEntry> LineEntryFile = GR.getFile(LineEntry->File); + std::optional<FileEntry> LineEntryFile = GR.getFile(LineEntry->File); if (!LineEntryFile) return createStringError(std::errc::invalid_argument, "failed to extract file[%" PRIu32 "]", |