We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a16374e commit ea15772Copy full SHA for ea15772
llvm/lib/ExecutionEngine/Orc/EPCDebugObjectRegistrar.cpp
@@ -41,8 +41,11 @@ Expected<std::unique_ptr<EPCDebugObjectRegistrar>> createJITLoaderGDBRegistrar(
41
assert(Result->size() == 1 && "Unexpected number of dylibs in result");
42
assert((*Result)[0].size() == 1 &&
43
"Unexpected number of addresses in result");
44
- assert((*Result)[0][0].has_value() &&
45
- "Expected a valid address in the lookup result");
+
+ if (!(*Result)[0][0].has_value())
46
+ return make_error<StringError>(
47
+ "Expected a valid address in the lookup result",
48
+ inconvertibleErrorCode());
49
50
ExecutorAddr RegisterAddr = (*Result)[0][0]->getAddress();
51
return std::make_unique<EPCDebugObjectRegistrar>(ES, RegisterAddr);
0 commit comments