sharwell
46d5458617
Fix handling of alts with some configs predicated and some configs unpredicated (should be treated as always true)
2012-02-09 01:11:09 -06:00
sharwell
9c554a002b
Add LexerATNSimulator.copyState (allows copying state information from another simulator instance)
2012-02-09 00:15:30 -06:00
sharwell
40a8759276
Add LexerATNSimulator.getTraceStream
2012-02-09 00:14:37 -06:00
sharwell
3b4ae2a742
Use trivial implementation of mark/release for BufferedTokenStream
2012-02-08 18:58:57 -06:00
sharwell
f43f9f2218
Override CommonTokenStream.reset() to make sure the stream is left on an on-channel token
2012-02-08 18:58:19 -06:00
sharwell
a34fd6330b
Use isEmpty() instead of size()==0
2012-02-08 18:57:32 -06:00
sharwell
a9e44f3aab
Use isEmpty() instead of size()==0, use StringBuilder instead of StringBuffer, use chained append() calls instead of string concatenation, add @Override annotations
2012-02-08 18:57:05 -06:00
sharwell
d181b230dc
Specify generic type parameter
2012-02-08 18:55:57 -06:00
sharwell
64203312ac
Improved SemanticContext.hashCode(), add @Override annotations
2012-02-08 18:54:40 -06:00
sharwell
773e9e1c7e
Add generic type argument
2012-02-08 18:12:01 -06:00
sharwell
dcdfac4bcd
Improved implementation of equals() and hashCode() for ATNConfig
2012-02-08 18:09:32 -06:00
sharwell
64210f4b72
Add @NotNull annotations, make ATNConfig.semanticContext field final
2012-02-08 17:21:09 -06:00
sharwell
71e0c66477
Rename NUM_EDGES to MAX_DFA_EDGE, reduce max value to 127
2012-02-08 17:15:34 -06:00
sharwell
2249135c21
Specify generic type parameters
2012-02-08 17:12:22 -06:00
sharwell
1df70924f5
Use ATNConfigSet instead of OrderedHashSet<ATNConfig>
2012-02-08 17:06:41 -06:00
sharwell
52256044a9
Use for each instead of indexed for; use isEmpty() instead of size()==0
2012-02-08 17:06:03 -06:00
sharwell
326cb259a0
Construct Parser with TokenStream (restriction from IntStream)
2012-02-08 16:34:04 -06:00
sharwell
18a6414fb3
Use ATNConfigSet for parameter instead of OrderedHashSet<ATNConfig>
2012-02-08 16:26:14 -06:00
sharwell
a6524d8b38
Add pom.xml to support maven builds
2012-02-08 15:07:06 -06:00
Terence Parr
894a77168d
rename atn sim, add error message to TestRig
2012-02-05 10:14:04 -08:00
Terence Parr
1cc7ac3410
added -trace to TestRig. fixed code gen issue for trace listener
2012-01-30 16:51:55 -08:00
parrt
e90b322dd4
~[] stuff is allowed and works inside sets etc...
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9926]
2012-01-28 14:36:46 -08:00
parrt
09da63cfd4
rollback and do a real fix for whitespace escaping
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9911]
2012-01-27 12:00:30 -08:00
parrt
7498908d62
rollback and do a real fix for whitespace escaping
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9906]
2012-01-26 14:18:57 -08:00
parrt
adcf72b9a2
whitespace was being escaped to special characters even when printing to string should only do so when doing GUI tree
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9904]
2012-01-26 14:11:30 -08:00
parrt
9fd280b30e
Lexer fields mv from x to _x
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9883]
2012-01-21 15:36:20 -08:00
parrt
6013c4c97d
Added modeNames to gen'd lexers
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9878]
2012-01-21 15:10:46 -08:00
parrt
dc82edad02
Summary: we can have lexer commands like -> skip now.
...
moved model.actions package to chunk
type(foo) didn't match.
ATNBuilder.g now tracks the outer alternative number and calls new factory commands on the lexer commands.
Removed unnecessary resolveWithPredicate field from ATNConfig
Added lexerActionIndex field to ATNConfig since we need to track whether we passed an action in an alternative will rule in the lexer.
Renamed ruleIndex in DFAState and added the lexer action index so that we can execute lexer actions from the DFA.
added functions to the grammar tree visitor for the lexer commands.
Added templates for the lexer commands.
Augmented the lexer ATN factory so that it constructs plain old actions from the lexer commands it finds. That way, the code generator doesn't know any different and generates an action.
Augmented the lexer ATN simulator so that it fires a proper action index now. previously it only used the rule index, which of course doesn't work when you have more than one action in a rule.
rm'd dup code from OutputModelController
altered the epsilon edge removal optimization so that it could not remove actions in lexer rules.
Added list of valid lexer commands in Rule.
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9877]
2012-01-21 15:01:05 -08:00
parrt
093a4f951b
leave start/stop char index alone in CommonTokenFactory; refers to original text.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9867]
2012-01-14 11:18:23 -08:00
parrt
5bd780c235
in tree views, spaces/newlines were blanks. I converted to \n and middle dot
...
for space.
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9857]
2012-01-11 17:25:44 -08:00
parrt
848c6e4313
This change is a major restructuring of how left recursive rules are transformed. Previously I simply rewrote the grammar and ANTLR was none the wiser. However, it quickly became apparent that ANTLR needed to do many different things for recursive rules so I had to insert transformation later in the pipeline. Specifically, I needed it after Rule object creation. I made a special LeftRecursiveRule object that track information collected during transformation so that I could use it later. I made major changes to the left recursion templates as well as the little code snippets in Java.stg. I created a new template called LeftRecursiveRuleFunction an accompanying model object that handles the special case, even though there is some duplication. the biggest difference in the grammar is the introduction of => ID notation on any outermost alternative. This information is not added to the tree, instead the ALT node is annotated with the ID. Rule.getAltLabels() now looks also in the LeftRecursiveRuleAltInfo objects. I have moved to the left recursion transformation to its own object and have moved some objects into the analysis package. Further, I have split out the Rule object creation into its own RuleCollector. I renamed discoverAlt in the grammar tree visitor to be discoverOuterAlt an added discoverAlt so we can get information about individual alts even inside subrules. Listeners always get an event for the generic rule context, which is used if there is no specific label for an alternative. Added a list of iteration operations for LL(*) subrules. Split buildRuleFunction into buildLeftRecursiveRuleFunction and one for normal rule function creation. I have to insert lots of extra code to manage the contexts, but of course it's all done using the templates. As long as those templates are correct, this code generation mechanism will work. I removed the st field from the parser rule context. I injected the left recursion transformation inside the SemanticPipeline. Visitor dispatch methods are always added to the generated context structures. Fixed some unit tests. About 24 fail.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9854]
2012-01-11 11:00:05 -08:00
sharwell
742a08862f
Merging dev changes to main
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9853]
2012-01-09 10:26:23 -08:00
parrt
4ae23f4a64
* 1+2*3 now gives new parse tree: (e (e 1) + (e (e 2) * (e 3))) See CHANGES.txt now too
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9833]
2012-01-05 12:27:14 -08:00
parrt
cab41e41e3
had non-ascii char
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9812]
2012-01-04 09:05:31 -08:00
parrt
963ccd2700
added comment
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9797]
2012-01-03 12:46:51 -08:00
parrt
224a4bc9e1
changed formatting
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9796]
2012-01-03 12:46:39 -08:00
parrt
8099cec3bd
Added ctx to visitTerminal in parse tree listener. That should be useful information. made commensurate change in the parse tree walker to make sure I have a proper context to send to the visitTerminal method. renamed a few fields of parser/lexer to have _ in front to avoid name collisions with user actions. change the name of the listener method so that they're more explicit using the terms Error and Parser to identify what kind of listener we are adding or removing. Added a default TraceListener to Parser so that we can call setTrace(true) to have it start dumping out information as a first step in the debugging process. there are now multiple parse tree listeners possible because I made a list. we may want to pass in multiple actions to the parser.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9795]
2012-01-03 12:46:18 -08:00
parrt
5c328c7e3f
Bug: didn't stop at end of stream during consume()
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9794]
2012-01-03 12:40:42 -08:00
parrt
5d60e85617
rm trace ATN state stuff. Will think about when we do debugging.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9792]
2012-01-03 11:07:49 -08:00
parrt
c716a87544
move method down in file
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9791]
2012-01-03 11:05:40 -08:00
parrt
5c3c8d6e7a
Added TokenFactory, CommonTokenFactory. Update the parser in the lexer with methods to set the factory. Alter the default error strategy and the lexer to use the factory. The parser's set token factory method updates the token source, usually the lexer, and the error handling strategy. I had to add the set token factory method to token source as well to make all of this work.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9789]
2012-01-03 10:58:01 -08:00
parrt
3aeeb2b277
rename BaseREcognizer as Parser
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9781]
2012-01-02 18:36:59 -08:00
parrt
1b04195a2f
removed all template / AST rewrite stuff; massive change; added -encoding tool option
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9780]
2012-01-02 18:13:16 -08:00
parrt
8846b98ee7
fix compile error
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9765]
2011-12-29 17:05:34 -08:00
parrt
a923ad8765
Major update to v4. I backed out a change I made on Christmas then mistakenly prevented any lexer DFA creation. Per http://www.antlr.org/wiki/display/~admin/2011/12/29/Flaw+in+ANTLR+v3+LL%28*%29+analysis+algorithm I fixed a major flaw in ANTLR's notion of context. To do that, I needed to create a new LoopEndState, with all of its fanout to the serialization and parser ATN construction. got a very good start on ParserATNPathFinder, which uses basic recursion to find all possible paths and return a tree with the possibilities. I left it in the condition where he would sometimes loop forever; it needs to track sets of configurations in the busy set; it using states at the moment. added a new signal from the interpreter: reportAttemptingFullContext. I fixed a bug where configuration sets derived from a configuration that had reachesIntoOuterContext>0 were not being considered as dipping into the outer context. The ambiguity checker needed to switch so that a check for exact matches not suffixes when doing full context. It's faster at the very least for full context. added some more support routines to DFA. Added TraceTree in support of the new ParserATNPathFinder.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9764]
2011-12-29 17:04:40 -08:00
parrt
3b51bb478d
rm unneeded field
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9761]
2011-12-27 15:52:47 -08:00
parrt
d01bde9125
added new reportAttemptingFullContext to strategy
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9760]
2011-12-27 15:25:01 -08:00
parrt
bb960e3c37
improved data to report insuff. preds. also, it was detecting it improperly
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9758]
2011-12-27 14:11:41 -08:00
parrt
638969bed9
add '...' to diagnostics input
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9757]
2011-12-27 13:37:47 -08:00
parrt
c1e199d77f
added -tokens flag
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9756]
2011-12-26 18:10:29 -08:00
parrt
bf8473e0fd
add cmt
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9755]
2011-12-26 17:57:00 -08:00
parrt
ce9638e59c
was still creating dfa with sempreds
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9752]
2011-12-26 17:07:45 -08:00
parrt
c1923a107e
-tree => -print option
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9748]
2011-12-26 14:05:58 -08:00
parrt
db655f8f2c
add -gui option to view in gui window
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9747]
2011-12-26 13:06:05 -08:00
parrt
5c50e5f049
Wasn't using Udo's lib correctly
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9746]
2011-12-26 13:05:46 -08:00
parrt
c6bde7e1e8
-ps arg wrong
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9745]
2011-12-26 11:13:46 -08:00
parrt
adb91a9bde
rm print
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9744]
2011-12-26 11:10:30 -08:00
parrt
494f519b05
add java org.antlr.v4.runtime.misc.TestRig GrammarName startRuleName [-tree | -ps file.ps] [input-filename]
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9743]
2011-12-26 11:03:51 -08:00
parrt
6daa66f83f
no more resolved bit in config. use ATNConfigSet all over. final clean up of ATN sim.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9741]
2011-12-25 12:01:24 -08:00
sharwell
79d1c40427
Integrate CL9648 to main (getAncestors returns Collections.emptyList() instead of null)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9649]
2011-12-17 11:42:26 -08:00
sharwell
c59cf36f88
Integrate CL9646 to main (fix forward seek)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9647]
2011-12-17 09:51:18 -08:00
parrt
6b673a3b2e
track stats properly
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9643]
2011-12-16 16:00:11 -08:00
parrt
ebd1fbb63d
within 2 or 3 unit test of where I was before I got it the ATN simulator
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9642]
2011-12-16 15:07:28 -08:00
parrt
3d133e9417
broke out fullctx tests, some fixes.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9636]
2011-12-16 09:43:29 -08:00
parrt
1e8548297e
mv comment over and make sure that the tree parsers use the new ATN engine
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9635]
2011-12-15 16:14:49 -08:00
parrt
5ad1505fdb
almost got new ATN engine working; separated .* nongreedy tests, reorg args on reporting methods
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9627]
2011-12-15 11:03:41 -08:00
sharwell
fa3483a7fc
Merge CL9619 to main (fix CommonTokenStream.seek)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9620]
2011-12-15 07:27:52 -08:00
parrt
92279bd6db
almost got prediction working
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9600]
2011-12-13 18:10:04 -08:00
parrt
8d73f53775
check in start of new ATN sim engine; rm traversedPred in DFAState.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9598]
2011-12-13 14:38:30 -08:00
parrt
8f7fb98e16
added big comments
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9565]
2011-12-12 16:33:10 -08:00
parrt
b9afdf6e07
rename var; add missing return
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9564]
2011-12-11 14:45:25 -08:00
parrt
3fb7466a80
another big reorg and fixed unit test. lots more sharing and splitting into methods; same 21/807 tests fail; java works.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9563]
2011-12-11 14:34:32 -08:00
parrt
8615fc26da
rm dead code
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9562]
2011-12-11 13:03:34 -08:00
parrt
18ff004d83
playing; nop
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9560]
2011-12-11 12:29:27 -08:00
parrt
d372d761d5
interim refactoring. much smaller execATN; removed prevAccept fields. useless.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9559]
2011-12-11 12:09:29 -08:00
parrt
c3630843d2
add convenience method
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9558]
2011-12-11 11:23:42 -08:00
parrt
1923242b37
clean up comment
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9553]
2011-12-10 18:54:52 -08:00
parrt
b89d7c0932
rm dead code
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9552]
2011-12-10 18:51:46 -08:00
parrt
12aa6c2404
fix unit tests, bug in collecting preds and testing in DFA state
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9550]
2011-12-10 17:28:17 -08:00
parrt
b1c7edb8d8
moved empty context chk for retry
...
altered args on reporting methods
reporting methods moved from parser to error strategy
fixed full ctx retry in DFA (used to only work in ATN)
i record conflictSet not just boolean in DFA
added debugging support to BaseRecognizer
added DiagnosticErrorStrategy
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9549]
2011-12-10 16:24:41 -08:00
parrt
b682450e29
add clone()
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9548]
2011-12-10 15:43:06 -08:00
parrt
131e9f7686
added comments, working on parser interpreter (not prediction) reorg. adding ParserInterpreter. adding unit tests.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9546]
2011-12-09 16:35:21 -08:00
parrt
63168c5577
added more dbg prints, turned on context sensitivity in test java lr.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9545]
2011-12-07 17:47:08 -08:00
parrt
946c59da14
added Sam's fix for def of ambiguous DFA state; added unit test but not working yet. rule ctx conflictsWith() consistent with v3 now; replaced some Set<Integer> with IntervalSet (for alt sets) and sped things up.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9541]
2011-12-06 17:10:53 -08:00
parrt
28696fe2ff
add toSet()
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9540]
2011-12-06 15:58:47 -08:00
parrt
cc00494e9d
add null chk
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9535]
2011-12-06 11:41:08 -08:00
parrt
27aca5a66e
rm prints
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9533]
2011-12-06 11:24:33 -08:00
parrt
cab803d5f3
tweak comment
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9528]
2011-12-05 09:44:40 -08:00
parrt
2ddb8100e9
shrunk serialized ATN a bit
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9526]
2011-12-04 18:39:20 -08:00
parrt
b09077209c
fixed hideous bug found by sam in getAmbigAlts
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9525]
2011-12-04 18:21:24 -08:00
parrt
110fafde5a
change name
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9524]
2011-12-04 16:02:40 -08:00
parrt
80fd90d363
rm'd epsilon transition in ATN after rule refs.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9518]
2011-12-03 14:52:24 -08:00
parrt
2b8a821c21
turn off dbg print
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9517]
2011-12-03 14:16:47 -08:00
parrt
f08e8fc098
predTransition was not passing along predicate properly. rm'd unneeded parameter. pass null if ctx independent pred. added 2 unit tests for non outer ctx check.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9516]
2011-12-03 14:12:06 -08:00
parrt
cabe808c7f
trivial change, gets small speed bump
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9514]
2011-12-02 12:22:35 -08:00
sharwell
beec4ab721
v4: Back out changelist 9511 (change DFAState.configs to ATNConfig[])
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9513]
2011-12-02 10:04:34 -08:00
parrt
ae74881de6
strip epsilons between alternative elements and also stripped the final epsilons before block ends. added an ATN visitor for general use. updated all of the unit tests so they pass new smaller ATNs. had to do some work in the serialization and deserialization to handle state numbers without state information. did not want to reorder state numbers during optimization.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9512]
2011-12-01 17:46:12 -08:00
sharwell
682e60b065
v4: DFAState.configs now ATNConfig[] instead of OrderedHashSet<ATNConfig>
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9511]
2011-12-01 17:04:25 -08:00
parrt
4d942c37c8
use RuleContext not ParserRuleContext during prediction
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9510]
2011-12-01 14:24:57 -08:00
parrt
4400ba169f
refactored RuleContext to move all noncritical fields down into ParserRuleContext. Widespread but minor changes. Using the more specific ParserRuleContext where appropriate.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9509]
2011-12-01 14:01:00 -08:00
sharwell
38c69af805
v4: Back out changelist 9507 (PredictionContext optimization)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9508]
2011-12-01 13:14:37 -08:00
sharwell
11b6fa13f9
v4: PredictionContext optimization
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9507]
2011-12-01 13:13:24 -08:00
parrt
a8219d943e
got java LR parser working :) allows e A B C e type LR alts now
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9506]
2011-11-30 18:57:45 -08:00
parrt
b6b4583b92
let it build DFA again.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9505]
2011-11-30 18:31:20 -08:00
parrt
8d7a97fb68
fixing some pred bugs. fixed unit testSimple in pred eval. optimized sem ctx.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9503]
2011-11-30 17:44:49 -08:00
Udo Borkowski
1bc3997930
add "useCurvedEdges" feature
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9502]
2011-11-30 17:10:46 -08:00
Udo Borkowski
ef57f44240
add "useCurvedEdges" feature
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9501]
2011-11-30 16:12:35 -08:00
sharwell
8c3e8272d8
v4: System.out.format instead of System.out.println
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9496]
2011-11-30 08:50:25 -08:00
sharwell
583668746f
v4: Optimize ATNState.onlyHasEpsilonTransitions (5-15% improvement during warmup)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9495]
2011-11-30 08:42:54 -08:00
sharwell
8096b3b4c4
v4: Check for early return conditions during DFA updates
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9494]
2011-11-30 07:05:38 -08:00
sharwell
83a5f592d0
v4: Convert do{...}while(true) to while(true){...}
...
Use CharStream.EOF instead of Token.EOF when referencing results of CharStream.LA
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9493]
2011-11-30 07:03:40 -08:00
sharwell
befd9ba483
v4: Combine calls to Set.contains and Set.add
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9492]
2011-11-30 06:32:33 -08:00
sharwell
2bbb1ca132
v4: Fix Parser.reset (side effect fixes Parser.setInputStream)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9491]
2011-11-29 20:25:51 -08:00
sharwell
1be2e2c556
v4: Initial tracing support in the lexer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9490]
2011-11-29 20:13:06 -08:00
sharwell
fb3de170d1
v4: Add BaseRecognizer.isExpectedToken - *massive* performance improvement in DefaultErrorStrategy.sync()
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9489]
2011-11-29 19:43:33 -08:00
sharwell
07bbf42f8b
v4: Add <?> to generic instance
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9488]
2011-11-29 19:31:25 -08:00
sharwell
99cf07cc3c
v4: check for null
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9487]
2011-11-29 19:01:35 -08:00
sharwell
a71a9f04ea
v4: check for null before evaluating sempreds in the lexer (issue a warning if no recognizer is available for evaluation)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9486]
2011-11-29 18:59:32 -08:00
sharwell
c25f3ff3d8
Add type parameter to BailErrorStrategy since the class may safely be used with any type of recognizer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9485]
2011-11-29 17:50:03 -08:00
parrt
2243cc2e81
wasn't seeing thru some preds.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9484]
2011-11-29 17:31:18 -08:00
parrt
e00fa44996
Got validating and disambiguating predicates the way I want; widespread changes. DFAStates now have a list of predicate/alt pairs that they can test at except states. renamed Java.g4 to JavaLR.g4. LL(1) analysis did not fail when it's all predicates, which it must.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9482]
2011-11-29 15:46:51 -08:00
Udo Borkowski
4e30119ab6
fix various issues in TreeViewer
...
1) Issue: The tree "jumps" from a larger scale to a much smaller scale when starting dragging the scale slider.
Cause: Initially the slider was not correctly positioned. It always assumed a scale of 1.
Solution: I now calculate the initial slider position using the current scale (was 1.5).
---
2) Issue: NullPointerException when the scale slider is dragged to the very left.
Cause: The formula "v / 1000.0 + 1.0" results in a scale of 0.0 when using -1000 (left position). A scale of 0 is not supported.
Solution: in setScale I now check for "<= 0.0". In the case I use scale 1. In addition I changed the lower bound of the slider to -999, i.e. the left position represents the scale "0.001".
---
3) Issue: when scaling the scrollbars are not added/updated/removed
Cause: when scaling the preferred size of the TreeViewer must be updated as the ScrollPane refers to the preferredSize for scrolling.
Solution: now calling "updatePreferredSize" in setScale. This will set the preferred size to the "scaled tree size". It also ensures parents will be notified and the view is repainted.
---
4) Issue: only an upper left part of the tree is painted.
Cause: the TreeViewer overwrote the getWidth/Height and returned unchanged values (800x600). Only this area in painted. If the preferred size exceeded this size the remaining area was not painted.
Solution: Removed the overwrite of getWidth/Height. As one consequence the dialog will start at maximum size for large tree layouts.
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9481]
2011-11-29 07:40:09 -08:00
parrt
9a1a8428b5
got ambig pred thing working i think; unit tests. missing validating pred thing.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9480]
2011-11-28 19:16:45 -08:00
parrt
e288ff3039
interim pred overhaul
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9479]
2011-11-28 09:37:29 -08:00
parrt
eb6443b32b
add TODO
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9478]
2011-11-27 14:39:29 -08:00
parrt
3b7e984d5f
mv join to runtime Utils
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9477]
2011-11-27 14:28:59 -08:00
sharwell
fc2b4cad07
v4: Call mark() from match instead of matchATN
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9476]
2011-11-27 13:45:36 -08:00
parrt
c0262d569b
pull v3 pred ctx tree stuff
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9475]
2011-11-26 20:57:20 -08:00
parrt
dc4ce0cd16
update cmt in ctx and make out of ctx preds see through
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9473]
2011-11-26 14:19:03 -08:00
parrt
181611da94
rounded line edges, no border if color==null; 1.0.1 abego
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9468]
2011-11-26 11:28:50 -08:00
parrt
b83da61f52
Left EPSILON in expected set; rm'd
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9466]
2011-11-26 11:02:45 -08:00
parrt
9b924d0348
fix toString for EPS
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9465]
2011-11-26 11:00:38 -08:00
parrt
a6be7ddb9c
fixed enter/exit. "every" done first/last now.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9463]
2011-11-26 10:27:01 -08:00
parrt
30d89abc4a
rm type param
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9462]
2011-11-25 18:16:46 -08:00
parrt
fe1691da78
update comment
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9461]
2011-11-25 16:25:30 -08:00
parrt
d2b24da47f
remove incidentTransition from ATNState, add computation for next tokens within rule, add nextTokenWithinRule to ATNState, add EPSILON as -2 token type
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9459]
2011-11-25 16:09:00 -08:00
parrt
6898dc6f5e
add readonly bit to sets
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9458]
2011-11-25 14:39:05 -08:00
parrt
d35560583c
add remove() to IntervalSet
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9456]
2011-11-25 14:25:08 -08:00
parrt
5dfc4aed1d
add on-the-fly listeners; augment enter/exit rule, consume(). playground/U.g and MyUListener.java are test. added human-readable toInfoString to ParserRuleContext such as
...
RuleParserRuleContext[s, a]{altNum=0, start=[@0,0:0='a',<6>,1:0], stop=null, st=null}
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9453]
2011-11-25 10:38:36 -08:00
parrt
4af8a7ac61
rm bad comment
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9452]
2011-11-25 10:00:02 -08:00
sharwell
7a52d4e304
Back out changelist 9448
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9449]
2011-11-23 12:25:06 -08:00
sharwell
898138a5e2
v4: Reusable ATN simulator objects
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9448]
2011-11-23 06:42:31 -08:00
sharwell
89ebd369f9
v4: @Override annotations, update equals to check parameter type
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9447]
2011-11-23 06:41:45 -08:00
sharwell
ed7377dfd4
v4: remove TODO - situation was already addressed
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9446]
2011-11-23 06:31:08 -08:00
parrt
bf1e306bae
rm commented out code
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9445]
2011-11-22 18:29:14 -08:00
sharwell
22edf77263
v4: specify generic type
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9439]
2011-11-22 16:38:42 -08:00
sharwell
cf0d47c8fe
v4: Parser.setInputStream calls Parser.setTokenStream
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9438]
2011-11-22 16:36:39 -08:00
sharwell
1495ba5bd7
v4: use getInterpreter() instead of directly accessing the _interp field
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9437]
2011-11-22 16:33:19 -08:00
parrt
72684907bc
add -Xlog, add .ctx to rule refs. parse tree test pass.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9436]
2011-11-22 16:30:50 -08:00
parrt
95f3afa562
rm ANTLRStringStream. combined with ANTLRInputStream. causes name change in lots of files. rm encoding ability.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9435]
2011-11-22 15:50:19 -08:00
parrt
7d5c69842b
BufferedTokenStream gets generic type. CommonTokenStream extends BufferedTokenStream<CommonToken>, rename unbuff'd stream. add unbuff token stream
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9428]
2011-11-22 15:21:09 -08:00
parrt
4b393cf448
rm QStack and use ArrayDeque
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9427]
2011-11-22 14:33:35 -08:00
parrt
31c24292cd
unbuff char stream working
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9425]
2011-11-22 12:32:15 -08:00
parrt
45dc683a91
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9424]
2011-11-22 12:30:53 -08:00
parrt
f3b0ffb8b2
almost working
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9423]
2011-11-21 17:55:39 -08:00
parrt
0fe415e227
checking in but doesn't work yet; just so i can pull at work
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9421]
2011-11-20 16:07:45 -08:00
parrt
f8a8aadca2
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9420]
2011-11-20 15:14:19 -08:00
parrt
3e216a258d
combine Reader/InputStream into InputStream
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9419]
2011-11-20 15:13:16 -08:00
parrt
6abc73cba3
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9418]
2011-11-20 15:04:48 -08:00
parrt
2c98cae751
no more line/col in string stream
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9417]
2011-11-20 15:03:15 -08:00
parrt
4cc8a8e501
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9416]
2011-11-20 14:46:47 -08:00
parrt
e71440b9cb
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9415]
2011-11-20 14:40:26 -08:00
parrt
4b4a7d9c7a
add LogManager, add InputSymbolType()
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9413]
2011-11-20 14:27:58 -08:00
parrt
01a71c5b02
fixing a lot of little thingsTo make my examples work
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9410]
2011-11-19 17:27:19 -08:00
parrt
b61603e98a
A rename of TSymbol->Symbol and a few of T to Symbol. Also changed name of the default error handler
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9406]
2011-11-19 13:44:53 -08:00
sharwell
5c7ff2cf9d
v4: Use IntStream.mark to ensure that CharStream.substring works within the bounds necessary for Lexer.getText
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9405]
2011-11-19 13:39:55 -08:00
parrt
6b1c367d54
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9404]
2011-11-19 13:28:50 -08:00
parrt
4476cbf22b
else format
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9403]
2011-11-19 13:09:48 -08:00
parrt
c1b77ac6a8
format else
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9401]
2011-11-19 12:48:15 -08:00
parrt
7f042393d2
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9400]
2011-11-19 12:47:41 -08:00
parrt
06ed597d29
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9399]
2011-11-19 12:42:54 -08:00
parrt
ac7913e67f
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9398]
2011-11-19 12:40:48 -08:00
sharwell
0092b421b5
v4: Fix Lexer.reset (and as a side effect fixes Lexer.setInputStream)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9396]
2011-11-18 22:58:11 -08:00
sharwell
f64ecebd34
v4: Fix LookaheadStream ability to seek forward past the current location (via consume())
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9395]
2011-11-18 22:54:07 -08:00
sharwell
7774405ee3
v4: Can't use the @NotNull and @Nullable from com.sun.istack.internal. Adding our own until we settle on a final library.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9394]
2011-11-18 22:48:08 -08:00
sharwell
ca141afc28
v4: @NotNull and @Nullable annotations for fields and methods
...
mark fields final
no behavior changes
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9389]
2011-11-18 11:29:58 -08:00
sharwell
6060b6c288
v4: visitToken->visitTerminal
...
TokenNode->TerminalNode
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9384]
2011-11-17 20:09:24 -08:00
sharwell
ff97c91ef2
v4: ObjectStream -> SymbolStream
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9381]
2011-11-17 19:45:35 -08:00
sharwell
f999b5c3d0
v4: TODO comments
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9380]
2011-11-17 19:40:56 -08:00
sharwell
65f8b9f124
v4: Add TSymbol generic type parameter to Recognizer, BaseRecognizer, ParserATNSimulator, ParserRuleContext, ParseTreeListener, ANTLRErrorStrategy, ANTLRErrorListener, TreeParserRuleContext
...
Move ParserRuleContext.tree/getTree to the generated contexts, implement ASTContext<T> for strongly typed getTree() method
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9379]
2011-11-17 19:40:48 -08:00
sharwell
73907aacd3
v4: Unnecessary semi in {;}
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9377]
2011-11-17 19:07:17 -08:00
sharwell
b441dc226a
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9376]
2011-11-17 19:06:20 -08:00
sharwell
5f6b463174
v4: StringBuilder instead of StringBuffer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9375]
2011-11-17 19:00:49 -08:00
sharwell
0e587759c1
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9374]
2011-11-17 19:00:00 -08:00
sharwell
8d92e55e49
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9373]
2011-11-17 18:58:24 -08:00
sharwell
9ce0968a5e
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9372]
2011-11-17 18:55:47 -08:00
sharwell
d9c0ce2f0c
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9371]
2011-11-17 18:45:18 -08:00
sharwell
1581c54ff6
v4: Specify generic arguments for ASTAdaptor usage, remove unnecessary casts
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9370]
2011-11-17 18:43:01 -08:00
sharwell
c4bb346f9a
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9369]
2011-11-17 18:42:18 -08:00
sharwell
afebb6138e
v4: Specify generic argument for ASTAdaptor usage
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9368]
2011-11-17 18:40:35 -08:00
sharwell
e2dbb085ac
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9367]
2011-11-17 18:40:00 -08:00
sharwell
88b4c7572f
v4: Remove unnecessary casts
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9366]
2011-11-17 18:38:51 -08:00
sharwell
77aeca8174
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9365]
2011-11-17 18:38:13 -08:00
sharwell
845d1f913c
v4: Specify generic argument for ASTAdaptor usage, remove unnecessary casts
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9364]
2011-11-17 18:36:39 -08:00
sharwell
66f0e01520
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9363]
2011-11-17 18:34:52 -08:00
sharwell
1da1fe8002
v4: remove unnecessary casts
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9362]
2011-11-17 18:33:20 -08:00
sharwell
d01c583e36
v4: Class<?> instead of Class
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9361]
2011-11-17 18:30:27 -08:00
sharwell
5e567eacc9
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9359]
2011-11-17 18:28:54 -08:00
sharwell
bac9c543ba
v4: Fix _LOOK for NotSetTransition
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9358]
2011-11-17 18:27:50 -08:00
sharwell
57eb76aab3
v4: StringBuilder instead of StringBuffer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9357]
2011-11-17 18:26:46 -08:00
sharwell
24b354e0a5
v4: Return List<String> instead of List
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9353]
2011-11-17 18:22:59 -08:00
sharwell
f356cd42d1
v4: Remove unnecessary casts
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9345]
2011-11-17 16:59:49 -08:00
sharwell
5ccf0526aa
v4: StringBuilder instead of StringBuffer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9344]
2011-11-17 16:59:38 -08:00
sharwell
818be0bfb7
v4: Simple use of generics
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9343]
2011-11-17 16:59:28 -08:00
sharwell
36a9af8b29
v4: Specify @Nullable
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9342]
2011-11-17 16:59:19 -08:00
sharwell
3526198105
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9341]
2011-11-17 16:58:10 -08:00
sharwell
0d41d48d6e
v4: Remove unnecessary cast
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9340]
2011-11-17 16:52:41 -08:00
sharwell
41ed240850
v4: Return List<Token> instead of List
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9339]
2011-11-17 16:50:39 -08:00
sharwell
f9396907bd
v4: Clean up impl with generic List<T> field
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9338]
2011-11-17 16:48:30 -08:00
sharwell
421a261ddb
v4: Specify @Override
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9337]
2011-11-17 16:06:30 -08:00
sharwell
79da4c7386
v4: Specify @Override, add <?> for local generic instance
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9335]
2011-11-17 16:04:09 -08:00
sharwell
2fce2b0f2d
v4: Fix mark/seek/release for LookaheadStream
...
LookaheadStream.LB can see back to the earliest mark
Specify @Override
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9334]
2011-11-17 16:02:58 -08:00
sharwell
66c53e18dc
v4: Expose generic List<Integer>
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9333]
2011-11-17 16:01:13 -08:00
sharwell
ed32646f52
v4: Simple use of generics to clean up local impl code
...
Specify @Override
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9332]
2011-11-17 16:00:40 -08:00
sharwell
ddf4cadf06
v4: TokenStream extends ObjectStream<Token> (specified Token as the type parameter)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9327]
2011-11-17 15:52:21 -08:00
sharwell
29ec107b24
v4: Remove explicit boxing/unboxing
...
Add @Override and @Nullable annotations
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9326]
2011-11-17 15:49:34 -08:00
sharwell
92bbdfbaea
v4: Use generics for List and Map fields/locals to clean up several casts
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9325]
2011-11-17 15:48:23 -08:00
sharwell
ee4a70cf16
v4: StringBuilder instead of StringBuffer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9324]
2011-11-17 15:44:49 -08:00
parrt
8792fe19ff
rm
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9314]
2011-11-17 11:16:51 -08:00
parrt
6e38497b11
change name
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9313]
2011-11-17 11:07:33 -08:00
sharwell
fe16bc3f1f
v4: Add ParseTreeWalker.DEFAULT to make basic listener usage easier
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9312]
2011-11-15 12:31:11 -08:00
parrt
d597de1792
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9311]
2011-11-13 18:26:27 -08:00
parrt
27cbd249ac
Added lots of little stuff
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9310]
2011-11-13 18:04:35 -08:00
parrt
c8e9e12a74
add <T> to ast stuff
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9309]
2011-11-13 12:57:15 -08:00
parrt
60817a180a
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9308]
2011-11-13 11:52:29 -08:00
parrt
1d29898f1b
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9307]
2011-11-13 11:35:25 -08:00
parrt
324884585b
add slider
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9306]
2011-11-13 11:35:11 -08:00
parrt
f420f4c327
add OK button, set size, add scale
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9305]
2011-11-13 11:06:40 -08:00
parrt
61e9eade6a
added {...}?<msg="foo"> option
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9300]
2011-11-10 14:08:16 -08:00
parrt
843375522d
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9288]
2011-11-10 12:23:33 -08:00
parrt
fbbf74bc4e
add exception to recover()
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9287]
2011-11-10 12:21:08 -08:00
sharwell
3ca6ab034d
v4: Can't add a DFA edge for token types < -1 (EOF)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9269]
2011-11-09 10:18:54 -08:00
sharwell
783c3b2e50
v4:
...
* Use mark->seek->release instead of mark->release->seek
* mark() returns a marker. must pass the result of index() to seek(), and the result of mark() to release().
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9268]
2011-11-09 10:16:51 -08:00
parrt
2767530a47
name change
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9267]
2011-11-06 12:36:24 -08:00
parrt
e0fc8fe087
was consuming too much in recover
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9266]
2011-11-06 11:22:25 -08:00
parrt
ca17a4ce5b
ooops; wrong version
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9265]
2011-11-06 10:32:01 -08:00
parrt
ddb7ae218d
useError recovery said notThe set that follows a loop for sync()
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9264]
2011-11-06 10:31:13 -08:00
parrt
8237c2f0fb
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9263]
2011-11-06 08:30:43 -08:00
parrt
64b4cbd2c8
added auto highlight to tree views
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9262]
2011-11-05 08:56:12 -08:00
parrt
c17aab708f
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9261]
2011-11-03 13:40:16 -08:00
parrt
b23c093b68
no longer drawing background of nodes in tree unless you set a color
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9255]
2011-11-03 09:33:08 -08:00
parrt
ffc4f9b126
added Cay Horstmann's printing code for postscript.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9254]
2011-11-03 09:10:30 -08:00
parrt
647cb6d0ad
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9237]
2011-11-01 11:06:39 -08:00
parrt
8eb2e62fea
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9236]
2011-11-01 10:46:34 -08:00
parrt
2efba8b39d
it was sending null to postscript generation
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9235]
2011-11-01 09:32:40 -08:00
parrt
5cf4cba9c7
fix bug in modes
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9231]
2011-10-31 16:27:34 -08:00
parrt
947a11a3e4
start lexical error unit tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9228]
2011-10-30 13:48:09 -08:00
parrt
800564e1d6
made DFA sim loop smaller; refactored
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9227]
2011-10-30 13:23:52 -08:00
parrt
2d43a22e27
reorg'd lexer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9226]
2011-10-30 10:39:17 -08:00
parrt
95bc423669
more tests and made EOF always appear even if DONE : EOF ; in lexer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9225]
2011-10-29 13:59:17 -08:00
parrt
bc5577307c
more tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9224]
2011-10-29 12:08:34 -08:00
parrt
6e2bbcdb42
got EOF in lexer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9223]
2011-10-29 11:08:40 -08:00
parrt
6576abf65f
reorg'd lexer ATN sim to fix bug
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9221]
2011-10-27 19:33:45 -08:00
parrt
f44d03343a
push to grab at work...lexer might be hosed
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9220]
2011-10-27 11:29:20 -08:00
sharwell
bedb935bde
v4: Fix IndexOutOfBoundsException when token type < -1
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9211]
2011-10-27 08:55:08 -08:00
parrt
ad468ee29b
added tree node highlighting in treeviewer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9206]
2011-10-25 15:53:46 -08:00
parrt
7f867ec9d6
tweak padding
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9191]
2011-10-25 08:57:09 -08:00
parrt
fc85072851
add ArialNarrow, update to 255 max char
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9190]
2011-10-25 08:52:14 -08:00
parrt
490cec9af6
antialias lines
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9181]
2011-10-24 14:41:37 -08:00
parrt
2cbd522320
clean up, added tree parser err handler
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9178]
2011-10-23 14:04:58 -08:00
parrt
11b61d979d
refactored sync/recoverInLine. figured out exactly what sync does at start of alt. setState goes to loopBack now in loops
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9177]
2011-10-23 11:07:07 -08:00
parrt
4920bb2c9e
_errHandler.sync(this);
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9176]
2011-10-22 13:25:28 -08:00
parrt
39314b8d74
added PS support routines
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9154]
2011-10-22 11:46:13 -08:00
parrt
78bc92d81b
compiile error
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9153]
2011-10-22 11:39:16 -08:00
parrt
72906f5910
add font metrics to gen PS properly
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9152]
2011-10-22 11:22:22 -08:00
parrt
89d4b31ef6
rm treelayout, add jar
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9150]
2011-10-21 11:22:00 -08:00
parrt
542a57b49a
reworked udo's tree viewer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9149]
2011-10-21 10:58:00 -08:00
parrt
6c104b7724
pull apart treeviewer; rename ANTLRParserListener
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9148]
2011-10-20 19:12:32 -08:00
parrt
688f69541c
sync for use at home
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9146]
2011-10-15 08:58:13 -08:00
parrt
9eb19cf929
added start/stop methods.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9145]
2011-10-12 15:09:14 -08:00
parrt
3bbcfa5d25
change name of method
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9144]
2011-10-11 16:16:29 -08:00
parrt
547d58514d
bug fixes in error handling part deux
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9112]
2011-10-06 13:28:36 -08:00
parrt
251a42ddbb
bug fixes in error handling
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9111]
2011-10-06 10:40:07 -08:00
parrt
1efa316de9
added ctx stack test
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9110]
2011-10-05 15:15:58 -08:00
parrt
6179d7586b
tweak tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9108]
2011-10-04 13:26:18 -08:00
parrt
e293cbbdf5
UnsupportedOperationException
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9107]
2011-10-04 11:50:57 -08:00
parrt
d56e8c3a18
reorg error and add parse tree tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9106]
2011-10-04 10:19:04 -08:00
parrt
2707837bc8
factored out node construction for parse trees into a consume() method. added a start to the test parse trees. added the notion of an error node to the parse tree.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9104]
2011-10-03 17:30:55 -08:00
parrt
473e56d59f
more tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9103]
2011-10-03 11:04:01 -08:00
parrt
8508dd6da0
got sync in
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9101]
2011-10-02 20:31:26 -08:00
parrt
bf48ca5b73
test for conjured token
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9097]
2011-10-02 16:19:03 -08:00
parrt
1556d076bd
got token insertion working
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9096]
2011-10-02 16:15:02 -08:00
parrt
c33b06fdde
bug fix; no lexer if no lex rules
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9095]
2011-10-02 15:21:32 -08:00
parrt
2a34d00d09
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9094]
2011-10-02 13:18:10 -08:00
parrt
05360be562
more cleanup
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9093]
2011-10-02 13:17:06 -08:00
parrt
02d424a92b
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9092]
2011-10-02 12:58:53 -08:00
parrt
49571e386f
err clean up
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9091]
2011-10-02 12:51:33 -08:00
parrt
298a15e017
Parse error systemTweaks, removing the debug API since we won't use it
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9090]
2011-10-02 12:01:35 -08:00
parrt
9894221249
rename test. tweak errs
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9089]
2011-10-01 10:31:36 -08:00
parrt
6b4e9905fb
rename member, tweak output. new chk for inf loop from error sync works
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9088]
2011-09-30 20:40:14 -08:00
parrt
60c9fe76c0
almost got new error mech in
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9087]
2011-09-30 20:22:09 -08:00
parrt
9e69640bc1
added more unit tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9086]
2011-09-27 17:09:17 -08:00
parrt
82360bfaa8
clean up
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9085]
2011-09-27 16:23:15 -08:00
parrt
fd3f482375
fixed regression in atn interp
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9083]
2011-09-25 15:10:21 -08:00
parrt
e3d6db0478
more unit tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9081]
2011-09-25 14:10:30 -08:00
parrt
f02db87c02
got nullable kids tree parsing working. got $rule.text in tree parsing working
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9077]
2011-09-24 17:12:22 -08:00
parrt
e8a2a738cf
rename TreeNodeStream
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9075]
2011-09-24 09:33:04 -08:00
parrt
93581cfa98
got v3 tests working in v4
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9074]
2011-09-24 09:14:22 -08:00
parrt
b63b271815
got basic tree parser working.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9071]
2011-09-22 17:16:22 -08:00
parrt
a1c682434d
removes the individual stacks to track rule invocations. $a::x now looks up the context stack for rule index RULE_a. they're not done very often and so it's better to say all of the overhead pushing and popping the contexts.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9066]
2011-09-11 16:12:01 -08:00
parrt
64ccba4168
rebuilt the code generator so that I generate a separate class for each labeled alternative and modify the listener so that it's always enter and exit rule; the type of the argument that distinguishes between them. I now create the overall rule context and then copy it into the alternative context if they have a label.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9064]
2011-09-11 15:09:55 -08:00
parrt
bf19465437
Got a rule labels added to the tree and also altered code generation so that it pays attention to the labels. fairly major surgery but it's a nice refactoring.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9062]
2011-09-09 17:08:13 -08:00
parrt
f13fd1973e
mv ruleIndex, add alt
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9061]
2011-09-09 13:00:58 -08:00
parrt
62937ca639
rename visit->walk
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9060]
2011-09-08 16:52:30 -08:00
parrt
2d234ee28c
Got the visitor thing cleaned up enough for a small example
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9059]
2011-09-08 13:45:05 -08:00
parrt
da7e7c8813
clean up tree output, rename _ctx to context
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9058]
2011-09-08 12:12:51 -08:00
Udo Borkowski
b671cb1fba
add treeTextProvider and various "visual" properties to TreeViewer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9057]
2011-09-08 10:05:23 -08:00
Udo Borkowski
a440d4e988
add TreeViewer
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9051]
2011-09-06 08:45:28 -08:00
parrt
1e595a486a
add
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9050]
2011-09-06 06:31:44 -08:00
parrt
730794128e
parse tree visiting; now, we ALWAYS generate a return struct definition: rule_ctx.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9049]
2011-09-05 17:08:26 -08:00
parrt
0f74909c8c
mv ruleIndex
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9045]
2011-09-05 12:49:54 -08:00
Udo Borkowski
f93bc7aa7a
add org.abego.treelayout
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9044]
2011-09-05 10:50:57 -08:00
parrt
528d6df1e3
added list of rule consts; parser ctx tracks rule index
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9043]
2011-09-05 08:28:24 -08:00
parrt
01020ee1bb
more cleanup
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9042]
2011-09-04 15:55:45 -08:00
parrt
5c35165873
update the comment
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9041]
2011-09-04 13:49:40 -08:00
parrt
32a375bbf7
I split the tree interface into multiple simpler ones and removed the methods that can modify a node. Either you should use the adapter or, you know the concrete type and then you can call those methods directly not through the interface. The whole point of the interface is to be flexible but then for consistency users must use the adapters. I'm also starting to pull helper methods into a Trees "module". I also renamed CommonTree to be CommonAST. I also renamed the adapters appropriately.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9040]
2011-09-04 12:02:07 -08:00
parrt
783f1bc38f
Split token into read-only and writable portions. added release method. moved the methods around that get input streams and token streams between interfaces. simplify the character stream interface by moving the gas line and get characterization methods to the lexer.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9039]
2011-09-03 17:36:14 -08:00
parrt
5c6f35abef
did some reorganization
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9038]
2011-09-03 11:52:23 -08:00
parrt
c1aa0fcd10
New parse tree mechanism
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9037]
2011-09-03 09:18:26 -08:00
parrt
104f39acde
working on parse trees
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9036]
2011-09-02 17:15:36 -08:00
parrt
7aad57fe49
add
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9035]
2011-09-02 16:18:25 -08:00
parrt
62549b65bf
add dbg classes. add mark/rewind
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9034]
2011-09-02 16:17:37 -08:00
parrt
085dd05bf1
got parser nongreedy loops going
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9032]
2011-08-12 19:51:12 -08:00
parrt
f44c49a8b8
got lexer nongreedy loops going
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 9018]
2011-08-07 11:19:34 -08:00
parrt
d926ec9661
WOOT! all left-recursive tests pass
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8972]
2011-07-31 18:14:47 -08:00
parrt
ec5d74c83e
removed all traces of FORCED_ACTION
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8971]
2011-07-31 12:36:07 -08:00
parrt
a7f2bc31ac
ok, got new simple semantics in for sempreds; no forced actions and preds always eval unless ctx dependent, in which case they need to bein original rule.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8970]
2011-07-31 11:58:59 -08:00
parrt
328444244f
backing out changes; tried 2 stacks; too complicated
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8969]
2011-07-31 10:38:48 -08:00
parrt
d2651a50a6
backing out changes; tried 2 stacks; too complicated
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8968]
2011-07-31 10:38:23 -08:00
parrt
e32bae3276
rebuilt ATN structure for ()* and ()+; two decisions each now unless single alt.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8966]
2011-07-30 17:20:57 -08:00
parrt
64e12dbfa5
add method
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8961]
2011-07-30 11:49:49 -08:00
parrt
b90b073450
getting more unit tests in
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8924]
2011-07-29 14:05:19 -08:00
parrt
4b5cd3a9ba
We're forced to exec args, even if dependent on _localctx. If no actual context to use, create dummy context to use for arg eval only.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8922]
2011-07-29 11:45:27 -08:00
parrt
dcfb804ed3
added method to get context for non-arg rules
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8921]
2011-07-28 19:36:56 -08:00
parrt
cce6c70b2e
fixed context in sempred. don't exec forced actions either if in outer context and dependent.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8920]
2011-07-28 15:15:41 -08:00
parrt
3d15daccad
got predicate issue resolved. executes preds if not dependent on context and no dipping into outer context
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8919]
2011-07-28 12:43:28 -08:00
parrt
10d7a79324
reorg; cleanup. added ast.g ptr setting to nodes created during left-recursion elim.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8915]
2011-07-27 17:03:54 -08:00
parrt
2136287966
tweak
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8911]
2011-07-27 15:55:30 -08:00
parrt
078e2ab47c
java.g working again.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8910]
2011-07-26 10:56:24 -08:00
parrt
fd3f8b17c9
~sets weren't working; got closer to java.g working again.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8909]
2011-07-25 18:09:00 -08:00
parrt
c6fa2fce6e
decided to clean up a bit, backtracking from updating current to have inner/outer context. will try with full ctx again.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8908]
2011-07-25 16:49:33 -08:00
parrt
a29feac1bf
a bit of clean up
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8906]
2011-07-24 16:18:21 -08:00
parrt
613c802c8c
rm dead code
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8905]
2011-07-24 15:26:52 -08:00
parrt
b4b02bb813
cleaned up atn construction / set detection / unit tests. still not done full context in parser simulation
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8904]
2011-07-24 15:25:17 -08:00
parrt
1fcc12a7ad
changes to ATN simulator just before I try adding context back in.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8903]
2011-07-24 13:20:49 -08:00
parrt
66da1f723a
got unit tests working again for interp; got args funcs in output
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8902]
2011-07-24 11:48:43 -08:00
parrt
3b52eb4e6a
snapshot
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8899]
2011-07-22 17:19:26 -08:00
parrt
40f9e867cd
23 import grammar unit tests pass
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8896]
2011-07-20 18:55:23 -08:00
parrt
5ffe679514
part of rename
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8870]
2011-07-16 15:47:01 -08:00
parrt
90a4bd9c41
rename
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8869]
2011-07-16 15:46:08 -08:00
parrt
c3f5bbed37
wasn't chked out
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8868]
2011-07-16 15:45:20 -08:00
parrt
7a109d29d5
added a LexerInterpreter and copied in unit tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8867]
2011-07-16 12:57:25 -08:00
parrt
b9ef4f9bee
woot! new visitor does away with BasicSemanticTriggers.g and Refs.g
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8861]
2011-07-14 19:25:08 -08:00
parrt
42f6b7cf86
after much bullshit, got sets working for ast stuff.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8855]
2011-07-13 17:29:20 -08:00
parrt
1dc598c26e
got lots more rewrite ast done including predicates
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8850]
2011-07-10 17:07:07 -08:00
parrt
f8abf5d40b
A B+ -> ^(A B)* works! fixed ant build
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8838]
2011-07-06 13:42:35 -08:00
parrt
07161bffe7
major reorg to get rewrites in there
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8821]
2011-07-02 16:04:56 -08:00
parrt
919e3a1c06
Small optimization
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8820]
2011-07-02 11:28:30 -08:00
parrt
ab8d07d82f
got started on rewrite stuff
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8817]
2011-07-01 14:01:53 -08:00
parrt
b9daa3763c
using old ast op code from v3. works fine.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8812]
2011-06-30 12:11:32 -08:00
parrt
1775feffdb
update copyright
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8798]
2011-06-29 11:22:17 -08:00
parrt
9da8639ba8
got AST construction ops working it seems.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8797]
2011-06-29 10:42:23 -08:00
parrt
68cef48483
cleaned up; mv'd stuff to parser. reorg to have lexer in controller
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8794]
2011-06-28 17:51:39 -08:00
parrt
15fbaccb6d
reorg to get walking of rules out of default factory into controller
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8790]
2011-06-28 15:18:39 -08:00
parrt
1510686b02
runtime no longer depends on tool module
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8787]
2011-06-28 11:51:21 -08:00
parrt
87c727e91f
change rule to ruleIndex in Rule; tests pass
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8786]
2011-06-28 11:37:45 -08:00
parrt
9bc02bfd33
no tool depends now in ATN, moved some maps to arrays :)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8779]
2011-06-27 18:46:21 -08:00
parrt
4d04b21999
removed Rule depend from ATN
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8778]
2011-06-27 17:53:11 -08:00
parrt
ad98d17191
snapshot; removed some dependencies to tool in runtime; made sure java grammar / parser still works
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8777]
2011-06-27 17:38:15 -08:00
parrt
046b469f8e
got all locals into return struct. all vars are visible to invoked rules via $rule::attr now.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8757]
2011-06-23 17:29:51 -08:00
parrt
d8edb713ed
initial wack at args/return value object
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8743]
2011-06-22 18:04:29 -08:00
parrt
c607e66f1a
added demo target X.stg
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8729]
2011-06-22 15:03:47 -08:00
parrt
4e3fd8446d
removed state stuff
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8726]
2011-06-22 14:45:28 -08:00
parrt
315944694f
mv file
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8688]
2011-06-20 17:54:54 -08:00
parrt
d6e4d5fb42
fix from 3.4
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8671]
2011-06-19 12:26:08 -08:00
parrt
1d6ce54816
tweak token consts.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8668]
2011-06-18 15:08:43 -08:00
parrt
da633613a7
all rule indexes are 0-based now; 0..n-1 not 1..n
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8667]
2011-06-18 15:06:49 -08:00
parrt
bd5df8ed53
ok, working on java again...same functionality as antlr-rewrite dir. ready to move forward
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8664]
2011-06-18 11:10:03 -08:00
parrt
1a17eb3be1
get to compile
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8662]
2011-06-18 10:35:31 -08:00
parrt
1a43396d3b
adding new files
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8660]
2011-06-17 16:07:39 -08:00
parrt
061fff09f9
adding new files
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8659]
2011-06-17 16:05:00 -08:00
parrt
2ddeb7c769
adding new files
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8658]
2011-06-17 15:42:21 -08:00
parrt
55f384237b
add initial antlr4 files (mainly runtime)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 8636]
2011-06-14 16:22:05 -08:00
parrt
36fb229434
Rename/move file(s) from old antlr4 to antlr-rewrite; that's not antlr4 anymore
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 7912]
2011-03-26 11:33:02 -08:00
parrt
4b71c478c1
huge update; preds in lexers
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6911]
2010-06-15 14:06:56 -08:00
parrt
c18898a917
PDA for lexers are too slow; working DFA back in. DFA construction was nondeterministic due to sets not ordered sets.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6909]
2010-06-10 15:24:09 -08:00
parrt
a017bb8feb
NOT eval was messed up; handles java lexer now (slowly)
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6905]
2010-06-08 16:34:07 -08:00
parrt
98bddc4446
got unicode and escape sequences into literals for bytecodes
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6904]
2010-06-08 11:49:31 -08:00
parrt
b9a5cf8691
range16 was hosed; got java lexer working
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6903]
2010-06-05 16:15:20 -08:00
parrt
de380d2fd1
got DFA interp working from parser grammar + unit tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6902]
2010-05-28 12:17:17 -08:00
parrt
19aecd3163
added NOT/SET ops, refactored PDA generation
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6900]
2010-05-27 16:01:55 -08:00
parrt
acf962bc28
initial DFA -> PDA compilation
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6899]
2010-05-26 17:34:28 -08:00
parrt
3fe028ecc4
got mode methods in
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6896]
2010-05-26 13:08:20 -08:00
parrt
ca8ea6feea
hacking with Oliver Z. Lots of fixes to code gen and sync/error handling/mode stuff.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6894]
2010-05-25 15:54:31 -08:00
parrt
f89ad35e1b
fix clone in bit set
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6888]
2010-05-23 16:53:06 -08:00
parrt
8ee1042f03
added start rule; fixed error recovery set stuff
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6887]
2010-05-23 16:41:44 -08:00
parrt
eaaa98bde9
got sync in
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6883]
2010-05-22 12:23:36 -08:00
parrt
03d9f0ba32
Got rid of the fields listed in the output model object hierarchy; created the exception throwing templates
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6882]
2010-05-22 10:27:11 -08:00
parrt
bf92a4bc73
updated errors to be listener
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6881]
2010-05-21 17:25:15 -08:00
parrt
b315dd4ae4
reorg snapshot; separate LexerSharedState; pass ctx as arg to funcctions
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6874]
2010-05-18 14:10:31 -08:00
parrt
e1ccf08680
Implemented token vocab option
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6873]
2010-05-17 15:10:53 -08:00
parrt
118d225066
got actions into lexer; reorg'd
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6872]
2010-05-17 13:28:04 -08:00
parrt
f5cc4efc1b
got basic lexers generated
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6871]
2010-05-16 15:00:56 -08:00
parrt
563de77ec4
move exceptions over from v3 runtime. add bitset defs..
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6869]
2010-05-16 12:14:05 -08:00
parrt
5a1607e884
merged args/retvals into one object
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6867]
2010-05-14 14:22:04 -08:00
parrt
161dd26006
got rule scope going
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6866]
2010-05-13 18:10:13 -08:00
parrt
62aa952f34
optimization: don't add intermediate closure addrs to closure; we ignore them during reach anyway. saves time/space.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6840]
2010-05-05 11:22:22 -08:00
parrt
27d9f25ec2
simplified label computation
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6839]
2010-05-04 12:04:49 -08:00
parrt
b0ca11f46b
got sempreds in
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6838]
2010-05-04 11:17:29 -08:00
parrt
e6d65be27b
rewinds now and does with feeling for actions in rules
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6837]
2010-05-03 17:02:47 -08:00
parrt
cf7a730b31
reworked how i assign label indexes
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6836]
2010-05-03 16:14:20 -08:00
parrt
9c03c08ba0
added comment
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6835]
2010-05-02 17:16:14 -08:00
parrt
689687f0ed
reorg so instrs in separate package. added label/save; added code gen at least for actions/sempred.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6834]
2010-05-02 17:11:30 -08:00
parrt
61603d18a9
more tests, fixes ANTLR-189. recursion works; rewinds properly.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6833]
2010-05-01 13:48:25 -08:00
parrt
16ad680adb
recursive calls work
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6832]
2010-05-01 13:23:08 -08:00
parrt
f6f444db52
got QID calling ID working
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6831]
2010-05-01 13:10:49 -08:00
parrt
f3e6d4644d
got INT calls DIGIT working
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6830]
2010-05-01 12:46:47 -08:00
parrt
9dbc6a43fd
added exec version that handles stack and new ThreadState / context. unit tests
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6829]
2010-05-01 11:38:18 -08:00
parrt
541350bbe3
handles nongreedy + and * loops. rewinds properly to last good accept if we kept going and failed.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6828]
2010-04-30 17:37:07 -08:00
parrt
6b55114dd0
got it to kill all addrs within a rule once we hit its accept state; needed for nongreedy loops.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6827]
2010-04-30 16:54:38 -08:00
parrt
43278cf701
added SAVE, WILDCARD
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6826]
2010-04-30 14:21:00 -08:00
parrt
7cf42fe4dd
reorg a bit
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6825]
2010-04-30 13:54:10 -08:00
parrt
a576c16905
got thompson's working it seems
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6823]
2010-04-29 17:33:29 -08:00
parrt
0516292911
got basic NFA code gen and interp working
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6822]
2010-04-29 11:37:11 -08:00
parrt
3015778202
added in NFA VM prototype
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6820]
2010-04-22 13:07:16 -08:00
parrt
309cb6d623
add missing
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6739]
2010-03-07 11:21:56 -08:00
parrt
d7bda19fd1
more work on NFA
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6735]
2010-03-04 15:56:47 -08:00
parrt
e38535a9bc
got attribute checks done
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6693]
2010-02-15 12:55:04 -08:00
parrt
b3f7c8e3cc
got more symbol resolution in
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6687]
2010-02-11 13:57:38 -08:00
parrt
e825a77466
made listener for action splitter
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6686]
2010-02-11 11:17:29 -08:00
parrt
795df39aaa
finished LABEL_TYPE_CONFLICT
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6676]
2010-02-07 15:22:46 -08:00
parrt
09eb3b5753
split AST for combined grammar into two, copying to lexer grammar.
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6669]
2010-02-06 14:58:26 -08:00
parrt
d81ae7478d
refactored. checking for illegal token ref
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6646]
2010-01-31 17:02:41 -08:00
parrt
f04dab7b83
got error message stuff in better shape. started semantics pipeline
...
[git-p4: depot-paths = "//depot/code/antlr4/main/": change = 6631]
2010-01-30 14:30:02 -08:00