diff --git a/src/ripple/basics/contract.h b/src/ripple/basics/contract.h index a4a7a849ea..9b65e826c3 100644 --- a/src/ripple/basics/contract.h +++ b/src/ripple/basics/contract.h @@ -43,12 +43,11 @@ throwException( } // detail -template +template void Throw (Args&&... args) { - throwException( + detail::throwException( std::make_exception_ptr( Exception(std::forward< Args>(args)...))); @@ -59,6 +58,11 @@ void LogicError ( std::string const& how); +/** Called to throw an exception. */ +#ifndef THROW +#define THROW(T, arg) Throw(arg) +#endif + } // ripple #endif