Commit Graph

1664 Commits

Author SHA1 Message Date
Sam Harwell 05363cd5ef Fix tests in TestSemPredEvalLexer 2012-10-31 21:52:51 -05:00
Sam Harwell d748271816 Remove getSpeculativeText since getText works again 2012-10-31 21:52:50 -05:00
Sam Harwell a4ba562210 LexerATNSimulator adjusts the input position during a speculative predicate evaluation to accurately reflect the state where the predicate appears in the grammar 2012-10-31 21:52:41 -05:00
Terence Parr a0dd1b4018 Merge branch 'test-performance-features' of git://github.com/sharwell/antlr4 2012-10-31 17:39:14 -07:00
Terence Parr fca4710004 alter tests 2012-10-31 12:46:11 -07:00
Sam Harwell bd121facef Add the COMPUTE_CHECKSUM option to TestPerformance 2012-10-30 17:49:51 -05:00
Sam Harwell a96e7a2e70 Added many new features and flags to TestPerformance 2012-10-30 17:10:42 -05:00
Sam Harwell 5924d3f935 Corrections to Java grammars used by TestPerformance 2012-10-30 16:39:12 -05:00
Sam Harwell efa9ea7811 Simplify LexerATNSimulator to reduce duplicate code (duplicate instruction executions and duplicated code blocks) 2012-10-30 09:24:03 -05:00
Sam Harwell bad2751a2c Add edge suppression for lexer start state - required for left edge predicates 2012-10-30 08:46:42 -05:00
Sam Harwell 1e5cfb4a1e Add unit test for behavior of lexer with input-position-sensitive predicates 2012-10-30 08:46:02 -05:00
Sam Harwell 13e940b1db Fix error messages not shown if invoke(...) throws InvocationTargetException 2012-10-30 08:35:00 -05:00
Sam Harwell 6db106855f Fix Java test grammars 2012-10-30 08:34:04 -05:00
Terence Parr 72c1fc8f6d tweaks on comments 2012-10-29 12:47:09 -07:00
Sam Harwell f554a2ed4f Eliminate debug and dfa_debug overhead in LexerATNSimulator by making them compile-time constants 2012-10-29 13:32:02 -05:00
Sam Harwell 7bf50c8263 LexerATNSimulator uses explicit lower bound for DFAState.edges array 2012-10-29 13:32:02 -05:00
Sam Harwell 1269ce8d4e Remove 2 field accesses per input character in LexerATNSimulator 2012-10-29 13:32:01 -05:00
Sam Harwell 0deadc688a Remove unnecessary array indexing operation in execDFA 2012-10-29 13:32:00 -05:00
Sam Harwell c34f0d6945 Remove duplicate array bounds check 2012-10-29 13:31:59 -05:00
Sam Harwell afed3ac349 Remove unnecessary null checks 2012-10-29 13:31:58 -05:00
Sam Harwell d17f919123 Updated NotNull annotations in LexerATNSimulator 2012-10-29 13:31:57 -05:00
Sam Harwell 5dace66921 DFAState.configs cannot be null 2012-10-29 13:31:57 -05:00
Sam Harwell 9873230f55 Correctness for lexer DFA with semantic predicate evaluation only requires suppressing single edges from the DFA 2012-10-29 13:31:56 -05:00
Terence Parr a115490d5e Merge branch 'warnings-as-errors' of git://github.com/sharwell/antlr4 2012-10-29 11:27:46 -07:00
Sam Harwell ee64790739 In lexer, configs which never reached a non-greedy decision state are fully greedy (unordered alternatives, longest match) 2012-10-29 13:14:51 -05:00
Sam Harwell 871db85ecb Add field DecisionState.nonGreedy, computed in tool and serialized as one bit in the state type field 2012-10-29 13:14:50 -05:00
Sam Harwell 94d3de748e Unit tests for ('a' | 'ab') in lexers 2012-10-29 13:14:34 -05:00
Sam Harwell 37425b70d0 Subtle whitespace changes in Java.stg reduces size of generated code without hurting legibility 2012-10-28 17:16:37 -05:00
Sam Harwell 25c5802ba4 Use suggested v4 syntax in unit tests 2012-10-28 17:11:36 -05:00
Sam Harwell 55c1652fcd Unit tests for parser greedy/non-greedy 2012-10-28 17:11:02 -05:00
Sam Harwell f46d06aec6 Fix testA, testB, and testE in TestSymbolIssues 2012-10-28 16:59:40 -05:00
Sam Harwell 59b3a05a05 warning 108 for "token name foo is already defined" 2012-10-28 16:58:49 -05:00
Sam Harwell b879d508ee Fix generated alt numbers for non-greedy quantifiers 2012-10-28 16:45:45 -05:00
Sam Harwell 4d2df41cdb Format and document the 'state' template to improve readability 2012-10-28 16:42:23 -05:00
Sam Harwell 85e2802d66 Use a group file instead of loose templates (easier to understand the interactions) 2012-10-28 11:24:08 -05:00
Sam Harwell 4adef1e455 Output from -atn flag shows the order of outgoing edges from decision states. 2012-10-28 11:17:39 -05:00
Sam Harwell 950f588ac0 Fix implementations: TokenStream interface says getText method returns non-null 2012-10-28 10:04:34 -05:00
Terence Parr bd0868c305 Merge branch 'action-init' of github.com:sharwell/antlr4 2012-10-26 17:37:45 -07:00
Sam Harwell f4a3d6f3a8 Move initialization of finallyAction to fillNamedActions - factory cannot provide context information for the Action construction before the constructor completes 2012-10-26 15:46:22 -05:00
Sam Harwell e89807e350 Add non-greedy quantifier syntax: greedy forms are *, +, ?, and non-greedy forms are *?, +?, ??
"greedy" is no longer a block option, and all loops are greedy unless the non-greedy quantifier is explicitly used
Add warning 131 when .* is used, because they probably intended to use the non-greedy form .*?
2012-10-26 15:40:05 -05:00
Sam Harwell 8494007025 Add regression test for antlr/antlr4#26 (an exception upon simple rule with double recursion in an alternative) 2012-10-25 21:45:03 -05:00
Sam Harwell 5a5f56e91c Add unit test for antlr/antlr4#25 (currently fails because the underlying problem hasn't been fixed) 2012-10-25 21:35:19 -05:00
Sam Harwell 73c6ce5c7e CIRCULAR_DEPENDENCY error number changed to 200 to make room for expanding the set of grammar errors 2012-10-25 21:34:24 -05:00
Sam Harwell bfc395d23b Add regression test for antlr/antlr4#19 (getter for context is not a list when it should be) 2012-10-25 18:03:03 -05:00
Sam Harwell 514a1500ea Add regression test for antlr/antlr4#6 (NullPointerException in getMissingSymbol) 2012-10-25 17:42:09 -05:00
Terence Parr d5341b55af Merge branch 'encapsulation' of git://github.com/sharwell/antlr4 2012-10-24 12:59:46 -07:00
Terence Parr b89445e861 Merge branch 'maven-update' of git://github.com/sharwell/antlr4 2012-10-24 12:58:52 -07:00
Terence Parr cb0f5c0e51 Merge branch 'parsecancellationexception' of git://github.com/sharwell/antlr4 2012-10-24 12:58:26 -07:00
Terence Parr 31c9fc33f1 Merge branch 'ordered-configs' of git://github.com/sharwell/antlr4 2012-10-24 10:51:56 -07:00
Terence Parr 4f918f75bc Merge branch 'get-reachable-target' of git://github.com/sharwell/antlr4 2012-10-24 10:41:46 -07:00