Mercurial > hg > vamp-build-and-test
annotate DEPENDENCIES/generic/include/boost/spirit/home/qi/auto/create_parser.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 | 2665513ce2d3 |
children |
rev | line source |
---|---|
Chris@16 | 1 // Copyright (c) 2001-2011 Hartmut Kaiser |
Chris@16 | 2 // |
Chris@16 | 3 // Distributed under the Boost Software License, Version 1.0. (See accompanying |
Chris@16 | 4 // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) |
Chris@16 | 5 |
Chris@16 | 6 #if !defined(BOOST_SPIRIT_QI_CREATE_NOV_21_2009_0444PM) |
Chris@16 | 7 #define BOOST_SPIRIT_QI_CREATE_NOV_21_2009_0444PM |
Chris@16 | 8 |
Chris@16 | 9 #if defined(_MSC_VER) |
Chris@16 | 10 #pragma once |
Chris@16 | 11 #endif |
Chris@16 | 12 |
Chris@16 | 13 #include <boost/spirit/home/qi/auto/meta_create.hpp> |
Chris@16 | 14 |
Chris@16 | 15 /////////////////////////////////////////////////////////////////////////////// |
Chris@16 | 16 namespace boost { namespace spirit { namespace result_of |
Chris@16 | 17 { |
Chris@16 | 18 template <typename T> |
Chris@16 | 19 struct create_parser |
Chris@16 | 20 : spirit::traits::meta_create<qi::domain, T> {}; |
Chris@16 | 21 }}} |
Chris@16 | 22 |
Chris@16 | 23 /////////////////////////////////////////////////////////////////////////////// |
Chris@16 | 24 namespace boost { namespace spirit { namespace qi |
Chris@16 | 25 { |
Chris@16 | 26 // Main API function for parser creation from data type |
Chris@16 | 27 template <typename T> |
Chris@16 | 28 typename result_of::create_parser<T>::type |
Chris@16 | 29 create_parser() |
Chris@16 | 30 { |
Chris@16 | 31 return spirit::traits::meta_create<qi::domain, T>::call(); |
Chris@16 | 32 } |
Chris@16 | 33 }}} |
Chris@16 | 34 |
Chris@16 | 35 /////////////////////////////////////////////////////////////////////////////// |
Chris@16 | 36 namespace boost { namespace spirit { namespace traits |
Chris@16 | 37 { |
Chris@16 | 38 // Meta function returning true if create_parser does return a valid |
Chris@16 | 39 // parser for the given type T. |
Chris@16 | 40 template <typename T> |
Chris@16 | 41 struct create_parser_exists |
Chris@16 | 42 : meta_create_exists<qi::domain, T> {}; |
Chris@16 | 43 }}} |
Chris@16 | 44 |
Chris@16 | 45 #endif |