pANTLR3_BASE_RECOGNIZER Base Recognizer Implementation
[API Implementation functions]

Collaboration diagram for pANTLR3_BASE_RECOGNIZER Base Recognizer Implementation:

Detailed Description

The base recognizer interface is implemented by all higher level recognizers such as pANTLR3_PARSER and provides methods common to all recognizers.


Functions

static ANTLR3_BOOLEAN alreadyParsedRule (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_MARKER ruleIndex)
 Has this rule already parsed input at the current index in the input stream? Return ANTLR3_TRUE if we have and ANTLR3_FALSE if we have not.
ANTLR3_API pANTLR3_BASE_RECOGNIZER antlr3BaseRecognizerNew (ANTLR3_UINT32 type, ANTLR3_UINT32 sizeHint, pANTLR3_RECOGNIZER_SHARED_STATE state)
ANTLR3_API void antlr3MTExceptionNew (pANTLR3_BASE_RECOGNIZER recognizer)
 Creates a new Mismatched Token Exception and inserts in the recognizer exception stack.
ANTLR3_API void antlr3RecognitionExceptionNew (pANTLR3_BASE_RECOGNIZER recognizer)
static void beginBacktrack (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_UINT32 level)
static void beginResync (pANTLR3_BASE_RECOGNIZER recognizer)
static pANTLR3_BITSET combineFollows (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_BOOLEAN exact)
 Compute the current followset for the input stream.
static pANTLR3_BITSET computeCSRuleFollow (pANTLR3_BASE_RECOGNIZER recognizer)
 Compute the context-sensitive FOLLOW set for current rule.
static pANTLR3_BITSET computeErrorRecoverySet (pANTLR3_BASE_RECOGNIZER recognizer)
 Compute the error recovery set for the current rule.
static void consumeUntil (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_UINT32 tokenType)
 Eat tokens from the input stream until we get one of JUST the right type.
static void consumeUntilSet (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_BITSET set)
 Eat tokens from the input stream until we find one that belongs to the supplied set.
static void displayRecognitionError (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_UINT8 *tokenNames)
 Standard/Example error display method.
static void endBacktrack (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_UINT32 level, ANTLR3_BOOLEAN successful)
static void endResync (pANTLR3_BASE_RECOGNIZER recognizer)
static void freeBR (pANTLR3_BASE_RECOGNIZER recognizer)
static void ANTLR3_CDECL freeIntTrie (void *trie)
static void ANTLR3_CDECL freeList (void *list)
static void * getCurrentInputSymbol (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_INT_STREAM istream)
static void * getMissingSymbol (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_INT_STREAM istream, pANTLR3_EXCEPTION e, ANTLR3_UINT32 expectedTokenType, pANTLR3_BITSET_LIST follow)
static ANTLR3_UINT32 getNumberOfSyntaxErrors (pANTLR3_BASE_RECOGNIZER recognizer)
 Return how many syntax errors were detected by this recognizer.
