/usr/include/boost/phoenix/object
Edit: /usr/include/boost/phoenix/object/static_cast.hpp (2054B)
/*==============================================================================
Copyright (c) 2001-2010 Joel de Guzman
Copyright (c) 2010 Thomas Heller
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 BOOST_PHOENIX_OBJECT_STATIC_CAST_HPP
#define BOOST_PHOENIX_OBJECT_STATIC_CAST_HPP
#include
#include
#include
#include
#include
#include
BOOST_PHOENIX_DEFINE_EXPRESSION(
(boost)(phoenix)(static_cast_)
, (proto::terminal >)
(meta_grammar)
)
namespace boost { namespace phoenix
{
struct static_cast_eval
{
template
struct result;
template
struct result
: detail::result_of::target
{};
template
typename detail::result_of::target::type
operator()(Target, Source const& u, Context const& ctx) const
{
return static_cast<
typename detail::result_of::target::type
>(boost::phoenix::eval(u, ctx));
}
};
template
struct default_actions::when
: call
{};
template
inline
typename expression::static_cast_, U>::type const
static_cast_(U const& u)
{
return
expression::
static_cast_, U>::
make(detail::target(), u);
}
}}
#endif