Home
last modified time | relevance | path

Searched refs:lexer (Results 1 – 25 of 723) sorted by relevance

12345678910>>...29

/external/antlr/runtime/C/src/
Dantlr3lexer.c42 static void mTokens (pANTLR3_LEXER lexer);
43 static void setCharStream (pANTLR3_LEXER lexer, pANTLR3_INPUT_STREAM input);
44 static void pushCharStream (pANTLR3_LEXER lexer, pANTLR3_INPUT_STREAM input);
45 static void popCharStream (pANTLR3_LEXER lexer);
47 static void emitNew (pANTLR3_LEXER lexer, pANTLR3_COMMON_TOKEN token);
48 static pANTLR3_COMMON_TOKEN emit (pANTLR3_LEXER lexer);
49 static ANTLR3_BOOLEAN matchs (pANTLR3_LEXER lexer, ANTLR3_UCHAR * string);
50 static ANTLR3_BOOLEAN matchc (pANTLR3_LEXER lexer, ANTLR3_UCHAR c);
51 static ANTLR3_BOOLEAN matchRange (pANTLR3_LEXER lexer, ANTLR3_UCHAR low, ANTLR3_UCHAR high);
52 static void matchAny (pANTLR3_LEXER lexer);
[all …]
/external/nist-sip/java/gov/nist/javax/sip/parser/
DViaParser.java47 public ViaParser(Lexer lexer) { in ViaParser() argument
48 super(lexer); in ViaParser()
56 lexer.match(TokenTypes.ID); in parseVia()
57 Token protocolName = lexer.getNextToken(); in parseVia()
59 this.lexer.SPorHT(); in parseVia()
61 lexer.match('/'); in parseVia()
62 this.lexer.SPorHT(); in parseVia()
63 lexer.match(TokenTypes.ID); in parseVia()
64 this.lexer.SPorHT(); in parseVia()
65 Token protocolVersion = lexer.getNextToken(); in parseVia()
[all …]
DURLParser.java50 this.lexer = new Lexer("sip_urlLexer", url); in URLParser()
54 public URLParser(Lexer lexer) { in URLParser() argument
55 this.lexer = lexer; in URLParser()
56 this.lexer.selectLexer("sip_urlLexer"); in URLParser()
116 char next = lexer.lookAhead(0); in unreserved()
118 lexer.consume(1); in unreserved()
128 int startIdx = lexer.getPtr(); in paramNameOrValue()
129 while (lexer.hasMoreChars()) { in paramNameOrValue()
130 char next = lexer.lookAhead(0); in paramNameOrValue()
143 lexer.consume(1); in paramNameOrValue()
[all …]
DWarningParser.java63 protected WarningParser(Lexer lexer) { in WarningParser() argument
64 super(lexer); in WarningParser()
82 while (lexer.lookAhead(0) != '\n') { in parse()
87 this.lexer.match(TokenTypes.ID); in parse()
88 Token token = lexer.getNextToken(); in parse()
97 this.lexer.SPorHT(); in parse()
100 this.lexer.match(TokenTypes.ID); in parse()
101 token = lexer.getNextToken(); in parse()
103 if (lexer.lookAhead(0) == ':') { in parse()
104 this.lexer.match(':'); in parse()
[all …]
DSubscriptionStateParser.java56 protected SubscriptionStateParser(Lexer lexer) { in SubscriptionStateParser() argument
57 super(lexer); in SubscriptionStateParser()
77 lexer.match(TokenTypes.ID); in parse()
78 Token token = lexer.getNextToken(); in parse()
81 while (lexer.lookAhead(0) == ';') { in parse()
82 this.lexer.match(';'); in parse()
83 this.lexer.SPorHT(); in parse()
84 lexer.match(TokenTypes.ID); in parse()
85 token = lexer.getNextToken(); in parse()
88 this.lexer.match('='); in parse()
[all …]
DAddressParser.java40 public AddressParser(Lexer lexer) { in AddressParser() argument
41 this.lexer = lexer; in AddressParser()
42 this.lexer.selectLexer("charLexer"); in AddressParser()
46 this.lexer = new Lexer("charLexer", address); in AddressParser()
53 if (this.lexer.lookAhead(0) == '<') { in nameAddr()
54 this.lexer.consume(1); in nameAddr()
55 this.lexer.selectLexer("sip_urlLexer"); in nameAddr()
56 this.lexer.SPorHT(); in nameAddr()
57 URLParser uriParser = new URLParser((Lexer) lexer); in nameAddr()
62 this.lexer.SPorHT(); in nameAddr()
[all …]
DAcceptLanguageParser.java74 protected AcceptLanguageParser(Lexer lexer) { in AcceptLanguageParser() argument
75 super(lexer); in AcceptLanguageParser()
91 while (lexer.lookAhead(0) != '\n') { in parse()
94 if (lexer.lookAhead(0) != ';') { in parse()
96 lexer.match(TokenTypes.ID); in parse()
97 Token value = lexer.getNextToken(); in parse()
101 while (lexer.lookAhead(0) == ';') { in parse()
102 this.lexer.match(';'); in parse()
103 this.lexer.SPorHT(); in parse()
104 this.lexer.match('q'); in parse()
[all …]
DRetryAfterParser.java58 protected RetryAfterParser(Lexer lexer) { in RetryAfterParser() argument
59 super(lexer); in RetryAfterParser()
77 String value = lexer.number(); in parse()
87 this.lexer.SPorHT(); in parse()
88 if (lexer.lookAhead(0) == '(') { in parse()
89 String comment = this.lexer.comment(); in parse()
92 this.lexer.SPorHT(); in parse()
94 while (lexer.lookAhead(0) == ';') { in parse()
95 this.lexer.match(';'); in parse()
96 this.lexer.SPorHT(); in parse()
[all …]
DAcceptEncodingParser.java77 protected AcceptEncodingParser(Lexer lexer) { in AcceptEncodingParser() argument
78 super(lexer); in AcceptEncodingParser()
94 if (lexer.lookAhead(0) == '\n') { in parse()
98 while (lexer.lookAhead(0) != '\n') { in parse()
100 if (lexer.lookAhead(0) != ';') { in parse()
102 lexer.match(TokenTypes.ID); in parse()
103 Token value = lexer.getNextToken(); in parse()
107 while (lexer.lookAhead(0) == ';') { in parse()
108 this.lexer.match(';'); in parse()
109 this.lexer.SPorHT(); in parse()
[all …]
DInReplyToParser.java56 protected InReplyToParser(Lexer lexer) { in InReplyToParser() argument
57 super(lexer); in InReplyToParser()
74 while (lexer.lookAhead(0) != '\n') { in parse()
78 this.lexer.match(TokenTypes.ID); in parse()
79 Token token = lexer.getNextToken(); in parse()
80 if (lexer.lookAhead(0) == '@') { in parse()
81 this.lexer.match('@'); in parse()
82 this.lexer.match(TokenTypes.ID); in parse()
83 Token secToken = lexer.getNextToken(); in parse()
90 this.lexer.SPorHT(); in parse()
[all …]
DAcceptParser.java56 protected AcceptParser(Lexer lexer) { in AcceptParser() argument
57 super(lexer); in AcceptParser()
77 this.lexer.SPorHT(); in parse()
78 this.lexer.match(TokenTypes.ID); in parse()
79 Token token = lexer.getNextToken(); in parse()
81 this.lexer.match('/'); in parse()
82 this.lexer.match(TokenTypes.ID); in parse()
83 token = lexer.getNextToken(); in parse()
85 this.lexer.SPorHT(); in parse()
90 while (lexer.lookAhead(0) == ',') { in parse()
[all …]
DCallInfoParser.java55 protected CallInfoParser(Lexer lexer) { in CallInfoParser() argument
56 super(lexer); in CallInfoParser()
72 while (lexer.lookAhead(0) != '\n') { in parse()
76 this.lexer.SPorHT(); in parse()
77 this.lexer.match('<'); in parse()
78 URLParser urlParser=new URLParser((Lexer)this.lexer); in parse()
81 this.lexer.match('>'); in parse()
82 this.lexer.SPorHT(); in parse()
87 while (lexer.lookAhead(0) == ',') { in parse()
88 this.lexer.match(','); in parse()
[all …]
/external/antlr/runtime/Ruby/test/functional/lexer/
Dbasic.rb18 lexer = Zero::Lexer.new( '0' )
20 token = lexer.next_token
23 token = lexer.next_token
28 lexer = Zero::Lexer.new( '0' )
30 token_types = lexer.map { |token| token.name }
35 lexer = Zero::Lexer.new( '1' )
38 token = lexer.next_token
60 lexer = Binary::Lexer.new( '01' )
62 token = lexer.next_token
65 token = lexer.next_token
[all …]
/external/pdfium/xfa/fxfa/fm2js/
Dcxfa_fmlexer_unittest.cpp14 CXFA_FMLexer lexer(L""); in TEST() local
15 std::unique_ptr<CXFA_FMToken> token = lexer.NextToken(); in TEST()
20 auto lexer = pdfium::MakeUnique<CXFA_FMLexer>(L"-12"); in TEST() local
21 std::unique_ptr<CXFA_FMToken> token = lexer->NextToken(); in TEST()
24 token = lexer->NextToken(); in TEST()
26 token = lexer->NextToken(); in TEST()
29 lexer = pdfium::MakeUnique<CXFA_FMLexer>(L"1.5362"); in TEST()
30 token = lexer->NextToken(); in TEST()
34 lexer = pdfium::MakeUnique<CXFA_FMLexer>(L"0.875"); in TEST()
35 token = lexer->NextToken(); in TEST()
[all …]
/external/antlr/runtime/Python/tests/
Dt025lexerRulePropertyRef.py13 lexer = self.getLexer(stream)
16 token = lexer.nextToken()
20 assert len(lexer.properties) == 3, lexer.properties
22 text, type, line, pos, index, channel, start, stop = lexer.properties[0]
23 assert text == 'foobar', lexer.properties[0]
24 assert type == self.lexerModule.IDENTIFIER, lexer.properties[0]
25 assert line == 1, lexer.properties[0]
26 assert pos == 0, lexer.properties[0]
27 assert index == -1, lexer.properties[0]
28 assert channel == antlr3.DEFAULT_CHANNEL, lexer.properties[0]
[all …]
/external/nist-sip/java/gov/nist/core/
DHostNameParser.java66 this.lexer = new LexerCore("charLexer", hname); in HostNameParser()
75 public HostNameParser(LexerCore lexer) { in HostNameParser() argument
76 this.lexer = lexer; in HostNameParser()
77 lexer.selectLexer("charLexer"); in HostNameParser()
89 lexer.consumeValidChars(VALID_DOMAIN_LABEL_CHAR); in consumeDomainLabel()
104 while (lexer.hasMoreChars()) { in ipv6Reference()
105 char la = lexer.lookAhead(0); in ipv6Reference()
110 lexer.consume(1); in ipv6Reference()
113 lexer.consume(1); in ipv6Reference()
118 lexer.consume(1); in ipv6Reference()
[all …]
/external/antlr/runtime/Python3/tests/
Dt025lexerRulePropertyRef.py13 lexer = self.getLexer(stream)
16 token = lexer.nextToken()
20 self.assertEqual(len(lexer.properties), 3, lexer.properties)
22 text, type, line, pos, index, channel, start, stop = lexer.properties[0]
23 self.assertEqual(text, 'foobar', lexer.properties[0])
24 self.assertEqual(type, self.lexerModule.IDENTIFIER, lexer.properties[0])
25 self.assertEqual(line, 1, lexer.properties[0])
26 self.assertEqual(pos, 0, lexer.properties[0])
27 self.assertEqual(index, -1, lexer.properties[0])
28 self.assertEqual(channel, antlr3.DEFAULT_CHANNEL, lexer.properties[0])
[all …]
/external/antlr/runtime/Ruby/test/functional/ast-output/
Dtree-rewrite.rb1005 lexer = FlatList::Lexer.new( "abc 34" )
1006 tokens = ANTLR3::CommonTokenStream.new( lexer )
1019 lexer = SimpleTree::Lexer.new( "abc 34" )
1020 tokens = ANTLR3::CommonTokenStream.new( lexer )
1033 lexer = CombinedRewriteAndAuto::Lexer.new( "abc 34" )
1034 tokens = ANTLR3::CommonTokenStream.new( lexer )
1043 lexer = CombinedRewriteAndAuto::Lexer.new( "34" )
1044 tokens = ANTLR3::CommonTokenStream.new( lexer )
1056 lexer = AvoidDup::Lexer.new( "abc" )
1057 tokens = ANTLR3::CommonTokenStream.new( lexer )
[all …]
/external/antlr/runtime/Ruby/test/functional/parser/
Dscopes.rb30 lexer = SimpleScope::Lexer.new( 'foobar' )
31 parser = SimpleScope::Parser.new lexer
178 lexer = LotsaScopes::Lexer.new( "foobar" )
179 parser = LotsaScopes::Parser.new lexer
184 lexer = LotsaScopes::Lexer.new( "foobar" )
185 parser = LotsaScopes::Parser.new lexer
190 lexer = LotsaScopes::Lexer.new( "foobar" )
191 parser = LotsaScopes::Parser.new lexer
196 lexer = LotsaScopes::Lexer.new( <<-END.here_indent! )
203 parser = LotsaScopes::Parser.new lexer
[all …]
Dnuances.rb28 lexer = EmptyAlt::Lexer.new( 'foo' )
29 parser = EmptyAlt::Parser.new lexer
58 lexer = Subrule::Lexer.new( 'BEGIN A END' )
59 parser = Subrule::Parser.new lexer
95 lexer = SpecialStates::Lexer.new 'foo'
96 parser = SpecialStates::Parser.new lexer
101 lexer = SpecialStates::Lexer.new 'foo name1'
102 parser = SpecialStates::Parser.new lexer
107 lexer = SpecialStates::Lexer.new 'bar name1'
108 parser = SpecialStates::Parser.new lexer
[all …]
/external/antlr/runtime/Ruby/test/functional/tree-parser/
Dbasic.rb32 lexer = FlatList::Lexer.new( "abc 34" )
33 tokens = ANTLR3::CommonTokenStream.new( lexer )
68 lexer = SimpleTree::Lexer.new( "abc 34" )
69 tokens = ANTLR3::CommonTokenStream.new( lexer )
107 lexer = FlatVsTreeDecision::Lexer.new( "a 1 b 2" )
108 tokens = ANTLR3::CommonTokenStream.new( lexer )
145 lexer = FlatVsTreeDecision2::Lexer.new( "a 1 2 3 b 4 5" )
146 tokens = ANTLR3::CommonTokenStream.new( lexer )
182 lexer = CyclicDFALookahead::Lexer.new( "a 1 2 3." )
183 tokens = ANTLR3::CommonTokenStream.new( lexer )
[all …]
/external/ply/ply/example/yply/
Dylex.py36 if getattr(t.lexer, "lastsection", 0):
37 t.value = t.lexer.lexdata[t.lexpos + 2:]
38 t.lexer.lexpos = len(t.lexer.lexdata)
40 t.lexer.lastsection = 0
48 t.lexer.lineno += t.value.count('\n')
55 t.lexer.lineno += t.value.count("\n")
61 t.lexer.lineno += 1
66 t.lexer.codestart = t.lexpos
67 t.lexer.level = 1
68 t.lexer.begin('code')
[all …]
/external/nist-sip/java/gov/nist/javax/sip/parser/ims/
DSecurityAgreeParser.java61 protected SecurityAgreeParser(Lexer lexer) { in SecurityAgreeParser() argument
62 super(lexer); in SecurityAgreeParser()
98 this.lexer.SPorHT(); in parse()
99 lexer.match(TokenTypes.ID); in parse()
100 Token type = lexer.getNextToken(); in parse()
102 this.lexer.SPorHT(); in parse()
104 char la = lexer.lookAhead(0); in parse()
111 this.lexer.match(';'); in parse()
113 this.lexer.SPorHT(); in parse()
117 while (lexer.lookAhead(0) != '\n') { in parse()
[all …]
/external/python/cpython3/Lib/
Dnetrc.py33 lexer = shlex.shlex(fp)
34 lexer.wordchars += r"""!"#$%&'()*+,-./:;<=>?@[\]^_`{|}~"""
35 lexer.commenters = lexer.commenters.replace('#', '')
38 saved_lineno = lexer.lineno
39 toplevel = tt = lexer.get_token()
43 if lexer.lineno == saved_lineno and len(tt) == 1:
44 lexer.instream.readline()
47 entryname = lexer.get_token()
51 entryname = lexer.get_token()
53 lexer.whitespace = ' \t'
[all …]
/external/antlr/runtime/C/include/
Dantlr3lexer.h110 void (*setCharStream) (struct ANTLR3_LEXER_struct * lexer, pANTLR3_INPUT_STREAM input);
116 void (*pushCharStream) (struct ANTLR3_LEXER_struct * lexer, pANTLR3_INPUT_STREAM input);
121 void (*popCharStream) (struct ANTLR3_LEXER_struct * lexer);
126 void (*emitNew) (struct ANTLR3_LEXER_struct * lexer, pANTLR3_COMMON_TOKEN token);
130 pANTLR3_COMMON_TOKEN (*emit) (struct ANTLR3_LEXER_struct * lexer);
145 ANTLR3_BOOLEAN (*matchs) (struct ANTLR3_LEXER_struct * lexer, ANTLR3_UCHAR * string);
152 ANTLR3_BOOLEAN (*matchc) (struct ANTLR3_LEXER_struct * lexer, ANTLR3_UCHAR c);
158 …ANTLR3_BOOLEAN (*matchRange) (struct ANTLR3_LEXER_struct * lexer, ANTLR3_UCHAR low, ANTLR3_UCH…
163 void (*matchAny) (struct ANTLR3_LEXER_struct * lexer);
169 void (*recover) (struct ANTLR3_LEXER_struct * lexer);
[all …]

12345678910>>...29