static pANTLR3_STACK getRuleInvocationStack (pANTLR3_BASE_RECOGNIZER recognizer)
 Return the rule invocation stack (how we got here in the parse.
static pANTLR3_STACK getRuleInvocationStackNamed (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_UINT8 name)
static ANTLR3_MARKER getRuleMemoization (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_INTKEY ruleIndex, ANTLR3_MARKER ruleParseStart)
 Pointer to a function to return whether the rule has parsed input starting at the supplied start index before.
static void * match (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_UINT32 ttype, pANTLR3_BITSET_LIST follow)
 Match current input symbol against ttype.
static void matchAny (pANTLR3_BASE_RECOGNIZER recognizer)
 Consumes the next token, whatever it is, and resets the recognizer state so that it is not in error.
static void memoize (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_MARKER ruleIndex, ANTLR3_MARKER ruleParseStart)
 Record whether or not this rule parsed the input at this position successfully.
static void mismatch (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_UINT32 ttype, pANTLR3_BITSET_LIST follow)
 Factor out what to do upon token mismatch so tree parsers can behave differently.
static ANTLR3_BOOLEAN mismatchIsMissingToken (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_INT_STREAM is, pANTLR3_BITSET_LIST follow)
static ANTLR3_BOOLEAN mismatchIsUnwantedToken (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_INT_STREAM is, ANTLR3_UINT32 ttype)
static void recover (pANTLR3_BASE_RECOGNIZER recognizer)
 Recover from an error found on the input stream.
static ANTLR3_BOOLEAN recoverFromMismatchedElement (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_BITSET_LIST followBits)
 This code is factored out from mismatched token and mismatched set recovery.
static void * recoverFromMismatchedSet (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_BITSET_LIST follow)
static void * recoverFromMismatchedToken (pANTLR3_BASE_RECOGNIZER recognizer, ANTLR3_UINT32 ttype, pANTLR3_BITSET_LIST follow)
 Attempt to recover from a single missing or extra token.
static void reportError (pANTLR3_BASE_RECOGNIZER recognizer)
 Report a recognition problem.
static void reset (pANTLR3_BASE_RECOGNIZER recognizer)
static ANTLR3_BOOLEAN synpred (pANTLR3_BASE_RECOGNIZER recognizer, void *ctx, void(*predicate)(void *ctx))
 A syntactic predicate.
static pANTLR3_HASH_TABLE toStrings (pANTLR3_BASE_RECOGNIZER recognizer, pANTLR3_HASH_TABLE tokens)
 Convenience method for template rewrites - NYI.


Function Documentation

static ANTLR3_BOOLEAN alreadyParsedRule ( pANTLR3_BASE_RECOGNIZER  recognizer,
ANTLR3_MARKER  ruleIndex 
) [static]

ANTLR3_API pANTLR3_BASE_RECOGNIZER antlr3BaseRecognizerNew ( ANTLR3_UINT32  type,
ANTLR3_UINT32  sizeHint,
pANTLR3_RECOGNIZER_SHARED_STATE  state 
)

References alreadyParsedRule(), ANTLR3_BASE_RECOGNIZER_struct::alreadyParsedRule, ANTLR3_CALLOC, ANTLR3_FALSE, ANTLR3_FREE, ANTLR3_MALLOC, antlr3MTExceptionNew(), antlr3VectorNew(), ANTLR3_RECOGNIZER_SHARED_STATE_struct::backtracking, beginBacktrack(), ANTLR3_BASE_RECOGNIZER_struct::beginBacktrack, beginResync(), ANTLR3_BASE_RECOGNIZER_struct::beginResync, combineFollows(), ANTLR3_BASE_RECOGNIZER_struct::combineFollows, computeCSRuleFollow(), ANTLR3_BASE_RECOGNIZER_struct::computeCSRuleFollow, computeErrorRecoverySet(), ANTLR3_BASE_RECOGNIZER_struct::computeErrorRecoverySet, consumeUntil(), ANTLR3_BASE_RECOGNIZER_struct::consumeUntil, consumeUntilSet(), ANTLR3_BASE_RECOGNIZER_struct::consumeUntilSet, ANTLR3_BASE_RECOGNIZER_struct::debugger, displayRecognitionError(), ANTLR3_BASE_RECOGNIZER_struct::displayRecognitionError, endBacktrack(), ANTLR3_BASE_RECOGNIZER_struct::endBacktrack, endResync(), ANTLR3_BASE_RECOGNIZER_struct::endResync, ANTLR3_RECOGNIZER_SHARED_STATE_struct::errorCount, ANTLR3_RECOGNIZER_SHARED_STATE_struct::errorRecovery, ANTLR3_BASE_RECOGNIZER_struct::exConstruct, ANTLR3_RECOGNIZER_SHARED_STATE_struct::failed, ANTLR3_RECOGNIZER_SHARED_STATE_struct::following, ANTLR3_BASE_RECOGNIZER_struct::free, freeBR(), getCurrentInputSymbol(), ANTLR3_BASE_RECOGNIZER_struct::getCurrentInputSymbol, getMissingSymbol(), ANTLR3_BASE_RECOGNIZER_struct::getMissingSymbol, getNumberOfSyntaxErrors(), ANTLR3_BASE_RECOGNIZER_struct::getNumberOfSyntaxErrors, getRuleInvocationStack(), ANTLR3_BASE_RECOGNIZER_struct::getRuleInvocationStack, getRuleInvocationStackNamed(), ANTLR3_BASE_RECOGNIZER_struct::getRuleInvocationStackNamed, getRuleMemoization(), ANTLR3_BASE_RECOGNIZER_struct::getRuleMemoization, ANTLR3_RECOGNIZER_SHARED_STATE_struct::lastErrorIndex, match(), ANTLR3_BASE_RECOGNIZER_struct::match, matchAny(), ANTLR3_BASE_RECOGNIZER_struct::matchAny, memoize(), ANTLR3_BASE_RECOGNIZER_struct::memoize, mismatch(), ANTLR3_BASE_RECOGNIZER_struct::mismatch, mismatchIsMissingToken(), ANTLR3_BASE_RECOGNIZER_struct::mismatchIsMissingToken, mismatchIsUnwantedToken(), ANTLR3_BASE_RECOGNIZER_struct::mismatchIsUnwantedToken, recover(), ANTLR3_BASE_RECOGNIZER_struct::recover, recoverFromMismatchedElement(), recoverFromMismatchedSet(), ANTLR3_BASE_RECOGNIZER_struct::recoverFromMismatchedSet, recoverFromMismatchedToken(), ANTLR3_BASE_RECOGNIZER_struct::recoverFromMismatchedToken, reportError(), ANTLR3_BASE_RECOGNIZER_struct::reportError, reset(), ANTLR3_BASE_RECOGNIZER_struct::reset, ANTLR3_RECOGNIZER_SHARED_STATE_struct::rStreams, ANTLR3_RECOGNIZER_SHARED_STATE_struct::ruleMemo, ANTLR3_RECOGNIZER_SHARED_STATE_struct::sizeHint, ANTLR3_BASE_RECOGNIZER_struct::state, synpred(), ANTLR3_BASE_RECOGNIZER_struct::synpred, ANTLR3_RECOGNIZER_SHARED_STATE_struct::tokenNames, ANTLR3_RECOGNIZER_SHARED_STATE_struct::tokSource, toStrings(), ANTLR3_BASE_RECOGNIZER_struct::toStrings, and ANTLR3_BASE_RECOGNIZER_struct::type.

Referenced by antlr3LexerNew(), antlr3ParserNew(), and antlr3TreeParserNewStream().

Here is the call graph for this function:

Here is the caller graph for this function:

ANTLR3_API void antlr3MTExceptionNew ( pANTLR3_BASE_RECOGNIZER  recognizer  ) 

Creates a new Mismatched Token Exception and inserts in the recognizer exception stack.

Parameters:
recognizer Context pointer for this recognizer

References ANTLR3_MISMATCHED_EX_NAME, ANTLR3_MISMATCHED_TOKEN_EXCEPTION, antlr3RecognitionExceptionNew(), ANTLR3_RECOGNIZER_SHARED_STATE_struct::exception, ANTLR3_EXCEPTION_struct::name, ANTLR3_BASE_RECOGNIZER_struct::state, and ANTLR3_EXCEPTION_struct::type.

Referenced by antlr3BaseRecognizerNew(), antlr3ParserNew(), and mismatch().

Here is the call graph for this function:

Here is the caller graph for this function:

ANTLR3_API void antlr3RecognitionExceptionNew ( pANTLR3_BASE_RECOGNIZER  recognizer  ) 

References ANTLR3_INT_STREAM_struct::_LA, ANTLR3_TREE_NODE_STREAM_struct::_LT, ANTLR3_TOKEN_STREAM_struct::_LT, ANTLR3_CHARSTREAM, ANTLR3_COMMONTREENODE, ANTLR3_FALSE, ANTLR3_FPRINTF, ANTLR3_INPUT_MASK, ANTLR3_RECOGNITION_EX_NAME, ANTLR3_RECOGNITION_EXCEPTION, ANTLR3_TOKEN_EOF, ANTLR3_TOKENSTREAM, ANTLR3_TRUE, ANTLR3_TYPE_LEXER, ANTLR3_TYPE_PARSER, ANTLR3_TYPE_TREE_PARSER, antlr3ExceptionNew(), ANTLR3_EXCEPTION_struct::c, ANTLR3_EXCEPTION_struct::charPositionInLine, ANTLR3_TREE_PARSER_struct::ctnstream, ANTLR3_RECOGNIZER_SHARED_STATE_struct::error, ANTLR3_RECOGNIZER_SHARED_STATE_struct::exception, ANTLR3_STRING_struct::factory, ANTLR3_INPUT_STREAM_struct::fileName, getCharPositionInLine(), ANTLR3_INPUT_STREAM_struct::getCharPositionInLine, getLine(), ANTLR3_INPUT_STREAM_struct::getLine, ANTLR3_INT_STREAM_struct::index, ANTLR3_EXCEPTION_struct::index, ANTLR3_EXCEPTION_struct::input, ANTLR3_COMMON_TOKEN_struct::input, ANTLR3_LEXER_struct::input, ANTLR3_TREE_NODE_STREAM_struct::istream, ANTLR3_TOKEN_STREAM_struct::istream, ANTLR3_INPUT_STREAM_struct::istream, ANTLR3_EXCEPTION_struct::line, ANTLR3_EXCEPTION_struct::message, ANTLR3_STRING_FACTORY_struct::newStr8, ANTLR3_EXCEPTION_struct::nextException, ANTLR3_BASE_RECOGNIZER_struct::state, ANTLR3_EXCEPTION_struct::streamName, ANTLR3_TOKEN_STREAM_struct::super, ANTLR3_BASE_RECOGNIZER_struct::super, ANTLR3_COMMON_TOKEN_struct::text, ANTLR3_COMMON_TREE_NODE_STREAM_struct::tnstream, ANTLR3_COMMON_TREE_struct::token, ANTLR3_EXCEPTION_struct::token, ANTLR3_COMMON_TOKEN_STREAM_struct::tstream, ANTLR3_PARSER_struct::tstream, ANTLR3_INT_STREAM_struct::type, and ANTLR3_BASE_RECOGNIZER_struct::type.

Referenced by antlr3MTExceptionNew(), antlr3MTNExceptionNew(), mismatch(), recoverFromMismatchedToken(), and setCharStream().

Here is the call graph for this function:

Here is the caller graph for this function:

static void beginBacktrack ( pANTLR3_BASE_RECOGNIZER  recognizer,
ANTLR3_UINT32  level 
) [static]

static void beginResync ( pANTLR3_BASE_RECOGNIZER  recognizer  )  [static]

static pANTLR3_BITSET combineFollows ( pANTLR3_BASE_RECOGNIZER  recognizer,
ANTLR3_BOOLEAN  exact 
) [static]

static pANTLR3_BITSET computeCSRuleFollow ( pANTLR3_BASE_RECOGNIZER  recognizer  )  [static]

Compute the context-sensitive FOLLOW set for current rule.

Documentation below is from the Java runtime.

This is the set of token types that can follow a specific rule reference given a specific call chain. You get the set of viable tokens that can possibly come next (look ahead depth 1) given the current call chain. Contrast this with the definition of plain FOLLOW for rule r:

FOLLOW(r)={x | S=>*alpha r beta in G and x in FIRST(beta)}

where x in T* and alpha, beta in V*; T is set of terminals and V is the set of terminals and non terminals. In other words, FOLLOW(r) is the set of all tokens that can possibly follow references to r in///any* sentential form (context). At runtime, however, we know precisely which context applies as we have the call chain. We may compute the exact (rather than covering superset) set of following tokens.

For example, consider grammar:

stat : ID '=' expr ';' // FOLLOW(stat)=={EOF} | "return" expr '.' ; expr : atom ('+' atom)* ; // FOLLOW(expr)=={';','.',')'} atom : INT // FOLLOW(atom)=={'+',')',';','.'} | '(' expr ')' ;

The FOLLOW sets are all inclusive whereas context-sensitive FOLLOW sets are precisely what could follow a rule reference. For input input "i=(3);", here is the derivation:

stat => ID '=' expr ';' => ID '=' atom ('+' atom)* ';' => ID '=' '(' expr ')' ('+' atom)* ';' => ID '=' '(' atom ')' ('+' atom)* ';' => ID '=' '(' INT ')' ('+' atom)* ';' => ID '=' '(' INT ')' ';'

At the "3" token, you'd have a call chain of

stat -> expr -> atom -> expr -> atom

What can follow that specific nested ref to atom? Exactly ')' as you can see by looking at the derivation of this specific input. Contrast this with the FOLLOW(atom)={'+',')',';','.'}.

You want the exact viable token set when recovering from a token mismatch. Upon token mismatch, if LA(1) is member of the viable next token set, then you know there is most likely a missing token in the input stream. "Insert" one by just not throwing an exception.

References ANTLR3_FALSE, and ANTLR3_BASE_RECOGNIZER_struct::combineFollows.

Referenced by antlr3BaseRecognizerNew().

Here is the caller graph for this function:

static pANTLR3_BITSET computeErrorRecoverySet ( pANTLR3_BASE_RECOGNIZER  recognizer  )  [static]

Compute the error recovery set for the current rule.

Documentation below is from the Java implementation.

During rule invocation, the parser pushes the set of tokens that can follow that rule reference on the stack; this amounts to computing FIRST of what follows the rule reference in the enclosing rule. This local follow set only includes tokens from within the rule; i.e., the FIRST computation done by ANTLR stops at the end of a rule. EXAMPLE When you find a "no viable alt exception", the input is not consistent with any of the alternatives for rule r. The best thing to do is to consume tokens until you see something that can legally follow a call to r *or* any rule that called r. You don't want the exact set of viable next tokens because the input might just be missing a token--you might consume the rest of the input looking for one of the missing tokens.

Consider grammar:

a : '[' b ']' | '(' b ')' ; b : c '^' INT ; c : ID | INT ;

At each rule invocation, the set of tokens that could follow that rule is pushed on a stack. Here are the various "local" follow sets:

FOLLOW(b1_in_a) = FIRST(']') = ']' FOLLOW(b2_in_a) = FIRST(')') = ')' FOLLOW(c_in_b) = FIRST('^') = '^'

Upon erroneous input "[]", the call chain is

a -> b -> c

and, hence, the follow context stack is:

depth local follow set after call to rule 0 <EOF> a (from main()) 1 ']' b 3 '^' c

Notice that ')' is not included, because b would have to have been called from a different context in rule a for ')' to be included.

For error recovery, we cannot consider FOLLOW(c) (context-sensitive or otherwise). We need the combined set of all context-sensitive FOLLOW sets--the set of all tokens that could follow any reference in the call chain. We need to resync to one of those tokens. Note that FOLLOW(c)='^' and if we resync'd to that token, we'd consume until EOF. We need to sync to context-sensitive FOLLOWs for a, b, and c: {']','^'}. In this case, for input "[]", LA(1) is in this set so we would not consume anything and after printing an error rule c would return normally. It would not find the required '^' though. At this point, it gets a mismatched token error and throws an exception (since LA(1) is not in the viable following token set). The rule exception handler tries to recover, but finds the same recovery set and doesn't consume anything. Rule b exits normally returning to rule a. Now it finds the ']' (and with the successful match exits errorRecovery mode).

