|
ANTLR Support Libraries 2.7.1+
|
#include <LLkParser.hpp>


Protected Attributes | |
| int | k |
| the lookahead this LL(k) parser is using. | |
Protected Attributes inherited from Parser | |
| ParserSharedInputState | inputState |
| ASTFactory * | astFactory |
| AST support code; parser and treeparser delegate to this object. | |
| int | traceDepth |
Private Member Functions | |
| void | trace (const char *ee, const char *rname) |
Additional Inherited Members | |
Protected Member Functions inherited from Parser | |
| Parser (TokenBuffer &input) | |
| Parser (TokenBuffer *input) | |
| Parser (const ParserSharedInputState &state) | |
An LL(k) parser.
| LLkParser::LLkParser | ( | const ParserSharedInputState & | state, |
| int | k_ ) |
An LL(k) parser.
| LLkParser::LLkParser | ( | TokenBuffer & | tokenBuf, |
| int | k_ ) |
| LLkParser::LLkParser | ( | TokenStream & | lexer, |
| int | k_ ) |
Consume another token from the input stream. Can only write sequentially! If you need 3 tokens ahead, you must consume() 3 times.
Note that it is possible to overwrite tokens that have not been matched. For example, calling consume() 3 times when k=2, means that the first token consumed will be overwritten with the 3rd.
Implements Parser.
Return the i-th token of lookahead.
Implements Parser.
|
protected |
the lookahead this LL(k) parser is using.