Index: llvm/trunk/include/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h =================================================================== --- llvm/trunk/include/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h +++ llvm/trunk/include/llvm/ExecutionEngine/Orc/OrcRemoteTargetClient.h @@ -168,10 +168,8 @@ void deregisterEHFrames() override { for (auto &Frame : RegisteredEHFrames) { - auto Err = Client.deregisterEHFrames(Frame.Addr, Frame.Size); // FIXME: Add error poll. - assert(!Err && "Failed to register remote EH frames."); - (void)Err; + llvm::cantFail(Client.deregisterEHFrames(Frame.Addr, Frame.Size)); } } Index: llvm/trunk/unittests/Support/ErrorTest.cpp =================================================================== --- llvm/trunk/unittests/Support/ErrorTest.cpp +++ llvm/trunk/unittests/Support/ErrorTest.cpp @@ -483,7 +483,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())),