summaryrefslogtreecommitdiff
path: root/src/parser/antlr_input.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/parser/antlr_input.cpp')
-rw-r--r--src/parser/antlr_input.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/parser/antlr_input.cpp b/src/parser/antlr_input.cpp
index b46e22853..b8caf5ded 100644
--- a/src/parser/antlr_input.cpp
+++ b/src/parser/antlr_input.cpp
@@ -134,8 +134,13 @@ void AntlrInput::setParser(pANTLR3_PARSER pParser) {
// it would have to be declared separately in every input's grammar and we'd have to
// pass it in as an address anyway.
d_parser->super = getParserState();
+// d_parser->rec->match = &match;
d_parser->rec->reportError = &reportError;
- d_parser->rec->recoverFromMismatchedToken = &recoverFromMismatchedToken;
+ /* Don't try to recover from a parse error. */
+ // [chris 4/5/2010] Not clear on why this cast is necessary, but I get an error if I remove it.
+ d_parser->rec->recoverFromMismatchedToken =
+ (void* (*)(ANTLR3_BASE_RECOGNIZER_struct*, ANTLR3_UINT32, ANTLR3_BITSET_LIST_struct*))
+ d_parser->rec->mismatch;
}
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback