• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*=============================================================================
2     Copyright (c) 2019 Nikita Kniazev
3 
4     Use, modification and distribution is subject to the Boost Software
5     License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
6     http://www.boost.org/LICENSE_1_0.txt)
7 =============================================================================*/
8 
9 #include "rule_separate_tu_grammar.hpp"
10 
11 #include <boost/spirit/home/x3.hpp>
12 
13 namespace unused_attr {
14 
15 const auto skipper_def = x3::lit('*');
16 BOOST_SPIRIT_DEFINE(skipper)
17 BOOST_SPIRIT_INSTANTIATE(skipper_type, char const*, x3::unused_type)
18 
19 const auto skipper2_def = x3::lit('#');
20 BOOST_SPIRIT_DEFINE(skipper2)
21 BOOST_SPIRIT_INSTANTIATE(skipper2_type, char const*, x3::unused_type)
22 
23 const auto grammar_def = *x3::lit('=');
24 BOOST_SPIRIT_DEFINE(grammar)
25 BOOST_SPIRIT_INSTANTIATE(grammar_type, char const*, x3::unused_type)
26 BOOST_SPIRIT_INSTANTIATE(grammar_type, char const*, x3::phrase_parse_context<skipper_type>::type)
27 BOOST_SPIRIT_INSTANTIATE(grammar_type, char const*, x3::phrase_parse_context<skipper2_type>::type)
28 
29 }
30 
31 namespace used_attr {
32 
33 const auto skipper_def = x3::space;
34 BOOST_SPIRIT_DEFINE(skipper)
35 BOOST_SPIRIT_INSTANTIATE(skipper_type, char const*, x3::unused_type)
36 
37 const auto grammar_def = x3::int_;
38 BOOST_SPIRIT_DEFINE(grammar)
39 BOOST_SPIRIT_INSTANTIATE(grammar_type, char const*, x3::unused_type)
40 BOOST_SPIRIT_INSTANTIATE(grammar_type, char const*, x3::phrase_parse_context<skipper_type>::type)
41 
42 }
43