File indexing completed on 2025-01-30 10:02:17
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013 #if !defined(BOOST_WAVE_LEX_INTERFACE_GENERATOR_HPP_INCLUDED)
0014 #define BOOST_WAVE_LEX_INTERFACE_GENERATOR_HPP_INCLUDED
0015
0016 #include <boost/wave/wave_config.hpp>
0017 #include <boost/wave/util/file_position.hpp>
0018 #include <boost/wave/language_support.hpp>
0019 #include <boost/wave/cpplexer/cpp_lex_interface.hpp>
0020 #include <boost/wave/cpplexer/cpp_lex_token.hpp> // lex_token
0021
0022
0023 #ifdef BOOST_HAS_ABI_HEADERS
0024 #include BOOST_ABI_PREFIX
0025 #endif
0026
0027
0028 #ifdef BOOST_MSVC
0029 #pragma warning(push)
0030 #pragma warning(disable : 4251 4231 4660)
0031 #endif
0032
0033
0034 namespace boost {
0035 namespace wave {
0036 namespace cpplexer {
0037
0038 #if BOOST_WAVE_SEPARATE_LEXER_INSTANTIATION != 0
0039 #define BOOST_WAVE_NEW_LEXER_DECL BOOST_WAVE_DECL
0040 #else
0041 #define BOOST_WAVE_NEW_LEXER_DECL
0042 #endif
0043
0044
0045
0046
0047
0048
0049 template <
0050 typename IteratorT,
0051 typename PositionT = boost::wave::util::file_position_type,
0052 typename TokenT = lex_token<PositionT>
0053 >
0054 struct BOOST_WAVE_NEW_LEXER_DECL new_lexer_gen
0055 {
0056
0057
0058
0059 static lex_input_interface<TokenT> *
0060 new_lexer(IteratorT const &first, IteratorT const &last,
0061 PositionT const &pos, boost::wave::language_support language);
0062 };
0063
0064 #undef BOOST_WAVE_NEW_LEXER_DECL
0065
0066
0067
0068
0069
0070
0071
0072
0073
0074 template <typename TokenT>
0075 struct lex_input_interface_generator
0076 : lex_input_interface<TokenT>
0077 {
0078 typedef typename lex_input_interface<TokenT>::position_type position_type;
0079
0080 lex_input_interface_generator() {}
0081 ~lex_input_interface_generator() {}
0082
0083
0084
0085
0086 template <typename IteratorT>
0087 static lex_input_interface<TokenT> *
0088 new_lexer(IteratorT const &first, IteratorT const &last,
0089 position_type const &pos, boost::wave::language_support language)
0090 {
0091 return new_lexer_gen<IteratorT, position_type, TokenT>::new_lexer (
0092 first, last, pos, language);
0093 }
0094 };
0095
0096
0097 }
0098 }
0099 }
0100
0101 #ifdef BOOST_MSVC
0102 #pragma warning(pop)
0103 #endif
0104
0105
0106 #ifdef BOOST_HAS_ABI_HEADERS
0107 #include BOOST_ABI_SUFFIX
0108 #endif
0109
0110 #endif