Home
last modified time | relevance | path

Searched refs:antlr (Results 1 – 25 of 553) sorted by relevance

12345678910>>...23

/external/antlr/runtime/JavaScript/build/
Dantlr3.properties9 org/antlr.js,\
10 org/antlr/runtime/RecognizerSharedState.js,\
11 org/antlr/runtime/IndexOutOfBoundsExceptions.js,\
12 org/antlr/runtime/RecognitionException.js,\
13 org/antlr/runtime/MismatchedTokenException.js,\
14 org/antlr/runtime/UnwantedTokenException.js,\
15 org/antlr/runtime/MissingTokenException.js,\
16 org/antlr/runtime/NoViableAltException.js,\
17 org/antlr/runtime/EarlyExitException.js,\
18 org/antlr/runtime/MismatchedSetException.js,\
[all …]
/external/antlr/runtime/JavaScript/src/org/antlr/runtime/
DBitSet.js14 org.antlr.runtime.BitSet = function(bits) {
16 bits = org.antlr.runtime.BitSet.BITS;
19 if (org.antlr.lang.isArray(bits)) {
25 } else if(org.antlr.lang.isNumber(bits)) {
30 org.antlr.lang.augmentObject(org.antlr.runtime.BitSet, {
66 var bitPosition = bitNumber & org.antlr.runtime.BitSet.MOD_MASK;
79 return (el >> org.antlr.runtime.BitSet.LOG_BITS) + 1;
90 return bit >> org.antlr.runtime.BitSet.LOG_BITS; // bit / BITS
116 if (org.antlr.lang.isNumber(el)) {
117 if (org.antlr.lang.isNumber(el2)) {
[all …]
DLexer.js6 org.antlr.runtime.Lexer = function(input, state) {
8 org.antlr.runtime.Lexer.superclass.constructor.call(this, state);
15 org.antlr.lang.extend(org.antlr.runtime.Lexer, org.antlr.runtime.BaseRecognizer, {
18 org.antlr.runtime.Lexer.superclass.reset.call(this);
19 if ( org.antlr.lang.isValue(this.input) ) {
22 if ( !org.antlr.lang.isValue(this.state) ) {
26 this.state.type = org.antlr.runtime.Token.INVALID_TOKEN_TYPE;
27 this.state.channel = org.antlr.runtime.Token.DEFAULT_CHANNEL;
40 this.state.channel = org.antlr.runtime.Token.DEFAULT_CHANNEL;
45 if ( this.input.LA(1)===org.antlr.runtime.CharStream.EOF ) {
[all …]
DBaseRecognizer.js13 org.antlr.runtime.BaseRecognizer = function(state) {
21 this.state = state || new org.antlr.runtime.RecognizerSharedState();
24 org.antlr.lang.augmentObject(org.antlr.runtime.BaseRecognizer, {
53 DEFAULT_TOKEN_CHANNEL: org.antlr.runtime.Token.DEFAULT_CHANNEL,
59 HIDDEN: org.antlr.runtime.Token.HIDDEN_CHANNEL,
68 org.antlr.runtime.BaseRecognizer.prototype = {
161 if ( follow.member(org.antlr.runtime.Token.EOR_TOKEN_TYPE) ) {
165 follow.remove(org.antlr.runtime.Token.EOR_TOKEN_TYPE);
176 follow.member(org.antlr.runtime.Token.EOR_TOKEN_TYPE) )
194 throw new org.antlr.runtime.UnwantedTokenException(ttype, input);
[all …]
DCommonTokenStream.js8 org.antlr.runtime.CommonTokenStream = function(tokenSource, channel) {
10 this.channel = org.antlr.runtime.Token.DEFAULT_CHANNEL;
20 org.antlr.runtime.TokenStream = function() {};
22 org.antlr.lang.extend(org.antlr.runtime.CommonTokenStream,
23 org.antlr.runtime.TokenStream,
30 this.channel = org.antlr.runtime.Token.DEFAULT_CHANNEL;
42 while ( org.antlr.lang.isValue(t) &&
43 t.getType()!=org.antlr.runtime.CharStream.EOF )
49 if ( org.antlr.lang.isValue(channelI) ) {
143 if (org.antlr.lang.isArray(types)) {
[all …]
DCommonToken.js1 org.antlr.runtime.CommonToken = function() {
9 if (org.antlr.lang.isNumber(arguments[0])) {
19 if ( oldToken instanceof org.antlr.runtime.CommonToken ) {
37 org.antlr.lang.extend(org.antlr.runtime.CommonToken,
38 org.antlr.runtime.Token,
49 if ( org.antlr.lang.isString(this.text) ) {
130 if ( !org.antlr.lang.isNull(txt) ) {
143 org.antlr.lang.augmentObject(org.antlr.runtime.Token, {
144 EOF_TOKEN: new org.antlr.runtime.CommonToken(org.antlr.runtime.CharStream.EOF),
145 INVALID_TOKEN: new org.antlr.runtime.CommonToken(0),
[all …]
DParser.js4 org.antlr.runtime.Parser = function(input, state) {
5 org.antlr.runtime.Parser.superclass.constructor.call(this, state);
9 org.antlr.lang.extend(org.antlr.runtime.Parser, org.antlr.runtime.BaseRecognizer, {
12 org.antlr.runtime.Parser.superclass.reset.call(this);
13 if ( org.antlr.lang.isValue(this.input) ) {
29 var t = new org.antlr.runtime.CommonToken(expectedTokenType, tokenText);
32 if ( current.getType() === org.antlr.runtime.Token.EOF ) {
42 t.channel = org.antlr.runtime.BaseRecognizer.DEFAULT_TOKEN_CHANNEL;
63 org.antlr.runtime.Parser.superclass.traceIn.call(
68 org.antlr.runtime.Parser.superclass.traceOut.call(
DRecognitionException.js31 org.antlr.runtime.RecognitionException = function(input) {
32 org.antlr.runtime.RecognitionException.superclass.constructor.call(this);
35 if ( input instanceof org.antlr.runtime.TokenStream ) {
40 if ( input instanceof org.antlr.runtime.tree.TreeNodeStream ) {
43 else if ( input instanceof org.antlr.runtime.CharStream ) {
57 org.antlr.lang.extend(org.antlr.runtime.RecognitionException, Error,
151 else if ( this.node instanceof org.antlr.runtime.tree.Tree) {
154 if ( this.node instanceof org.antlr.runtime.tree.CommonTree) {
161 this.token = new org.antlr.runtime.CommonToken(type, text);
169 if ( this.input instanceof org.antlr.runtime.TokenStream ) {
[all …]
DMissingTokenException.js1 org.antlr.runtime.MissingTokenException = function(expecting, input, inserted) {
3 org.antlr.runtime.MissingTokenException.superclass.constructor.call(
9 org.antlr.lang.extend(
10 org.antlr.runtime.MissingTokenException,
11 org.antlr.runtime.MismatchedTokenException, {
17 if (org.antlr.lang.isValue(this.inserted) &&
18 org.antlr.lang.isValue(this.token))
22 if ( org.antlr.lang.isValue(this.token) ) {
/external/antlr/tool/src/test/java/org/antlr/test/
DTestAttributes.java28 package org.antlr.test;
30 import org.antlr.Tool;
31 import org.antlr.codegen.CodeGenerator;
32 import org.antlr.grammar.v3.ANTLRParser;
33 import org.antlr.grammar.v3.ActionTranslator;
34 import org.antlr.runtime.CommonToken;
37 import org.antlr.tool.*;
58 Tool antlr = newTool(); in testEscapedLessThanInAction() local
59 CodeGenerator generator = new CodeGenerator(antlr, g, "Java"); in testEscapedLessThanInAction()
83 Tool antlr = newTool(); in testEscaped$InAction() local
[all …]
DTestTemplates.java28 package org.antlr.test;
30 import org.antlr.Tool;
31 import org.antlr.codegen.CodeGenerator;
32 import org.antlr.grammar.v3.ANTLRParser;
33 import org.antlr.grammar.v3.ActionTranslator;
34 import org.antlr.runtime.CommonToken;
37 import org.antlr.tool.ErrorManager;
38 import org.antlr.tool.Grammar;
39 import org.antlr.tool.GrammarSemanticsMessage;
40 import org.antlr.tool.Message;
[all …]
DTestMessages.java28 package org.antlr.test;
30 import org.antlr.Tool;
31 import org.antlr.codegen.CodeGenerator;
32 import org.antlr.grammar.v3.ANTLRParser;
33 import org.antlr.grammar.v3.ActionTranslator;
34 import org.antlr.runtime.CommonToken;
35 import org.antlr.tool.ErrorManager;
36 import org.antlr.tool.Grammar;
37 import org.antlr.tool.GrammarSemanticsMessage;
61 Tool antlr = newTool(); in testMessageStringificationIsConsistent() local
[all …]
DTestRewriteTemplates.java28 package org.antlr.test;
30 import org.antlr.Tool;
31 import org.antlr.codegen.CodeGenerator;
32 import org.antlr.tool.*;
250 Tool antlr = newTool(); in testRewriteRuleAndRewriteModeOnSimpleElements() local
251 antlr.setOutputDirectory(null); // write to /dev/null in testRewriteRuleAndRewriteModeOnSimpleElements()
252 CodeGenerator generator = new CodeGenerator(antlr, g, "Java"); in testRewriteRuleAndRewriteModeOnSimpleElements()
272 Tool antlr = newTool(); in testRewriteRuleAndRewriteModeIgnoreActionsPredicates() local
273 antlr.setOutputDirectory(null); // write to /dev/null in testRewriteRuleAndRewriteModeIgnoreActionsPredicates()
274 CodeGenerator generator = new CodeGenerator(antlr, g, "Java"); in testRewriteRuleAndRewriteModeIgnoreActionsPredicates()
[all …]
/external/antlr/
DREADME.txt21 http://www.antlr.org/works/index.html
25 http://www.antlr.org/wiki/display/ANTLR3/gUnit+-+Grammar+Unit+Testing
38 http://www.antlr.org/wiki/display/ANTLR3/FAQ+-+Getting+Started
44 http://www.antlr.org/wiki/display/ANTLR3/ANTLR+v3+FAQ
48 http://www.antlr.org/wiki/display/ANTLR3/ANTLR+3+Wiki+Home
52 If all else fails, you can buy support or ask the antlr-interest list:
54 http://www.antlr.org/support.html
77 https://github.com/antlr/examples-v3
93 http://www.antlr.org/wiki/display/ANTLR3/Code+Generation+Targets
101 http://www.antlr.org/wiki/pages/viewpage.action?pageId=719
[all …]
/external/antlr/runtime/JavaScript/src/org/antlr/runtime/tree/
DCommonErrorNode.js1 org.antlr.runtime.tree.CommonErrorNode = function(input, start, stop, e) {
4 stop.getType()!=org.antlr.runtime.Token.EOF) )
18 org.antlr.lang.extend(org.antlr.runtime.tree.CommonErrorNode, org.antlr.runtime.tree.CommonTree, {
24 return org.antlr.runtime.Token.INVALID_TOKEN_TYPE;
29 if ( this.start instanceof org.antlr.runtime.Token ) {
32 if ( this.stop.getType() === org.antlr.runtime.Token.EOF ) {
37 else if ( this.start instanceof org.antlr.runtime.tree.Tree ) {
49 if ( this.trappedException instanceof org.antlr.runtime.MissingTokenException ) {
54 else if ( this.trappedException instanceof org.antlr.runtime.UnwantedTokenException ) {
59 else if ( this.trappedException instanceof org.antlr.runtime.MismatchedTokenException ) {
[all …]
DCommonTreeAdaptor.js10 org.antlr.runtime.tree.CommonTreeAdaptor = function() {};
12 org.antlr.lang.extend(org.antlr.runtime.tree.CommonTreeAdaptor,
13 org.antlr.runtime.tree.BaseTreeAdaptor, {
21 if ( !org.antlr.lang.isValue(t) ) {
29 … return org.antlr.runtime.tree.CommonTreeAdaptor.superclass.create.apply(this, arguments);
31 return new org.antlr.runtime.tree.CommonTree(payload);
58 return new org.antlr.runtime.CommonToken(arguments[0], arguments[1]);
60 return new org.antlr.runtime.CommonToken(arguments[0]);
70 if ( !org.antlr.lang.isValue(t) ) {
75 if ( org.antlr.lang.isValue(startToken) ) {
[all …]
DCommonTree.js7 org.antlr.runtime.tree.CommonTree = function(node) {
23 if (node instanceof org.antlr.runtime.tree.CommonTree) {
24 org.antlr.runtime.tree.CommonTree.superclass.constructor.call(this, node);
28 } else if (node instanceof org.antlr.runtime.CommonToken) {
34 org.antlr.lang.extend(org.antlr.runtime.tree.CommonTree, org.antlr.runtime.tree.BaseTree, {
40 return new org.antlr.runtime.tree.CommonTree(this);
49 return org.antlr.runtime.Token.INVALID_TOKEN_TYPE;
123 if ( this.getType()===org.antlr.runtime.Token.INVALID_TOKEN_TYPE ) {
134 org.antlr.runtime.tree.Tree.INVALID_NODE =
135 new org.antlr.runtime.tree.CommonTree(org.antlr.runtime.Token.INVALID_TOKEN);
DCommonTreeNodeStream.js17 org.antlr.runtime.tree.CommonTreeNodeStream = function(adaptor,
23 adaptor = new org.antlr.runtime.tree.CommonTreeAdaptor();
27 org.antlr.runtime.tree.CommonTreeNodeStream.DEFAULT_INITIAL_BUFFER_SIZE;
38 var Token = org.antlr.runtime.Token;
47 org.antlr.lang.augmentObject(org.antlr.runtime.tree.CommonTreeNodeStream, {
52 org.antlr.lang.extend(org.antlr.runtime.tree.CommonTreeNodeStream,
53 org.antlr.runtime.tree.TreeNodeStream,
85 if (org.antlr.lang.isUndefined(t)) {
97 this.addNavigationNode(org.antlr.runtime.Token.DOWN);
107 this.addNavigationNode(org.antlr.runtime.Token.UP);
[all …]
DTreeParser.js5 org.antlr.runtime.tree.TreeParser = function(input) {
6 org.antlr.runtime.tree.TreeParser.superclass.constructor.call(this, arguments[1]);
11 var TP = org.antlr.runtime.tree.TreeParser;
13 org.antlr.lang.augmentObject(TP, {
14 DOWN: org.antlr.runtime.Token.DOWN,
15 UP: org.antlr.runtime.Token.UP
18 org.antlr.lang.extend(TP, org.antlr.runtime.BaseRecognizer, {
46 …return new org.antlr.runtime.tree.CommonTree(new org.antlr.runtime.CommonToken(expectedTokenType, …
65 while ( tokenType!==org.antlr.runtime.Token.EOF &&
86 throw new org.antlr.runtime.MismatchedTreeNodeException(ttype, input);
[all …]
DRewriteRuleElementStream.js14 org.antlr.runtime.tree.RewriteRuleElementStream = function(adaptor, elementDescription, el) {
33 if (org.antlr.lang.isArray(el)) {
42 org.antlr.runtime.tree.RewriteRuleElementStream.prototype = {
54 if ( !org.antlr.lang.isValue(el) ) {
61 if ( !org.antlr.lang.isValue(this.singleElement) ) { // no elements yet, track w/o list
99 throw new org.antlr.runtime.tree.RewriteEmptyStreamException(this.elementDescription);
106 throw new org.antlr.runtime.tree.RewriteCardinalityException(this.elementDescription);
109 if ( org.antlr.lang.isValue(this.singleElement) ) {
130 return (org.antlr.lang.isValue(this.singleElement) && this.cursor < 1) ||
136 if ( org.antlr.lang.isValue(this.singleElement) ) {
/external/antlr/runtime/JavaScript/src/org/
Dantlr.js13 if (typeof org.antlr == "undefined" || !org.antlr) {
20 org.antlr = {};
26 org.antlr.global = (function() {
46 org.antlr.namespace = function() {
50 o=org.antlr.global;
67 org.antlr.env = org.antlr.env || {};
80 org.antlr.env.ua = function() {
249 org.antlr.namespace("org.antlr.runtime.tree");
255 org.antlr.lang = org.antlr.lang || /** @lends org.antlr.lang */ {
268 var l = org.antlr.lang;
[all …]
/external/antlr/runtime/ObjC/Framework/examples/simplecTreeParser/
DSimpleCLexer.m4 …* - From the grammar source file : /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Frame…
14 // $ANTLR 3.4 /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/simplecTreePa…
34 …[BaseRecognizer setGrammarFileName:@"/Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framewor…
77 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/simplecTreeParser/Simpl…
78 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/simplecTreeParser/Simpl…
112 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/simplecTreeParser/Simpl…
113 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/simplecTreeParser/Simpl…
147 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/simplecTreeParser/Simpl…
148 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/simplecTreeParser/Simpl…
182 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/simplecTreeParser/Simpl…
[all …]
/external/antlr/runtime/ObjC/Framework/examples/LL-star/
DSimpleCLexer.m4 …* - From the grammar source file : /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Frame…
14 // $ANTLR 3.4 /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/LL-star/Simpl…
34 …[BaseRecognizer setGrammarFileName:@"/Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framewor…
77 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/LL-star/SimpleC.g:7:6: …
78 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/LL-star/SimpleC.g:7:8: …
111 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/LL-star/SimpleC.g:8:6: …
112 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/LL-star/SimpleC.g:8:8: …
145 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/LL-star/SimpleC.g:9:6: …
146 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/LL-star/SimpleC.g:9:8: …
179 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/LL-star/SimpleC.g:10:7:…
[all …]
/external/antlr/runtime/ObjC/Framework/examples/fuzzy/
DFuzzy.m4 …* - From the grammar source file : /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Frame…
14 // $ANTLR 3.4 /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/fuzzy/Fuzzy.g…
34 …[BaseRecognizer setGrammarFileName:@"/Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framewor…
145 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/fuzzy/Fuzzy.g:5:2: ( 'i…
146 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/fuzzy/Fuzzy.g:5:4: 'imp…
167 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/fuzzy/Fuzzy.g:5:29: ( W…
176 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/fuzzy/Fuzzy.g:5:29: WS …
220 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/fuzzy/Fuzzy.g:10:2: ( '…
221 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/fuzzy/Fuzzy.g:10:4: 're…
243 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/fuzzy/Fuzzy.g:10:38: . …
[all …]
/external/antlr/runtime/ObjC/Framework/examples/scopes/
DSymbolTableLexer.m4 …* - From the grammar source file : /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Frame…
14 // $ANTLR 3.4 /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/scopes/Symbol…
34 …[BaseRecognizer setGrammarFileName:@"/Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framewor…
77 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/scopes/SymbolTable.g:7:…
78 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/scopes/SymbolTable.g:7:…
111 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/scopes/SymbolTable.g:8:…
112 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/scopes/SymbolTable.g:8:…
145 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/scopes/SymbolTable.g:9:…
146 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/scopes/SymbolTable.g:9:…
179 …// /Users/acondit/source/antlr/code/antlr3/runtime/ObjC/Framework/examples/scopes/SymbolTable.g:10…
[all …]

12345678910>>...23