MCPcopy Create free account
hub / github.com/ChaiScript/ChaiScript / enforceOk

Method enforceOk

unittests/catch.hpp:5795–5803  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5793
5794 protected:
5795 void enforceOk() const override {
5796
5797 // Errors shouldn't reach this point, but if they do
5798 // the actual error message will be in m_errorMessage
5799 assert( m_type != ResultBase::LogicError );
5800 assert( m_type != ResultBase::RuntimeError );
5801 if( m_type != ResultBase::Ok )
5802 std::abort();
5803 }
5804
5805 std::string m_errorMessage; // Only populated if resultType is an error
5806

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected