annotate DEPENDENCIES/generic/include/boost/spirit/home/support/argument_expression.hpp @ 133:4acb5d8d80b6 tip

Don't fail environmental check if README.md exists (but .txt and no-suffix don't)
author Chris Cannam
date Tue, 30 Jul 2019 12:25:44 +0100
parents c530137014c0
children
rev   line source
Chris@16 1 /*=============================================================================
Chris@16 2 Copyright (c) 2011 Thomas Heller
Chris@16 3 Copyright (c) 2001-2011 Hartmut Kaiser
Chris@16 4 Copyright (c) 2011 Thomas Heller
Chris@16 5
Chris@16 6 Distributed under the Boost Software License, Version 1.0. (See accompanying
Chris@16 7 file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
Chris@16 8 ==============================================================================*/
Chris@16 9 #if !defined(BOOST_SPIRIT_ARGUMENT_MARCH_22_2011_0939PM)
Chris@16 10 #define BOOST_SPIRIT_ARGUMENT_MARCH_22_2011_0939PM
Chris@16 11
Chris@16 12 #include <boost/spirit/include/phoenix_core.hpp>
Chris@16 13
Chris@16 14 namespace boost { namespace spirit
Chris@16 15 {
Chris@16 16 template <int N>
Chris@16 17 struct argument;
Chris@16 18
Chris@16 19 template <typename Dummy>
Chris@16 20 struct attribute_context;
Chris@16 21
Chris@16 22 namespace expression
Chris@16 23 {
Chris@16 24 template <int N>
Chris@16 25 struct argument
Chris@16 26 : phoenix::expression::terminal<spirit::argument<N> >
Chris@16 27 {
Chris@16 28 typedef typename phoenix::expression::terminal<
Chris@16 29 spirit::argument<N>
Chris@16 30 >::type type;
Chris@16 31
Chris@16 32 static type make()
Chris@16 33 {
Chris@16 34 type const e = {{{}}};
Chris@16 35 return e;
Chris@16 36 }
Chris@16 37 };
Chris@16 38
Chris@16 39 template <typename Dummy>
Chris@16 40 struct attribute_context
Chris@16 41 : phoenix::expression::terminal<spirit::attribute_context<Dummy> >
Chris@16 42 {
Chris@16 43 typedef typename phoenix::expression::terminal<
Chris@16 44 spirit::attribute_context<Dummy>
Chris@16 45 >::type type;
Chris@16 46
Chris@16 47 static type make()
Chris@16 48 {
Chris@16 49 type const e = {{{}}};
Chris@16 50 return e;
Chris@16 51 }
Chris@16 52 };
Chris@16 53 }
Chris@16 54 }}
Chris@16 55
Chris@16 56 namespace boost { namespace phoenix
Chris@16 57 {
Chris@16 58 namespace result_of
Chris@16 59 {
Chris@16 60 template <typename Dummy>
Chris@16 61 struct is_nullary<custom_terminal<spirit::attribute_context<Dummy> > >
Chris@16 62 : mpl::false_
Chris@16 63 {};
Chris@16 64
Chris@16 65 template <int N>
Chris@16 66 struct is_nullary<custom_terminal<spirit::argument<N> > >
Chris@16 67 : mpl::false_
Chris@16 68 {};
Chris@16 69 }
Chris@16 70
Chris@16 71 template <typename Dummy>
Chris@16 72 struct is_custom_terminal<spirit::attribute_context<Dummy> >
Chris@16 73 : mpl::true_
Chris@16 74 {};
Chris@16 75
Chris@16 76 template <int N>
Chris@16 77 struct is_custom_terminal<spirit::argument<N> >
Chris@16 78 : mpl::true_
Chris@16 79 {};
Chris@16 80
Chris@16 81 template <typename Dummy>
Chris@16 82 struct custom_terminal<spirit::attribute_context<Dummy> >
Chris@16 83 : proto::call<
Chris@16 84 v2_eval(
Chris@16 85 proto::make<spirit::attribute_context<Dummy>()>
Chris@16 86 , proto::call<
Chris@16 87 functional::env(proto::_state)
Chris@16 88 >
Chris@16 89 )
Chris@16 90 >
Chris@16 91 {};
Chris@16 92
Chris@16 93 template <int N>
Chris@16 94 struct custom_terminal<spirit::argument<N> >
Chris@16 95 : proto::call<
Chris@16 96 v2_eval(
Chris@16 97 proto::make<spirit::argument<N>()>
Chris@16 98 , proto::call<
Chris@16 99 functional::env(proto::_state)
Chris@16 100 >
Chris@16 101 )
Chris@16 102 >
Chris@16 103 {};
Chris@16 104 }}
Chris@16 105
Chris@16 106 #endif