Index: include/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h =================================================================== --- include/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h +++ include/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h @@ -171,7 +171,7 @@ auto Err = Client.deregisterEHFrames(Frame.Addr, Frame.Size); // FIXME: Add error poll. assert(!Err && "Failed to register remote EH frames."); - (void)Err; + llvm::consumeError(std::move(Err)); } } Index: unittests/Support/ErrorTest.cpp =================================================================== --- unittests/Support/ErrorTest.cpp +++ unittests/Support/ErrorTest.cpp @@ -482,7 +482,7 @@ } // Test that cantFail results in a crash if you pass it a failure value. -#if LLVM_ENABLE_ABI_BREAKING_CHECKS +#if LLVM_ENABLE_ABI_BREAKING_CHECKS && !defined(NDEBUG) TEST(Error, CantFailDeath) { EXPECT_DEATH( cantFail(make_error("foo", inconvertibleErrorCode())),