/third_party/rust/crates/serde/serde_derive/src/ |
H A D | bound.rs | 5 use syn::punctuated::{Pair, Punctuated}; 6 use syn::Token; 11 pub fn without_defaults(generics: &syn::Generics) -> syn::Generics { in without_defaults() 12 syn::Generics { in without_defaults() 17 syn::GenericParam::Type(param) => syn::GenericParam::Type(syn::TypeParam { in without_defaults() 30 generics: &syn::Generics, in with_where_predicates() 31 predicates: &[syn in with_where_predicates() [all...] |
H A D | lib.rs | 66 extern crate syn; 73 use syn::parse_macro_input; 74 use syn::DeriveInput; 91 .unwrap_or_else(syn::Error::into_compile_error) in derive_serialize() 99 .unwrap_or_else(syn::Error::into_compile_error) in derive_deserialize()
|
/third_party/vk-gl-cts/external/amber/src/tools/ |
H A D | amber-syntax.vim | 9 syn match amberNumber '\d\+' contained display 10 syn match amberNumber '[-+]\d\+' contained display 13 syn match amberNumber '\d\+\.\d*' contained display 14 syn match amberNumber '[-+]\d\+\.\d*' contained display 17 syn match amberNumber '[-+]\=\d[[:digit:]]*[eE][\-+]\=\d\+' contained display 18 syn match amberNumber '\d[[:digit:]]*[eE][\-+]\=\d\+' contained display 21 syn match amberNumber '[-+]\=\d[[:digit:]]*\.\d*[eE][\-+]\=\d\+' contained display 22 syn match amberNumber '\d[[:digit:]]*\.\d*[eE][\-+]\=\d\+' contained display 24 syn region amberString start='"' end='"' contained 25 syn regio [all...] |
/third_party/gn/misc/vim/syntax/ |
H A D | gn.vim | 12 syn case match 15 syn keyword gnConditional if else 19 syn keyword gnPredefVar current_cpu current_os current_toolchain 20 syn keyword gnPredefVar default_toolchain host_cpu host_os 21 syn keyword gnPredefVar root_build_dir root_gen_dir root_out_dir 22 syn keyword gnPredefVar target_cpu target_gen_dir target_out_dir 23 syn keyword gnPredefVar target_os 24 syn keyword gnPredefVar true false 28 syn keyword gnTarget action action_foreach copy executable group 29 syn keywor [all...] |
/third_party/node/deps/v8/tools/torque/vim-torque/syntax/ |
H A D | torque.vim | 18 syn match torqueLineComment "\/\/.*" contains=@Spell 19 syn region torqueComment start="/\*" end="\*/" contains=@Spell 20 syn region torqueStringS start=+'+ skip=+\\\\\|\\'+ end=+'\|$+ 22 syn keyword torqueAssert assert check debug unreachable 23 syn keyword torqueAtom True False Undefined TheHole Null 24 syn keyword torqueBoolean true false 25 syn keyword torqueBranch break continue goto 26 syn keyword torqueConditional if else typeswitch otherwise 27 syn match torqueConstant /\v<[A-Z][A-Z0-9_]+>/ 28 syn matc [all...] |
/third_party/rust/crates/serde/serde_derive_internals/src/ |
H A D | attr.rs | 8 use syn::meta::ParseNestedMeta; 9 use syn::parse::ParseStream; 10 use syn::punctuated::Punctuated; 11 use syn::{parse_quote, token, Ident, Lifetime, Token}; 211 ser_bound: Option<Vec<syn::WherePredicate>>, 212 de_bound: Option<Vec<syn::WherePredicate>>, 214 type_from: Option<syn::Type>, 215 type_try_from: Option<syn::Type>, 216 type_into: Option<syn::Type>, 217 remote: Option<syn [all...] |
H A D | ast.rs | 4 use syn::punctuated::Punctuated; 5 use syn::Token; 11 pub ident: syn::Ident, 17 pub generics: &'a syn::Generics, 19 pub original: &'a syn::DeriveInput, 24 /// Analogous to `syn::Data`. 32 pub ident: syn::Ident, 36 pub original: &'a syn::Variant, 41 pub member: syn::Member, 43 pub ty: &'a syn [all...] |
/third_party/rust/crates/serde/serde_derive/src/internals/ |
H A D | attr.rs | 8 use syn::meta::ParseNestedMeta; 9 use syn::parse::ParseStream; 10 use syn::punctuated::Punctuated; 11 use syn::{parse_quote, token, Ident, Lifetime, Token}; 211 ser_bound: Option<Vec<syn::WherePredicate>>, 212 de_bound: Option<Vec<syn::WherePredicate>>, 214 type_from: Option<syn::Type>, 215 type_try_from: Option<syn::Type>, 216 type_into: Option<syn::Type>, 217 remote: Option<syn [all...] |
H A D | ast.rs | 4 use syn::punctuated::Punctuated; 5 use syn::Token; 11 pub ident: syn::Ident, 17 pub generics: &'a syn::Generics, 19 pub original: &'a syn::DeriveInput, 24 /// Analogous to `syn::Data`. 32 pub ident: syn::Ident, 36 pub original: &'a syn::Variant, 41 pub member: syn::Member, 43 pub ty: &'a syn [all...] |
/third_party/rust/crates/syn/tests/debug/ |
H A D | gen.rs | 1 // This file is @generated by syn-internal-codegen. 9 impl Debug for Lite<syn::Abi> { 15 struct Print(syn::LitStr); in fmt() 29 impl Debug for Lite<syn::AngleBracketedGenericArguments> { 41 impl Debug for Lite<syn::Arm> { 51 struct Print((syn::token::If, Box<syn::Expr>)); in fmt() 69 impl Debug for Lite<syn::AssocConst> { 76 struct Print(syn::AngleBracketedGenericArguments); in fmt() 91 impl Debug for Lite<syn [all...] |
/third_party/rust/crates/syn/tests/ |
H A D | test_expr.rs | 8 use syn::punctuated::Punctuated; 9 use syn::{parse_quote, token, Expr, ExprRange, ExprTuple, Stmt, Token}; 86 assert_eq!(expected, syn::parse_str(input).unwrap()); in test_tuple_multi_index() 97 assert_eq!(expected, syn::parse2(tokens).unwrap()); in test_tuple_multi_index() 309 // https://github.com/dtolnay/syn/issues/1019 329 syn::parse_str::<Expr>("|| &x as T[0]").unwrap_err(); in test_postfix_operator_after_cast() 330 syn::parse_str::<Expr>("|| () as ()()").unwrap_err(); in test_postfix_operator_after_cast() 335 syn::parse_str::<Expr>("..").unwrap(); in test_ranges() 336 syn::parse_str::<Expr>("..hi").unwrap(); in test_ranges() 337 syn in test_ranges() [all...] |
H A D | test_pat.rs | 8 use syn::parse::Parser; 9 use syn::punctuated::Punctuated; 10 use syn::{parse_quote, token, Item, Pat, PatTuple, Stmt, Token}; 32 syn::parse_str::<Item>("fn f() {}").unwrap(); in test_leading_vert() 33 syn::parse_str::<Item>("fn fun1(| A: E) {}").unwrap_err(); in test_leading_vert() 34 syn::parse_str::<Item>("fn fun2(|| A: E) {}").unwrap_err(); in test_leading_vert() 36 syn::parse_str::<Stmt>("let | () = ();").unwrap_err(); in test_leading_vert() 37 syn::parse_str::<Stmt>("let (| A): E;").unwrap(); in test_leading_vert() 38 syn::parse_str::<Stmt>("let (|| A): (E);").unwrap_err(); in test_leading_vert() 39 syn in test_leading_vert() [all...] |
H A D | test_ty.rs | 8 use syn::punctuated::Punctuated; 9 use syn::{parse_quote, token, Token, Type, TypeTuple}; 13 syn::parse_str::<Type>("fn(mut self)").unwrap(); in test_mut_self() 14 syn::parse_str::<Type>("fn(mut self,)").unwrap(); in test_mut_self() 15 syn::parse_str::<Type>("fn(mut self: ())").unwrap(); in test_mut_self() 16 syn::parse_str::<Type>("fn(mut self: ...)").unwrap_err(); in test_mut_self() 17 syn::parse_str::<Type>("fn(mut self: mut self)").unwrap_err(); in test_mut_self() 18 syn::parse_str::<Type>("fn(mut self::T)").unwrap_err(); in test_mut_self() 281 syn::parse_str::<Type>("for<'a> dyn Trait<'a>").unwrap_err(); in test_trait_object() 282 syn in test_trait_object() [all...] |
H A D | test_precedence.rs | 3 //! 1. Parse the file using syn into a syn::File. 4 //! 2. Extract every syn::Expr from the file. 7 //! 5. For both the syn::Expr and rustc_ast::Expr, crawl the syntax tree to 9 //! 6. Serialize the fully parenthesized syn::Expr to a string of source code. 12 //! data structures vs syn data structures, ignoring spans. If they agree, 13 //! rustc's parser and syn's parser have identical handling of expression 76 let (l_passed, l_failed) = match syn::parse_file(&content) { in test_rustc_precedence() 90 errorf!("\nFAIL {} - syn failed to parse: {}\n", path.display(), msg); in test_rustc_precedence() 114 fn test_expressions(path: &Path, edition: Edition, exprs: Vec<syn [all...] |
H A D | test_parse_buffer.rs | 4 use syn::parse::discouraged::Speculative as _; 5 use syn::parse::{Parse, ParseStream, Parser, Result}; 6 use syn::{parenthesized, Token}; 22 syn::parse_str::<BreakRules>("").unwrap(); in smuggled_speculative_cursor_between_sources() 40 syn::parse_str::<BreakRules>("()()").unwrap(); in smuggled_speculative_cursor_between_brackets() 56 syn::parse_str::<BreakRules>("()").unwrap(); in smuggled_speculative_cursor_into_brackets()
|
/third_party/ninja/misc/ |
H A D | ninja.vim | 22 syn case match 27 syn match ninjaComment /\(\$\n\)\@<!\_^\s*#.*$/ contains=@Spell 32 syn match ninjaKeyword "^build\>" 33 syn match ninjaKeyword "^rule\>" 34 syn match ninjaKeyword "^pool\>" 35 syn match ninjaKeyword "^default\>" 36 syn match ninjaKeyword "^include\>" 37 syn match ninjaKeyword "^subninja\>" 44 syn region ninjaRule start="^rule" end="^\ze\S" contains=TOP transparent 45 syn keywor [all...] |
/third_party/protobuf/editors/ |
H A D | proto.vim | 51 syn case match 53 syn keyword pbTodo contained TODO FIXME XXX 54 syn cluster pbCommentGrp contains=pbTodo 56 syn keyword pbSyntax syntax import option 57 syn keyword pbStructure package message group oneof 58 syn keyword pbRepeat optional required repeated 59 syn keyword pbDefault default 60 syn keyword pbExtend extend extensions to max reserved 61 syn keyword pbRPC service rpc returns 63 syn keywor [all...] |
/third_party/rust/crates/clap/clap_derive/src/utils/ |
H A D | error.rs | 3 fn EXPECTED_Span_OR_ToTokens<D: std::fmt::Display>(&self, msg: D) -> syn::Error; in EXPECTED_Span_OR_ToTokens() 8 fn EXPECTED_Span_OR_ToTokens<D: std::fmt::Display>(&self, msg: D) -> syn::Error; in EXPECTED_Span_OR_ToTokens() 12 fn EXPECTED_Span_OR_ToTokens<D: std::fmt::Display>(&self, msg: D) -> syn::Error { in EXPECTED_Span_OR_ToTokens() 14 syn::Error::new_spanned(self.to_token_stream(), msg) in EXPECTED_Span_OR_ToTokens() 19 fn EXPECTED_Span_OR_ToTokens<D: std::fmt::Display>(&self, msg: D) -> syn::Error { in EXPECTED_Span_OR_ToTokens() 20 syn::Error::new(*self, msg) in EXPECTED_Span_OR_ToTokens()
|
H A D | ty.rs | 5 use syn::{ 23 pub fn from_syn_ty(ty: &syn::Type) -> Sp<Self> { in from_syn_ty() 58 pub fn inner_type(field_ty: &syn::Type) -> &syn::Type { in inner_type() 73 pub fn sub_type(ty: &syn::Type) -> Option<&syn::Type> { in sub_type() 77 fn only_last_segment(mut ty: &syn::Type) -> Option<&PathSegment> { in only_last_segment() 78 while let syn::Type::Group(syn::TypeGroup { elem, .. }) = ty { in only_last_segment() 95 fn subty_if<F>(ty: &syn [all...] |
H A D | doc_comments.rs | 8 pub fn extract_doc_comment(attrs: &[syn::Attribute]) -> Vec<String> { in extract_doc_comment() 20 syn::Meta::NameValue(syn::MetaNameValue { in extract_doc_comment() 22 syn::Expr::Lit(syn::ExprLit { in extract_doc_comment() 23 lit: syn::Lit::Str(s), in extract_doc_comment()
|
/third_party/rust/crates/syn/tests/regression/ |
H A D | issue1235.rs | 12 let file = syn::parse2::<syn::File>(tokens).unwrap(); in main() 21 let file = syn::parse2::<syn::File>(tokens).unwrap(); in main() 30 let file = syn::parse2::<syn::File>(tokens).unwrap(); in main()
|
/third_party/rust/crates/clap/clap_derive/src/derives/ |
H A D | parser.rs | 17 use syn::Ident; 18 use syn::Variant; 19 use syn::{ 28 pub fn derive_parser(input: &DeriveInput) -> Result<TokenStream, syn::Error> { in derive_parser() 46 .collect::<Result<Vec<_>, syn::Error>>()?; in derive_parser() 62 .collect::<Result<Vec<_>, syn::Error>>()?; in derive_parser() 76 .collect::<Result<Vec<_>, syn::Error>>()?; in derive_parser() 88 ) -> Result<TokenStream, syn::Error> { in gen_for_struct() 107 ) -> Result<TokenStream, syn::Error> { in gen_for_enum()
|
H A D | subcommand.rs | 17 use syn::{spanned::Spanned, Data, DeriveInput, FieldsUnnamed, Generics, Variant}; 23 pub fn derive_subcommand(input: &DeriveInput) -> Result<TokenStream, syn::Error> { in derive_subcommand() 38 .collect::<Result<Vec<_>, syn::Error>>()?; in derive_subcommand() 50 ) -> Result<TokenStream, syn::Error> { in gen_for_enum() 125 ) -> Result<TokenStream, syn::Error> { in gen_augment() 126 use syn::Fields::*; in gen_augment() 275 .collect::<Result<Vec<_>, syn::Error>>()?; in gen_augment() 350 fn gen_has_subcommand(variants: &[(&Variant, Item)]) -> Result<TokenStream, syn::Error> { in gen_has_subcommand() 351 use syn::Fields::*; in gen_has_subcommand() 398 .collect::<Result<Vec<_>, syn in gen_has_subcommand() [all...] |
/third_party/rust/crates/syn/benches/ |
H A D | file.rs | 27 use syn::parse::{ParseStream, Parser}; 47 fn immediate_fail(_input: ParseStream) -> syn::Result<()> { in create_token_buffer() 48 Err(syn::Error::new(Span::call_site(), "")) in create_token_buffer() 56 b.iter(|| syn::parse2::<syn::File>(tokens.clone())); in parse_file()
|
/third_party/rust/crates/syn/codegen/src/ |
H A D | parse.rs | 8 use syn::parse::{Error, Parser}; 9 use syn::{ 62 /// Data extracted from syn source 133 fn introspect_type(item: &syn::Type, lookup: &Lookup) -> types::Type { in introspect_type() 135 syn::Type::Path(TypePath { qself: None, path }) => { in introspect_type() 180 syn::Type::Tuple(TypeTuple { elems, .. }) => { in introspect_type() 184 syn::Type::Macro(TypeMacro { mac }) in introspect_type() 244 fn first_arg(params: &PathArguments) -> &syn::Type { in first_arg() 260 fn last_arg(params: &PathArguments) -> &syn::Type { in last_arg() 281 use syn [all...] |