So, you can see that the parser walks up call chain looking for the token that was a member of the recovery set.

Errors are not generated in errorRecovery mode.

ANTLR's error recovery mechanism is based upon original ideas:

"Algorithms + Data Structures = Programs" by Niklaus Wirth

and

"A note on error recovery in recursive descent parsers": http://portal.acm.org/citation.cfm?id=947902.947905

Later, Josef Grosch had some good ideas:

"Efficient and Comfortable Error Recovery in Recursive Descent Parsers": ftp://www.cocolab.com/products/cocktail/doca4.ps/ell.ps.zip

Like Grosch I implemented local FOLLOW sets that are combined at run-time upon error to avoid overhead during parsing.

References ANTLR3_FALSE, and ANTLR3_BASE_RECOGNIZER_struct::combineFollows.

Referenced by antlr3BaseRecognizerNew().

Here is the caller graph for this function:

static void consumeUntil ( pANTLR3_BASE_RECOGNIZER  recognizer,
ANTLR3_UINT32  tokenType 
) [static]

static void consumeUntilSet ( pANTLR3_BASE_RECOGNIZER  recognizer,
pANTLR3_BITSET  set 
) [static]

static void displayRecognitionError ( pANTLR3_BASE_RECOGNIZER  recognizer,
pANTLR3_UINT8 tokenNames 
) [static]

