File indexing completed on 2025-01-18 09:53:51
0001
0002
0003
0004
0005
0006
0007
0008 #ifndef BOOST_XPRESSIVE_DETAIL_STATIC_MODIFIER_HPP_EAN_10_04_2005
0009 #define BOOST_XPRESSIVE_DETAIL_STATIC_MODIFIER_HPP_EAN_10_04_2005
0010
0011
0012 #if defined(_MSC_VER)
0013 # pragma once
0014 # pragma warning(push)
0015 # pragma warning(disable : 4510)
0016 # pragma warning(disable : 4610)
0017 #endif
0018
0019 #include <boost/xpressive/detail/detail_fwd.hpp>
0020 #include <boost/proto/traits.hpp>
0021 #include <boost/xpressive/regex_constants.hpp>
0022
0023 namespace boost { namespace xpressive { namespace detail
0024 {
0025
0026
0027
0028 template<typename Modifier>
0029 struct modifier_op
0030 {
0031 typedef regex_constants::syntax_option_type opt_type;
0032
0033 template<typename Expr>
0034 struct apply
0035 {
0036 typedef typename proto::binary_expr<
0037 modifier_tag
0038 , typename proto::terminal<Modifier>::type
0039 , typename proto::result_of::as_child<Expr const>::type
0040 >::type type;
0041 };
0042
0043 template<typename Expr>
0044 typename apply<Expr>::type const
0045 operator ()(Expr const &expr) const
0046 {
0047 typename apply<Expr>::type that = {{this->mod_}, proto::as_child(expr)};
0048 return that;
0049 }
0050
0051 operator opt_type() const
0052 {
0053 return this->opt_;
0054 }
0055
0056 Modifier mod_;
0057 opt_type opt_;
0058 };
0059
0060 }}}
0061
0062 #if defined(_MSC_VER)
0063 # pragma warning(pop)
0064 #endif
0065
0066 #endif