Home
last modified time | relevance | path

Searched refs:tokens (Results 1 - 25 of 499) sorted by relevance

12345678910>>...20

/third_party/rust/crates/quote/src/
H A Dlib.rs10 //! structures into tokens of source code.
14 //! Procedural macros in Rust receive a stream of tokens as input, execute
15 //! arbitrary Rust code to determine how to manipulate those tokens, and produce
16 //! a stream of tokens to hand back to the compiler to compile into the caller's
18 //! tokens to return to the compiler.
25 //! it around, mutate it, and eventually hand it back to the compiler as tokens
43 //! syntax performs interpolation of runtime variables into the quoted tokens.
61 //! let tokens = quote! {
88 //! file, consider having the code generator pass the tokens through
133 /// Note: for returning tokens t
[all...]
H A Dto_tokens.rs33 /// fn to_tokens(&self, tokens: &mut TokenStream) {
37 /// tokens.append(Punct::new(':', Spacing::Joint));
38 /// tokens.append(Punct::new(':', Spacing::Alone));
40 /// segment.to_tokens(tokens);
48 /// # fn to_tokens(&self, tokens: &mut TokenStream) {
53 fn to_tokens(&self, tokens: &mut TokenStream); in to_tokens()
60 let mut tokens = TokenStream::new(); in to_token_stream() variables
61 self.to_tokens(&mut tokens); in to_token_stream()
62 tokens in to_token_stream()
78 fn to_tokens(&self, tokens
[all...]
/third_party/rust/crates/cxx/gen/cmd/src/syntax/
H A Dtokens.rs11 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
16 tokens.extend(quote_spanned!(span=> ::cxx::private::)); in to_tokens()
19 tokens.extend(quote_spanned!(span=> ::cxx::)); in to_tokens()
22 tokens.extend(quote_spanned!(span=> ::cxx::alloc::string::)); in to_tokens()
24 ident.to_tokens(tokens); in to_tokens()
31 | Type::RustVec(ty) => ty.to_tokens(tokens), in to_tokens()
32 Type::Ref(r) | Type::Str(r) => r.to_tokens(tokens), in to_tokens()
33 Type::Ptr(p) => p.to_tokens(tokens), in to_tokens()
34 Type::Array(a) => a.to_tokens(tokens), in to_tokens()
35 Type::Fn(f) => f.to_tokens(tokens), in to_tokens()
[all...]
/third_party/rust/crates/cxx/gen/lib/src/syntax/
H A Dtokens.rs11 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
16 tokens.extend(quote_spanned!(span=> ::cxx::private::)); in to_tokens()
19 tokens.extend(quote_spanned!(span=> ::cxx::)); in to_tokens()
22 tokens.extend(quote_spanned!(span=> ::cxx::alloc::string::)); in to_tokens()
24 ident.to_tokens(tokens); in to_tokens()
31 | Type::RustVec(ty) => ty.to_tokens(tokens), in to_tokens()
32 Type::Ref(r) | Type::Str(r) => r.to_tokens(tokens), in to_tokens()
33 Type::Ptr(p) => p.to_tokens(tokens), in to_tokens()
34 Type::Array(a) => a.to_tokens(tokens), in to_tokens()
35 Type::Fn(f) => f.to_tokens(tokens), in to_tokens()
[all...]
/third_party/rust/crates/cxx/gen/build/src/syntax/
H A Dtokens.rs11 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
16 tokens.extend(quote_spanned!(span=> ::cxx::private::)); in to_tokens()
19 tokens.extend(quote_spanned!(span=> ::cxx::)); in to_tokens()
22 tokens.extend(quote_spanned!(span=> ::cxx::alloc::string::)); in to_tokens()
24 ident.to_tokens(tokens); in to_tokens()
31 | Type::RustVec(ty) => ty.to_tokens(tokens), in to_tokens()
32 Type::Ref(r) | Type::Str(r) => r.to_tokens(tokens), in to_tokens()
33 Type::Ptr(p) => p.to_tokens(tokens), in to_tokens()
34 Type::Array(a) => a.to_tokens(tokens), in to_tokens()
35 Type::Fn(f) => f.to_tokens(tokens), in to_tokens()
[all...]
/third_party/rust/crates/cxx/macro/src/syntax/
H A Dtokens.rs11 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
16 tokens.extend(quote_spanned!(span=> ::cxx::private::)); in to_tokens()
19 tokens.extend(quote_spanned!(span=> ::cxx::)); in to_tokens()
22 tokens.extend(quote_spanned!(span=> ::cxx::alloc::string::)); in to_tokens()
24 ident.to_tokens(tokens); in to_tokens()
31 | Type::RustVec(ty) => ty.to_tokens(tokens), in to_tokens()
32 Type::Ref(r) | Type::Str(r) => r.to_tokens(tokens), in to_tokens()
33 Type::Ptr(p) => p.to_tokens(tokens), in to_tokens()
34 Type::Array(a) => a.to_tokens(tokens), in to_tokens()
35 Type::Fn(f) => f.to_tokens(tokens), in to_tokens()
[all...]
/third_party/rust/crates/cxx/syntax/
H A Dtokens.rs11 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
16 tokens.extend(quote_spanned!(span=> ::cxx::private::)); in to_tokens()
19 tokens.extend(quote_spanned!(span=> ::cxx::)); in to_tokens()
22 tokens.extend(quote_spanned!(span=> ::cxx::alloc::string::)); in to_tokens()
24 ident.to_tokens(tokens); in to_tokens()
31 | Type::RustVec(ty) => ty.to_tokens(tokens), in to_tokens()
32 Type::Ref(r) | Type::Str(r) => r.to_tokens(tokens), in to_tokens()
33 Type::Ptr(p) => p.to_tokens(tokens), in to_tokens()
34 Type::Array(a) => a.to_tokens(tokens), in to_tokens()
35 Type::Fn(f) => f.to_tokens(tokens), in to_tokens()
[all...]
/third_party/mesa3d/src/gallium/drivers/r300/compiler/tests/
H A Drc_test_helpers.c142 struct src_tokens tokens; in init_rc_normal_src() local
153 tokens.Negate.String = src_str + matches[1].rm_so; in init_rc_normal_src()
154 tokens.Negate.Length = match_length(matches, 1); in init_rc_normal_src()
155 tokens.Abs.String = src_str + matches[2].rm_so; in init_rc_normal_src()
156 tokens.Abs.Length = match_length(matches, 2); in init_rc_normal_src()
157 tokens.File.String = src_str + matches[3].rm_so; in init_rc_normal_src()
158 tokens.File.Length = match_length(matches, 3); in init_rc_normal_src()
159 tokens.Index.String = src_str + matches[4].rm_so; in init_rc_normal_src()
160 tokens.Index.Length = match_length(matches, 4); in init_rc_normal_src()
161 tokens in init_rc_normal_src()
271 struct dst_tokens tokens; init_rc_normal_dst() local
377 struct inst_tokens tokens; parse_rc_normal_instruction() local
[all...]
/third_party/rust/crates/quote/tests/
H A Dtest.rs20 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
21 tokens.append(Ident::new("X", Span::call_site())); in to_tokens()
27 let tokens = quote! { in test_quote_impl()
29 fn to_tokens(&self, tokens: &mut TokenStream) { in test_quote_impl()
30 (**self).to_tokens(tokens) in test_quote_impl()
37 "fn to_tokens (& self , tokens : & mut TokenStream) { ", in test_quote_impl()
38 "(* * self) . to_tokens (tokens) ", in test_quote_impl()
43 assert_eq!(expected, tokens.to_string()); in test_quote_impl()
49 let tokens = quote_spanned! {span=> in test_quote_spanned_impl()
51 fn to_tokens(&self, tokens in test_quote_spanned_impl()
[all...]
/third_party/rust/crates/syn/tests/
H A Dtest_item.rs13 let tokens = TokenStream::from_iter(vec![ in test_macro_variable_attr()
21 snapshot!(tokens as Item, @r###" in test_macro_variable_attr()
54 let tokens = quote! { in test_negative_impl()
57 snapshot!(tokens as Item, @r###" in test_negative_impl()
67 let tokens = quote! { in test_negative_impl()
70 snapshot!(tokens as Item, @r###" in test_negative_impl()
79 let tokens = quote! { in test_negative_impl()
82 snapshot!(tokens as Item, @r###" in test_negative_impl()
110 let tokens = quote! { in test_negative_impl()
113 snapshot!(tokens a in test_negative_impl()
[all...]
H A Dtest_expr.rs13 let tokens = quote!(..100u32); in test_expr_parse()
14 snapshot!(tokens as Expr, @r###" in test_expr_parse()
23 let tokens = quote!(..100u32); in test_expr_parse()
24 snapshot!(tokens as ExprRange, @r###" in test_expr_parse()
37 let tokens = quote!(fut.await); in test_await()
39 snapshot!(tokens as Expr, @r###" in test_await()
89 for tokens in [ in test_tuple_multi_index()
97 assert_eq!(expected, syn::parse2(tokens).unwrap()); in test_tuple_multi_index()
105 let tokens = quote!(#path()); in test_macro_variable_func()
107 snapshot!(tokens a in test_macro_variable_func()
[all...]
/third_party/rust/crates/syn/src/
H A Ditem.rs1205 let (delimiter, tokens) = input.call(mac::parse_delimiter)?; in parse()
1218 tokens, in parse()
2867 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
2868 tokens.append_all(self.attrs.outer()); in to_tokens()
2869 self.vis.to_tokens(tokens); in to_tokens()
2870 self.extern_token.to_tokens(tokens); in to_tokens()
2871 self.crate_token.to_tokens(tokens); in to_tokens()
2872 self.ident.to_tokens(tokens); in to_tokens()
2874 as_token.to_tokens(tokens); in to_tokens()
2875 rename.to_tokens(tokens); in to_tokens()
[all...]
H A Dexpr.rs1451 if let Expr::Verbatim(tokens) = &mut e { in trailer_expr()
1452 *tokens = verbatim::between(&begin, input); in trailer_expr()
1800 let (delimiter, tokens) = mac::parse_delimiter(input)?; in rest_of_path_or_macro_or_struct()
1807 tokens, in rest_of_path_or_macro_or_struct()
2960 fn wrap_bare_struct(tokens: &mut TokenStream, e: &Expr) { in wrap_bare_struct()
2962 token::Paren::default().surround(tokens, |tokens| { in wrap_bare_struct()
2963 e.to_tokens(tokens); in wrap_bare_struct()
2966 e.to_tokens(tokens); in wrap_bare_struct()
2971 pub(crate) fn outer_attrs_to_tokens(attrs: &[Attribute], tokens
[all...]
H A Dop.rs174 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
176 BinOp::Add(t) => t.to_tokens(tokens), in to_tokens()
177 BinOp::Sub(t) => t.to_tokens(tokens), in to_tokens()
178 BinOp::Mul(t) => t.to_tokens(tokens), in to_tokens()
179 BinOp::Div(t) => t.to_tokens(tokens), in to_tokens()
180 BinOp::Rem(t) => t.to_tokens(tokens), in to_tokens()
181 BinOp::And(t) => t.to_tokens(tokens), in to_tokens()
182 BinOp::Or(t) => t.to_tokens(tokens), in to_tokens()
183 BinOp::BitXor(t) => t.to_tokens(tokens), in to_tokens()
184 BinOp::BitAnd(t) => t.to_tokens(tokens), in to_tokens()
[all...]
H A Dpath.rs48 /// Meta::List(meta) => Ok(Some(&meta.tokens)),
678 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
679 self.leading_colon.to_tokens(tokens); in to_tokens()
680 self.segments.to_tokens(tokens); in to_tokens()
686 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
687 self.ident.to_tokens(tokens); in to_tokens()
688 self.arguments.to_tokens(tokens); in to_tokens()
694 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
698 arguments.to_tokens(tokens); in to_tokens()
701 arguments.to_tokens(tokens); in to_tokens()
[all...]
H A Dpat.rs402 let (delimiter, tokens) = mac::parse_delimiter(input)?; in pat_path_or_macro_or_struct_or_range()
409 tokens, in pat_path_or_macro_or_struct_or_range()
783 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
784 tokens.append_all(self.attrs.outer()); in to_tokens()
785 self.by_ref.to_tokens(tokens); in to_tokens()
786 self.mutability.to_tokens(tokens); in to_tokens()
787 self.ident.to_tokens(tokens); in to_tokens()
789 at_token.to_tokens(tokens); in to_tokens()
790 subpat.to_tokens(tokens); in to_tokens()
797 fn to_tokens(&self, tokens
[all...]
H A Dgenerics.rs15 /// grammar, there may be other tokens in between these two things.
982 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
987 TokensOrDefault(&self.lt_token).to_tokens(tokens); in to_tokens()
994 param.to_tokens(tokens); in to_tokens()
1002 <Token![,]>::default().to_tokens(tokens); in to_tokens()
1005 param.to_tokens(tokens); in to_tokens()
1011 TokensOrDefault(&self.gt_token).to_tokens(tokens); in to_tokens()
1016 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
1021 TokensOrDefault(&self.0.lt_token).to_tokens(tokens); in to_tokens()
1028 param.to_tokens(tokens); in to_tokens()
[all...]
H A Dty.rs483 let (delimiter, tokens) = mac::parse_delimiter(input)?;
489 tokens,
1005 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
1006 self.bracket_token.surround(tokens, |tokens| { in to_tokens()
1007 self.elem.to_tokens(tokens); in to_tokens()
1014 fn to_tokens(&self, tokens: &mut TokenStream) { in to_tokens()
1015 self.bracket_token.surround(tokens, |tokens| { in to_tokens()
1016 self.elem.to_tokens(tokens); in to_tokens()
[all...]
/third_party/python/Tools/scripts/
H A Dabitype.py16 for t,v in tokens:
40 if tokens[pos][1] == 'static':
45 name = tokens[pos][1]
47 while tokens[pos][1] != '{':
51 while tokens[pos][0] in ('ws', 'comment'):
53 if tokens[pos][1] != 'PyVarObject_HEAD_INIT':
55 while tokens[pos][1] != ')':
58 # field definitions: various tokens, comma-separated
61 while tokens[pos][0] in ('ws', 'comment'):
64 while tokens[en
169 tokens = [] global() variable
[all...]
/third_party/skia/third_party/externals/libwebp/src/utils/
H A Dhuffman_encode_utils.c262 HuffmanTreeToken* tokens, in CodeRepeatedValues()
266 tokens->code = value; in CodeRepeatedValues()
267 tokens->extra_bits = 0; in CodeRepeatedValues()
268 ++tokens; in CodeRepeatedValues()
275 tokens->code = value; in CodeRepeatedValues()
276 tokens->extra_bits = 0; in CodeRepeatedValues()
277 ++tokens; in CodeRepeatedValues()
281 tokens->code = 16; in CodeRepeatedValues()
282 tokens->extra_bits = repetitions - 3; in CodeRepeatedValues()
283 ++tokens; in CodeRepeatedValues()
261 CodeRepeatedValues(int repetitions, HuffmanTreeToken* tokens, int value, int prev_value) CodeRepeatedValues() argument
295 CodeRepeatedZeros(int repetitions, HuffmanTreeToken* tokens) CodeRepeatedZeros() argument
326 VP8LCreateCompressedHuffmanTree(const HuffmanTreeCode* const tree, HuffmanTreeToken* tokens, int max_tokens) VP8LCreateCompressedHuffmanTree() argument
[all...]
/third_party/mesa3d/src/gallium/targets/graw-null/
H A Dgraw_util.c19 struct tgsi_token tokens[1024]; in graw_parse_geometry_shader() local
22 if (!tgsi_text_translate(text, tokens, ARRAY_SIZE(tokens))) in graw_parse_geometry_shader()
26 state.tokens = tokens; in graw_parse_geometry_shader()
34 struct tgsi_token tokens[1024]; in graw_parse_vertex_shader() local
37 if (!tgsi_text_translate(text, tokens, ARRAY_SIZE(tokens))) in graw_parse_vertex_shader()
41 state.tokens = tokens; in graw_parse_vertex_shader()
49 struct tgsi_token tokens[1024]; graw_parse_fragment_shader() local
[all...]
/third_party/node/deps/npm/node_modules/postcss-selector-parser/dist/
H A Dparser.js19 var tokens = _interopRequireWildcard(require("./tokenTypes")); variable
28 var WHITESPACE_TOKENS = (_WHITESPACE_TOKENS = {}, _WHITESPACE_TOKENS[tokens.space] = true, _WHITESPACE_TOKENS[tokens.cr] = true, _WHITESPACE_TOKENS[tokens.feed] = true, _WHITESPACE_TOKENS[tokens.newline] = true, _WHITESPACE_TOKENS[tokens.tab] = true, _WHITESPACE_TOKENS);
29 var WHITESPACE_EQUIV_TOKENS = Object.assign({}, WHITESPACE_TOKENS, (_Object$assign = {}, _Object$assign[tokens.comment] = true, _Object$assign));
103 this.tokens = (0, _tokenize["default"])({
108 var rootSource = getTokenSourceSpan(this.tokens[0], this.tokens[thi
[all...]
/third_party/rust/crates/proc-macro2/tests/
H A Dcomments.rs6 fn lit_of_outer_doc_comment(tokens: &TokenStream) -> Literal { in lit_of_outer_doc_comment()
7 lit_of_doc_comment(tokens, false) in lit_of_outer_doc_comment()
11 fn lit_of_inner_doc_comment(tokens: &TokenStream) -> Literal { in lit_of_inner_doc_comment()
12 lit_of_doc_comment(tokens, true) in lit_of_inner_doc_comment()
15 fn lit_of_doc_comment(tokens: &TokenStream, inner: bool) -> Literal { in lit_of_doc_comment()
16 let mut iter = tokens.clone().into_iter(); in lit_of_doc_comment()
22 _ => panic!("wrong token {:?}", tokens), in lit_of_doc_comment()
30 _ => panic!("wrong token {:?}", tokens), in lit_of_doc_comment()
36 assert!(iter.next().is_none(), "unexpected token {:?}", tokens); in lit_of_doc_comment()
39 _ => panic!("wrong token {:?}", tokens), in lit_of_doc_comment()
[all...]
/third_party/skia/third_party/externals/libwebp/src/enc/
H A Dtoken_enc.c114 VP8TBuffer* const tokens) { in VP8RecordCoeffTokens()
122 if (!AddToken(tokens, last >= 0, base_id + 0, s + 0)) { in VP8RecordCoeffTokens()
130 if (!AddToken(tokens, v != 0, base_id + 1, s + 1)) { in VP8RecordCoeffTokens()
135 if (!AddToken(tokens, v > 1, base_id + 2, s + 2)) { in VP8RecordCoeffTokens()
139 if (!AddToken(tokens, v > 4, base_id + 3, s + 3)) { in VP8RecordCoeffTokens()
140 if (AddToken(tokens, v != 2, base_id + 4, s + 4)) { in VP8RecordCoeffTokens()
141 AddToken(tokens, v == 4, base_id + 5, s + 5); in VP8RecordCoeffTokens()
143 } else if (!AddToken(tokens, v > 10, base_id + 6, s + 6)) { in VP8RecordCoeffTokens()
144 if (!AddToken(tokens, v > 6, base_id + 7, s + 7)) { in VP8RecordCoeffTokens()
145 AddConstantToken(tokens, in VP8RecordCoeffTokens()
113 VP8RecordCoeffTokens(int ctx, const struct VP8Residual* const res, VP8TBuffer* const tokens) VP8RecordCoeffTokens() argument
208 const token_t* const tokens = TOKEN_DATA(p); VP8EmitTokens() local
234 const token_t* const tokens = TOKEN_DATA(p); VP8EstimateTokenSize() local
[all...]
/third_party/typescript/tests/baselines/reference/
H A DuncaughtCompilerError1.js2 declare var index, lineTokens, token, tokens;
5 if (lineTokens[index].trim() === '=' && index > 0 && token.type === '' && tokens[index - 1].type === 'attribute.name.html') {
6 if (index === (tokens.length - 1)) {
9 else if (tokens[index + 1].type !== 'attribute.value.html' && tokens[index + 1].type !== '') {
19 if (lineTokens[index].trim() === '=' && index > 0 && token.type === '' && tokens[index - 1].type === 'attribute.name.html') {
20 if (index === (tokens.length - 1)) {
23 else if (tokens[index + 1].type !== 'attribute.value.html' && tokens[index + 1].type !== '') {

Completed in 18 milliseconds

12345678910>>...20