/*============================================================================= Copyright (c) 2005-2007 Dan Marsden Copyright (c) 2005-2007 Joel de Guzman Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) ==============================================================================*/ #ifndef PHOENIX_STATEMENT_THROW_HPP #define PHOENIX_STATEMENT_THROW_HPP #include #include #include #include namespace boost { namespace phoenix { struct throw_new_eval { template struct result { typedef void type; }; template static void eval(const Env& env, ThrowExpr& throwExpr) { throw throwExpr.eval(env); } }; struct throw_again_eval { typedef mpl::false_ no_nullary; template struct result { typedef void type; }; template void eval(const Env&) const { throw; } }; inline actor throw_() { return throw_again_eval(); } template actor::type> throw_(const Actor& a) { return compose(a); } }} #endif