Subject: [Boost-bugs] [Boost C++ Libraries] #7822: waveidl sample does not use the IDL lexer, but the default lexer
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2012-12-21 19:38:17
#7822: waveidl sample does not use the IDL lexer, but the default lexer
-----------------------------------------------------------+----------------
Reporter: Michael Soegtrop <michael.soegtrop@â¦> | Owner: hkaiser
Type: Bugs | Status: new
Milestone: To Be Determined | Component: wave
Version: Boost 1.52.0 | Severity: Problem
Keywords: waveidl, sample |
-----------------------------------------------------------+----------------
Dear Boost developpers,
The waveidl sample from the wave lib does not use the included IDL lexer.
Instead it uses the default cpp lexer. This can be easily tested by
setting a breakpoint in the scan function in idl_re.cpp. The reason is
that it is explicitly set up like this in the lex_iterator constructor.
The #if 0 branch below is the original code, the #else branch is modified
to use the IDL lexer.
template <typename IteratorT>
lex_iterator(IteratorT const &first, IteratorT const &last,
typename TokenT::position_type const &pos,
boost::wave::language_support language)
: base_type(
functor_data_type(
unique_functor_type(),
#if 0
cpplexer::lex_input_interface_generator<TokenT>
::new_lexer(first, last, pos, language)
#else
boost::wave::idllexer::new_lexer_gen<
std::string::iterator>::new_lexer( first, last, pos,
language )
#endif
)
)
{}
Now if I do the above modification, the preprocessor stops after the first
include file with this warning:
"warning: last line of file ends without a newline"
Somehow the function which checks if there is a return from an include
always returns false.
Btw.: What I want to achieve is a preprocessor for Verilog-A, which is a
simplified variant of a C preprocessor with ` instaed of #. It should be
easy, but I cannot get it to work.
Thanks & best regards,
Michael
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/7822> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:11 UTC