Standard/Example error display method.

No generic error message display funciton coudl possibly do everything correctly for all possible parsers. Hence you are provided with this example routine, which you should override in your parser/tree parser to do as you will.

Here we depart somewhat from the Java runtime as that has now split up a lot of the error display routines into spearate units. However, ther is little advantage to this in the C version as you will probably implement all such routines as a separate translation unit, rather than install them all as pointers to functions in the base recognizer.

References ANTLR3_EARLY_EXIT_EXCEPTION, ANTLR3_FPRINTF, ANTLR3_MISMATCHED_SET_EXCEPTION, ANTLR3_MISMATCHED_TOKEN_EXCEPTION, ANTLR3_MISSING_TOKEN_EXCEPTION, ANTLR3_NO_VIABLE_ALT_EXCEPTION, ANTLR3_RECOGNITION_EXCEPTION, ANTLR3_TOKEN_EOF, ANTLR3_TYPE_PARSER, ANTLR3_TYPE_TREE_PARSER, ANTLR3_UNWANTED_TOKEN_EXCEPTION, antlr3BitsetLoad(), ANTLR3_EXCEPTION_struct::charPositionInLine, ANTLR3_STRING_struct::chars, ANTLR3_TREE_PARSER_struct::ctnstream, ANTLR3_RECOGNIZER_SHARED_STATE_struct::exception, ANTLR3_EXCEPTION_struct::expecting, ANTLR3_EXCEPTION_struct::expectingSet, ANTLR3_BASE_TREE_struct::getCharPositionInLine, ANTLR3_BASE_TREE_struct::getToken, ANTLR3_TREE_NODE_STREAM_struct::istream, ANTLR3_TOKEN_STREAM_struct::istream, ANTLR3_EXCEPTION_struct::line, ANTLR3_EXCEPTION_struct::message, ANTLR3_BITSET_struct::numBits, ANTLR3_BITSET_struct::size, size(), ANTLR3_BASE_RECOGNIZER_struct::state, ANTLR3_EXCEPTION_struct::streamName, ANTLR3_BASE_TREE_struct::super, ANTLR3_BASE_RECOGNIZER_struct::super, ANTLR3_COMMON_TREE_NODE_STREAM_struct::tnstream, ANTLR3_STRING_struct::to8, ANTLR3_EXCEPTION_struct::token, ANTLR3_COMMON_TOKEN_struct::toString, ANTLR3_BASE_TREE_struct::toStringTree, ANTLR3_PARSER_struct::tstream, ANTLR3_COMMON_TOKEN_struct::type, ANTLR3_BASE_RECOGNIZER_struct::type, and ANTLR3_EXCEPTION_struct::type.

Referenced by antlr3BaseRecognizerNew(), and antlr3LexerNew().

Here is the call graph for this function:

Here is the caller graph for this function:

static void endBacktrack ( pANTLR3_BASE_RECOGNIZER  recognizer,
ANTLR3_UINT32  level,
ANTLR3_BOOLEAN  successful 
) [static]

static void endResync ( pANTLR3_BASE_RECOGNIZER  recognizer  )  [static]

static void freeBR ( pANTLR3_BASE_RECOGNIZER  recognizer  )  [static]

static void ANTLR3_CDECL freeIntTrie ( void *  trie  )  [static]

Referenced by getRuleMemoization().

Here is the caller graph for this function:

static void ANTLR3_CDECL freeList ( void *  list  )  [static]

static void * getCurrentInputSymbol ( pANTLR3_BASE_RECOGNIZER  recognizer,
pANTLR3_INT_STREAM  istream 
) [static]

References ANTLR3_INT_STREAM_struct::super.

Referenced by antlr3BaseRecognizerNew(), antlr3LexerNew(), and antlr3TreeParserNewStream().

Here is the caller graph for this function: