Ejemplo n.º 1
0
void Scanner::nextToken()
{
    nextTokenInternal();
    while (ftoken == CodeTypes::tStartComment)
    {
        // Comment ends with an end of line char
        while ((fch != LF) && (fch != EOFCHAR))
            fch = getCharFromBuffer();
        //while ((fch != CR) && (fch != EOFCHAR))
        //      fch = getCharFromBuffer();
        //while ((fch == LF) && (fch !=  EOFCHAR))
        //      fch = getCharFromBuffer();
        while (fch == LF)
        {
            yylineno++;
            //while (fch == LF)
            //      nextChar();  // Dump the linefeed
            fch = nextChar();
        }
        nextTokenInternal(); // get the real next token
    }
}
Ejemplo n.º 2
0
inline Parser::Token Parser::nextToken()
{
    Token token = nextTokenInternal();
    m_lastTokenType = token.type;
    return token;
}
Ejemplo n.º 3
0
Token Parser::nextToken()
{
    Token toRet = nextTokenInternal();
    m_lastTokenType = toRet.type;
    return toRet;
}