{
public:
template <typename InputIterator, typename _Param>
- bool analyze(const InputIterator&, const _Param&) const
+ bool parse(const InputIterator&, const _Param&) const
{
return true;
}
{
public:
template <typename InputIterator, typename _Param>
- bool analyze(const InputIterator&, const _Param&) const
+ bool parse(const InputIterator&, const _Param&) const
{
return false;
}
/////////////////
template <typename InputIterator, typename _Param>
- bool analyze(InputIterator& it, const _Param& param) const
+ bool parse(InputIterator& it, const _Param& param) const
{
+ //memcmp
+
bool ret = (*it == data);
if ( ret )
it++;
/////////////////
template <typename InputIterator, typename _Param>
- bool analyze(InputIterator& it, const _Param& param) const
+ bool parse(InputIterator& it, const _Param& param) const
{
const T* p = data;
for(unsigned int i=length; i!=0; i--, p++, it++)
namespace lexical
{
//////////////////////////////////////////////////////////////////////////////////
-
- template <typename Lexer, typename InputIterator, typename Param>
- bool analyze(Lexer &lexer, InputIterator& it, Param& param = EmptyType())
- {
- return lexer.analyze(it, param);
- }
template <typename Lexer, typename InputIterator, typename Param>
bool parse(Lexer &lexer, InputIterator& it, Param& param = EmptyType())
{
- return lexer.analyze(it, param);
+ return lexer.parse(it, param);
}
//////////////////////////////////////////////////////////////////////////////////