Home
last modified time | relevance | path

Searched refs:Token (Results 1 – 25 of 641) sorted by relevance

12345678910>>...26

/third_party/skia/third_party/externals/tint/src/reader/wgsl/
Dtoken.cc22 std::string Token::TypeToName(Type type) { in TypeToName()
24 case Token::Type::kError: in TypeToName()
26 case Token::Type::kEOF: in TypeToName()
28 case Token::Type::kIdentifier: in TypeToName()
30 case Token::Type::kFloatLiteral: in TypeToName()
32 case Token::Type::kSintLiteral: in TypeToName()
34 case Token::Type::kUintLiteral: in TypeToName()
36 case Token::Type::kUninitialized: in TypeToName()
39 case Token::Type::kAnd: in TypeToName()
41 case Token::Type::kAndAnd: in TypeToName()
[all …]
Dlexer.cc63 Token Lexer::next() { in next()
99 return {Token::Type::kError, begin_source(), "invalid character found"}; in next()
141 Token Lexer::skip_whitespace_and_comments() { in skip_whitespace_and_comments()
167 return {Token::Type::kEOF, begin_source()}; in skip_whitespace_and_comments()
173 Token Lexer::skip_comment() { in skip_comment()
218 return {Token::Type::kError, source, "unterminated block comment"}; in skip_comment()
224 Token Lexer::try_float() { in try_float()
270 return {Token::Type::kError, source, in try_float()
300 return {Token::Type::kError, source, in try_float()
305 return {Token::Type::kError, source, in try_float()
[all …]
Dlexer_test.cc123 ASSERT_TRUE(t.Is(Token::Type::kError)); in TEST_F()
146 EXPECT_TRUE(t.Is(Token::Type::kFloatLiteral)); in TEST_P()
224 EXPECT_FALSE(t.Is(Token::Type::kFloatLiteral)); in TEST_P()
327 EXPECT_TRUE(t.Is(Token::Type::kSintLiteral)); in TEST_P()
350 ASSERT_TRUE(t.Is(Token::Type::kError)); in TEST_F()
359 ASSERT_TRUE(t.Is(Token::Type::kError)); in TEST_F()
369 ASSERT_TRUE(t.Is(Token::Type::kError)); in TEST_F()
378 ASSERT_TRUE(t.Is(Token::Type::kError)); in TEST_F()
399 EXPECT_TRUE(t.Is(Token::Type::kUintLiteral)); in TEST_P()
425 ASSERT_TRUE(t.Is(Token::Type::kError)); in TEST_F()
[all …]
/third_party/flutter/skia/src/sksl/
DSkSLUtil.cpp35 bool is_assignment(Token::Kind op) { in is_assignment()
37 case Token::EQ: // fall through in is_assignment()
38 case Token::PLUSEQ: // fall through in is_assignment()
39 case Token::MINUSEQ: // fall through in is_assignment()
40 case Token::STAREQ: // fall through in is_assignment()
41 case Token::SLASHEQ: // fall through in is_assignment()
42 case Token::PERCENTEQ: // fall through in is_assignment()
43 case Token::SHLEQ: // fall through in is_assignment()
44 case Token::SHREQ: // fall through in is_assignment()
45 case Token::BITWISEOREQ: // fall through in is_assignment()
[all …]
DSkSLParser.cpp104 , fPushback(Token::INVALID, -1, -1) in Parser()
140 case Token::END_OF_FILE: in file()
142 case Token::DIRECTIVE: { in file()
152 case Token::SECTION: { in file()
176 Token Parser::nextRawToken() { in nextRawToken()
177 if (fPushback.fKind != Token::INVALID) { in nextRawToken()
178 Token result = fPushback; in nextRawToken()
179 fPushback.fKind = Token::INVALID; in nextRawToken()
182 Token result = fLexer.next(); in nextRawToken()
186 Token Parser::nextToken() { in nextToken()
[all …]
/third_party/gn/src/gn/
Dtokenizer_unittest.cc15 Token::Type type;
25 std::vector<Token> results = Tokenizer::Tokenize(&input_file, &err); in CheckTokenizer()
45 std::vector<Token> results = Tokenizer::Tokenize(&empty_string_input, &err); in TEST()
56 TokenExpectation one_ident[] = {{Token::IDENTIFIER, "foo"}}; in TEST()
61 TokenExpectation integers[] = {{Token::INTEGER, "123"}, in TEST()
62 {Token::INTEGER, "-123"}}; in TEST()
67 TokenExpectation integers[] = {{Token::INTEGER, "123"}, in TEST()
68 {Token::INTEGER, "-123"}}; in TEST()
73 TokenExpectation strings[] = {{Token::STRING, "\"foo\""}, in TEST()
74 {Token::STRING, "\"bar\\\"baz\""}, in TEST()
[all …]
Dtokenizer.cc35 Token::Type GetSpecificOperatorType(std::string_view value) { in GetSpecificOperatorType()
37 return Token::EQUAL; in GetSpecificOperatorType()
39 return Token::PLUS; in GetSpecificOperatorType()
41 return Token::MINUS; in GetSpecificOperatorType()
43 return Token::PLUS_EQUALS; in GetSpecificOperatorType()
45 return Token::MINUS_EQUALS; in GetSpecificOperatorType()
47 return Token::EQUAL_EQUAL; in GetSpecificOperatorType()
49 return Token::NOT_EQUAL; in GetSpecificOperatorType()
51 return Token::LESS_EQUAL; in GetSpecificOperatorType()
53 return Token::GREATER_EQUAL; in GetSpecificOperatorType()
[all …]
Dparser.h29 static std::unique_ptr<ParseNode> Parse(const std::vector<Token>& tokens,
34 const std::vector<Token>& tokens,
38 static std::unique_ptr<ParseNode> ParseValue(const std::vector<Token>& tokens,
43 Parser(const std::vector<Token>& tokens, Err* err);
52 std::unique_ptr<ParseNode> Block(const Token& token);
53 std::unique_ptr<ParseNode> Literal(const Token& token);
54 std::unique_ptr<ParseNode> Name(const Token& token);
55 std::unique_ptr<ParseNode> Group(const Token& token);
56 std::unique_ptr<ParseNode> Not(const Token& token);
57 std::unique_ptr<ParseNode> List(const Token& token);
[all …]
/third_party/python/Doc/library/
Dtoken-list.inc18 Token value for ``"("``.
22 Token value for ``")"``.
26 Token value for ``"["``.
30 Token value for ``"]"``.
34 Token value for ``":"``.
38 Token value for ``","``.
42 Token value for ``";"``.
46 Token value for ``"+"``.
50 Token value for ``"-"``.
54 Token value for ``"*"``.
[all …]
/third_party/boost/boost/wave/cpplexer/
Ddetect_include_guards.hpp45 template <typename Token>
54 Token& detect_guard(Token& t) in detect_guard()
66 typedef Token& state_type(Token& t);
71 typename Token::string_type guard_name;
87 template <typename Token>
88 inline Token&
89 include_guards<Token>::state_0(Token& t) in state_0()
103 template <typename Token>
104 inline Token&
105 include_guards<Token>::state_1(Token& t) in state_1()
[all …]
/third_party/skia/src/sksl/
DSkSLDSLParser.cpp24 static int parse_modifier_token(Token::Kind token) { in parse_modifier_token()
26 case Token::Kind::TK_UNIFORM: return Modifiers::kUniform_Flag; in parse_modifier_token()
27 case Token::Kind::TK_CONST: return Modifiers::kConst_Flag; in parse_modifier_token()
28 case Token::Kind::TK_IN: return Modifiers::kIn_Flag; in parse_modifier_token()
29 case Token::Kind::TK_OUT: return Modifiers::kOut_Flag; in parse_modifier_token()
30 case Token::Kind::TK_INOUT: return Modifiers::kIn_Flag | Modifiers::kOut_Flag; in parse_modifier_token()
31 case Token::Kind::TK_FLAT: return Modifiers::kFlat_Flag; in parse_modifier_token()
32 case Token::Kind::TK_NOPERSPECTIVE: return Modifiers::kNoPerspective_Flag; in parse_modifier_token()
33 case Token::Kind::TK_HASSIDEEFFECTS: return Modifiers::kHasSideEffects_Flag; in parse_modifier_token()
34 case Token::Kind::TK_INLINE: return Modifiers::kInline_Flag; in parse_modifier_token()
[all …]
DSkSLOperators.cpp175 case Token::Kind::TK_LT: in isLogical()
176 case Token::Kind::TK_GT: in isLogical()
177 case Token::Kind::TK_LTEQ: in isLogical()
178 case Token::Kind::TK_GTEQ: in isLogical()
187 case Token::Kind::TK_SHL: in isOnlyValidForIntegralTypes()
188 case Token::Kind::TK_SHR: in isOnlyValidForIntegralTypes()
189 case Token::Kind::TK_BITWISEAND: in isOnlyValidForIntegralTypes()
190 case Token::Kind::TK_BITWISEOR: in isOnlyValidForIntegralTypes()
191 case Token::Kind::TK_BITWISEXOR: in isOnlyValidForIntegralTypes()
192 case Token::Kind::TK_PERCENT: in isOnlyValidForIntegralTypes()
[all …]
DSkSLConstantFolder.cpp35 if ((op.kind() == Token::Kind::TK_LOGICALAND && rightVal) || // (expr && true) -> (expr) in eliminate_no_op_boolean()
36 (op.kind() == Token::Kind::TK_LOGICALOR && !rightVal) || // (expr || false) -> (expr) in eliminate_no_op_boolean()
37 (op.kind() == Token::Kind::TK_LOGICALXOR && !rightVal) || // (expr ^^ false) -> (expr) in eliminate_no_op_boolean()
38 (op.kind() == Token::Kind::TK_EQEQ && rightVal) || // (expr == true) -> (expr) in eliminate_no_op_boolean()
39 (op.kind() == Token::Kind::TK_NEQ && !rightVal)) { // (expr != false) -> (expr) in eliminate_no_op_boolean()
53 if ((op.kind() == Token::Kind::TK_LOGICALAND && !leftVal) || // (false && expr) -> (false) in short_circuit_boolean()
54 (op.kind() == Token::Kind::TK_LOGICALOR && leftVal)) { // (true || expr) -> (true) in short_circuit_boolean()
68 if (op.kind() == Token::Kind::TK_EQEQ || op.kind() == Token::Kind::TK_NEQ) { in simplify_vector_equality()
69 bool equality = (op.kind() == Token::Kind::TK_EQEQ); in simplify_vector_equality()
103 case Token::Kind::TK_PLUS: foldFn = +[](double a, double b) { return a + b; }; break; in simplify_vector()
[all …]
/third_party/skia/third_party/externals/angle2/src/tests/preprocessor_tests/
Doperator_test.cpp27 pp::Token token; in TEST_P()
54 {"++", pp::Token::OP_INC},
55 {"--", pp::Token::OP_DEC},
56 {"<<", pp::Token::OP_LEFT},
57 {">>", pp::Token::OP_RIGHT},
58 {"<=", pp::Token::OP_LE},
59 {">=", pp::Token::OP_GE},
60 {"==", pp::Token::OP_EQ},
61 {"!=", pp::Token::OP_NE},
62 {"&&", pp::Token::OP_AND},
[all …]
/third_party/flutter/skia/third_party/externals/angle2/src/tests/preprocessor_tests/
Doperator_test.cpp27 pp::Token token; in TEST_P()
54 {"++", pp::Token::OP_INC},
55 {"--", pp::Token::OP_DEC},
56 {"<<", pp::Token::OP_LEFT},
57 {">>", pp::Token::OP_RIGHT},
58 {"<=", pp::Token::OP_LE},
59 {">=", pp::Token::OP_GE},
60 {"==", pp::Token::OP_EQ},
61 {"!=", pp::Token::OP_NE},
62 {"&&", pp::Token::OP_AND},
[all …]
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/CodeGen/MIRParser/
DMIParser.cpp401 MIToken Token; member in __anon9da6c40a0111::MIParser
565 CurrentSource.data() + SkipChar, Token, in lex()
569 bool MIParser::error(const Twine &Msg) { return error(Token.location(), Msg); } in error()
609 if (Token.isNot(TokenKind)) in expectAndConsume()
616 if (Token.isNot(TokenKind)) in consumeIfPresent()
624 assert(Token.is(MIToken::MachineBasicBlockLabel)); in parseBasicBlockDefinition()
628 auto Loc = Token.location(); in parseBasicBlockDefinition()
629 auto Name = Token.stringValue(); in parseBasicBlockDefinition()
638 switch (Token.kind()) { in parseBasicBlockDefinition()
693 while (Token.is(MIToken::Newline)) in parseBasicBlockDefinitions()
[all …]
DMILexer.cpp159 static Cursor lexName(Cursor C, MIToken &Token, MIToken::TokenKind Type, in lexName() argument
166 Token.reset(Type, String) in lexName()
171 Token.reset(MIToken::Error, Range.remaining()); in lexName()
176 Token.reset(Type, Range.upto(C)) in lexName()
261 static Cursor maybeLexIdentifier(Cursor C, MIToken &Token) { in maybeLexIdentifier() argument
268 Token.reset(getIdentifierKind(Identifier), Identifier) in maybeLexIdentifier()
273 static Cursor maybeLexMachineBasicBlock(Cursor C, MIToken &Token, in maybeLexMachineBasicBlock() argument
282 Token.reset(MIToken::Error, C.remaining()); in maybeLexMachineBasicBlock()
300 Token.reset(IsReference ? MIToken::MachineBasicBlock in maybeLexMachineBasicBlock()
308 static Cursor maybeLexIndex(Cursor C, MIToken &Token, StringRef Rule, in maybeLexIndex() argument
[all …]
/third_party/flutter/skia/third_party/externals/angle2/src/compiler/preprocessor/
DDirectiveParser.h35 void lex(Token *token) override;
38 void parseDirective(Token *token);
39 void parseDefine(Token *token);
40 void parseUndef(Token *token);
41 void parseIf(Token *token);
42 void parseIfdef(Token *token);
43 void parseIfndef(Token *token);
44 void parseElse(Token *token);
45 void parseElif(Token *token);
46 void parseEndif(Token *token);
[all …]
/third_party/skia/third_party/externals/swiftshader/src/OpenGL/compiler/preprocessor/
DDirectiveParser.h40 void lex(Token *token) override;
45 void parseDirective(Token *token);
46 void parseDefine(Token *token);
47 void parseUndef(Token *token);
48 void parseIf(Token *token);
49 void parseIfdef(Token *token);
50 void parseIfndef(Token *token);
51 void parseElse(Token *token);
52 void parseElif(Token *token);
53 void parseEndif(Token *token);
[all …]
/third_party/skia/third_party/externals/angle2/src/compiler/preprocessor/
DDirectiveParser.h35 void lex(Token *token) override;
38 void parseDirective(Token *token);
39 void parseDefine(Token *token);
40 void parseUndef(Token *token);
41 void parseIf(Token *token);
42 void parseIfdef(Token *token);
43 void parseIfndef(Token *token);
44 void parseElse(Token *token);
45 void parseElif(Token *token);
46 void parseEndif(Token *token);
[all …]
/third_party/pyyaml/lib3/yaml/
Dtokens.py2 class Token(object): class
17 class DirectiveToken(Token):
25 class DocumentStartToken(Token):
28 class DocumentEndToken(Token):
31 class StreamStartToken(Token):
39 class StreamEndToken(Token):
42 class BlockSequenceStartToken(Token):
45 class BlockMappingStartToken(Token):
48 class BlockEndToken(Token):
51 class FlowSequenceStartToken(Token):
[all …]
/third_party/pyyaml/lib/yaml/
Dtokens.py2 class Token(object): class
17 class DirectiveToken(Token):
25 class DocumentStartToken(Token):
28 class DocumentEndToken(Token):
31 class StreamStartToken(Token):
39 class StreamEndToken(Token):
42 class BlockSequenceStartToken(Token):
45 class BlockMappingStartToken(Token):
48 class BlockEndToken(Token):
51 class FlowSequenceStartToken(Token):
[all …]
/third_party/typescript_eslint/packages/experimental-utils/src/ast-utils/eslint-utils/
Dpredicates.ts5 token: TSESTree.Token | TSESTree.Comment,
8 token: TSESTree.Token | TSESTree.Comment,
12 token: TSESTree.Token | TSESTree.Comment,
15 token: TSESTree.Token | TSESTree.Comment,
19 token: TSESTree.Token | TSESTree.Comment,
22 token: TSESTree.Token | TSESTree.Comment,
26 token: TSESTree.Token | TSESTree.Comment,
29 token: TSESTree.Token | TSESTree.Comment,
33 token: TSESTree.Token | TSESTree.Comment,
36 token: TSESTree.Token | TSESTree.Comment,
[all …]
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/lib/Support/
DYAMLParser.cpp126 struct Token { struct
160 Token() = default;
166 using TokenQueueT = BumpPtrList<Token>;
260 Token &peekNext();
263 Token getNext();
429 , Token::TokenKind Kind
597 Token T = scanner.getNext(); in dumpTokens()
599 case Token::TK_StreamStart: in dumpTokens()
602 case Token::TK_StreamEnd: in dumpTokens()
605 case Token::TK_VersionDirective: in dumpTokens()
[all …]
/third_party/typescript_eslint/packages/experimental-utils/src/ts-eslint/
DSourceCode.ts15 left: TSESTree.Node | TSESTree.Token,
16 right: TSESTree.Node | TSESTree.Token,
24 nodeOrToken: TSESTree.Node | TSESTree.Token,
32 nodeOrToken: TSESTree.Node | TSESTree.Token,
58 left: TSESTree.Node | TSESTree.Token | TSESTree.Comment,
59 right: TSESTree.Node | TSESTree.Token | TSESTree.Comment,
80 left: TSESTree.Node | TSESTree.Token | TSESTree.Comment,
81 right: TSESTree.Node | TSESTree.Token | TSESTree.Comment,
102 left: TSESTree.Node | TSESTree.Token | TSESTree.Comment,
103 right: TSESTree.Node | TSESTree.Token | TSESTree.Comment,
[all …]

12345678910>>...26