Terence Parr
358a1025d2
tweaks per Sam's comments. Just pushing straight to master.
2014-06-10 11:28:43 -07:00
ericvergnaud
fa2ed459c6
Had lost some stuff
2014-06-07 00:57:13 +08:00
ericvergnaud
fd9d707d95
tests granularity
2014-06-07 00:52:39 +08:00
ericvergnaud
0692334c9f
unwanted format change
2014-06-07 00:13:38 +08:00
ericvergnaud
bf83ee42bc
Oops, removed some unwanted changes
2014-06-07 00:08:59 +08:00
ericvergnaud
00eb4f89ca
Merge branch 'Improved-tests-granularity' into Preliminary-enhancements-for-Python-target
2014-06-07 00:01:13 +08:00
ericvergnaud
5778570faf
warningw to be fixed separately
2014-06-06 23:54:52 +08:00
ericvergnaud
4545a8f5d0
resolved the Lexer listener/visitor issue by changing the tests grammar
...
using @members to @parser::members
2014-06-06 23:41:18 +08:00
ericvergnaud
33fd1804ff
Merge branch 'Preliminary-enhancements-for-Python-target' into Improved-tests-granularity
2014-06-06 23:08:27 +08:00
ericvergnaud
c46acf0031
cleanup after merge
2014-06-06 23:07:26 +08:00
ericvergnaud
f75e15258f
merged preliminary python enhancements
2014-06-06 23:02:50 +08:00
ericvergnaud
1592609e89
Improves the granularity of tests, thus helping narrow down differences
...
in behaviour between the reference Java target and other targets that
use the same test suite
2014-06-06 22:52:55 +08:00
ericvergnaud
ff67ae5d19
Merge branch 'master' of https://github.com/antlr/antlr4 into Preliminary-enhancements-for-Python-target
...
Terence's implementation
2014-06-06 19:47:47 +08:00
Terence Parr
36da0daad7
no longer passing Parser/Lexer masquerading as superClass option.
2014-06-05 19:22:09 -07:00
ericvergnaud
b8a91b9e3f
Preliminary changes for Python
2014-06-06 03:13:09 +08:00
Terence Parr
bc566605b1
Leave just one version spec in tool. Not looking externally anymore.
2014-06-04 17:23:47 -07:00
Terence Parr
cc36281ce2
new definition of context sensitivity required change in test code. Updated profiler per Sam's comments.
2014-06-03 22:04:02 -07:00
Terence Parr
8d17f43f57
Merge pull request #601 from sharwell/versioning-docs
...
Versioning updates and documentation
2014-06-03 21:39:11 -07:00
Sam Harwell
80125d661e
* Redefine checkVersion as version mismatch detection instead of a compatibility check
...
* Update notification behavior to notify callback listeners instead of throwing an exception
* Remove the distinction between regular and "extended" semantics
2014-06-03 18:31:52 -05:00
Sam Harwell
95596b4a52
Update ParserFactory.getLL1EBNFBlock to ensure it is correct even if additional ATN optimizations are implemented
2014-06-03 07:33:03 -05:00
Terence Parr
31a3b59576
Templates LL1PlusBlock and LL1StarBlock were not used. removed. added test for LL1OptionalBlock.
2014-06-03 07:33:00 -05:00
Sam Harwell
e4e1cb1845
Updated the documentation and improved the flexibility for future use of RuntimeMetaData.checkVersion
2014-06-02 23:06:58 -05:00
Terence Parr
742429a15d
make sure that previous tree node's start/stop token indexes are correct after left-recur elim.
2014-06-02 13:45:10 -05:00
Sam Harwell
e7a1d84197
Fix support for element options on semantic predicates in left recursive rules ( fixes #590 )
2014-06-01 22:33:43 -05:00
Sam Harwell
be16c71e56
Merge pull request #583 from sharwell/atn-profiler
...
Atn profiler
2014-06-01 22:30:39 -05:00
Terence Parr
68b186e77d
Add utility methods and track token indexes through the left recursive rule transformation to allow external tools to associate ATN states and transitions with original locations in the grammar source file
2014-06-01 22:30:33 -05:00
Terence Parr
e570489d33
Simplify common code in XPath tests
2014-06-01 22:29:35 -05:00
Terence Parr
fb49d7c6a2
initial profiler
2014-06-01 22:15:12 -05:00
Sam Harwell
46e1bad7b4
Simplify the GrammarAST constructors, and correct the token start/stop index not being set
2014-05-31 18:14:41 -05:00
Terence Parr
f3fcf5a712
Merge pull request #569 from parrt/runtime-tool-version-sync
...
add tool-template and generatedcode-runtime version compatibility check
2014-05-28 18:02:14 -07:00
Terence Parr
9e77e28bc1
should not be a default version lest all targets pass by default. make sure java target and tool move in lockstep. Fixes #572
2014-05-28 17:55:32 -07:00
Terence Parr
0b8a70a2a4
tweaks per Sam's comment. define default version so targets don't fail to compile.
2014-05-28 11:26:44 -07:00
Terence Parr
db0830e00d
To get static checking I converted the version template to a method and also moved the compatibility check into the target so that in the worst-case target developers can override the compatibility check per their needs. I have also decided to throw an exception for the Java target when the code generation and runtime library versions are incompatible. Change the tool message per Sam's request.
2014-05-28 11:14:00 -07:00
Sam Harwell
938a39c057
Qualify references to the ATN class to avoid symbol conflicts with tokens named ATN ( fixes #561 )
2014-05-24 16:49:38 -05:00
Sam Harwell
e0937a6322
Add regression test for #561 (token named ATN breaks reference to ATN.INVALID_ALT_NUMBER)
2014-05-24 13:14:08 -05:00
Terence Parr
813fefdbb7
Fixes #554
2014-05-24 12:13:31 -05:00
Terence Parr
4aec5aeac2
add basic code generation testing rig and 1st test.
2014-05-24 12:10:47 -05:00
Terence Parr
a3d4ba53a3
add tool-template and generatedcode-runtime version compatibility check. Target authors add a VERSION template and supply a RuntimeMetaData.checkVersion() method.
2014-05-19 17:25:01 -07:00
Sam Harwell
65b176a36d
Return predefined values instead of null for Grammar methods getTokenNames, getTokenDisplayNames, and getRuleNames
...
Improve consistency of Grammar methods for names of rules and tokens
2014-04-13 18:46:28 -05:00
Sam Harwell
7e2bf4a2d5
[maven-release-plugin] prepare for next development iteration
2014-04-06 21:19:40 -05:00
Sam Harwell
736a5f5905
[maven-release-plugin] prepare release 4.2.2
2014-04-06 21:18:12 -05:00
Sam Harwell
88c7d09c24
Add unit tests for grammars with multiple EOF transitions
2014-04-06 16:23:57 -05:00
Terence Parr
da9186ed63
Merge pull request #134 from parrt/eval-preds-when-delaying-errors
...
When delaying error reporting because prediction escapes the decision en...
2014-04-02 09:41:09 -07:00
Sam Harwell
ea4676b18a
adaptivePredict never returns -1; it could return ATN.INVALID_ALT_NUMBER
2014-04-01 21:26:48 -05:00
Sam Harwell
8c8d4d754e
Remove incorrectly generated call to adaptivePredict
...
This particular call to adaptivePredict did not correctly match the decision number to the preceding setState() call. In addition, since this code is generated only for a positive closure, the only possible alternative is the one that enters the loop; error handling is deferred to the alternative(s) within the body of the closure.
2014-04-01 21:26:47 -05:00
Terence Parr
69d4b423e1
When delaying error reporting because prediction escapes the decision entry rule, we should evaluate predicates to turn off any configurations that are invalid semantically. After that, we can collect the list of alternatives that are satisfied with the input thus far and then choose the minimum as before. Fixes #529
2014-04-01 16:49:30 -07:00
Sam Harwell
f34adc916a
Added Grammar.undefineRule to support undefining rules prior to AST construction
2014-03-29 16:13:36 -05:00
Sam Harwell
5a56cc1147
Documented Grammar.defineRule, and updated it to return true if the rule was added to the Grammar
2014-03-29 16:13:35 -05:00
Sam Harwell
2729f176b2
Add option TestPerformance.REPORT_SECOND_STAGE_RETRY
2014-03-29 13:12:35 -05:00
Sam Harwell
5be18445cd
[maven-release-plugin] prepare for next development iteration
2014-03-25 10:57:46 -05:00