/third_party/typescript/tests/baselines/reference/ |
H A D | controlFlowAliasing.js | 79 function f20(obj: { kind: 'foo', foo: string } | { kind: 'bar', bar: number }) { 80 const isFoo = obj.kind === 'foo'; 89 function f21(obj: { kind: 'foo', foo: string } | { kind: 'bar', bar: number }) { 90 const isFoo: boolean = obj.kind === 'foo'; 99 function f22(obj: { kind: 'foo', foo: string } | { kind: 'bar', bar: number }) { 100 let isFoo = obj.kind === 'foo'; 109 function f23(obj: { kind [all...] |
H A D | dependentDestructuredVariables.js | 3 | { kind: 'A', payload: number } 4 | { kind: 'B', payload: string }; 6 function f10({ kind, payload }: Action) { 7 if (kind === 'A') { 10 if (kind === 'B') { 16 const { kind, payload } = action; 17 if (kind === 'A') { 20 if (kind === 'B') { 25 function f12({ kind, payload }: Action) { 26 switch (kind) { [all...] |
H A D | discriminatedUnionTypes1.js | 3 kind: "square"; 8 kind: "rectangle"; 14 kind: "circle"; 21 if (s.kind === "square") { 24 else if (s.kind === "circle") { 27 else if (s.kind === "rectangle") { 36 switch (s.kind) { 48 switch (s.kind) { 57 switch (s.kind) { 66 { kind [all...] |
H A D | stringLiteralTypesAsTags02.js | 5 kind: Kind; 9 kind: "A"; 14 kind: "B"; 18 function hasKind(entity: Entity, kind: "A"): entity is A; 19 function hasKind(entity: Entity, kind: "B"): entity is B; 20 function hasKind(entity: Entity, kind: Kind): entity is (A | B) { 21 return entity.kind === kind; 25 kind: "A", 44 function hasKind(entity, kind) {
[all...] |
H A D | stringLiteralTypesAsTags03.js | 5 kind: Kind; 9 kind: "A"; 14 kind: "B"; 22 function hasKind(entity: Entity, kind: "A" | "A"): entity is A; 23 function hasKind(entity: Entity, kind: "B" | "B"): entity is B; 24 function hasKind(entity: Entity, kind: Kind): entity is Entity { 25 return entity.kind === kind; 29 kind: "A", 48 function hasKind(entity, kind) {
[all...] |
H A D | stringLiteralTypesAsTags01.js | 5 kind: Kind; 9 kind: "A"; 14 kind: "B"; 18 function hasKind(entity: Entity, kind: "A"): entity is A; 19 function hasKind(entity: Entity, kind: "B"): entity is B; 20 function hasKind(entity: Entity, kind: Kind): entity is Entity; 21 function hasKind(entity: Entity, kind: Kind): boolean { 22 return entity.kind === kind; 26 kind [all...] |
H A D | declarationNoDanglingGenerics.js | 2 const kindCache: { [kind: string]: boolean } = {}; 4 function register(kind: string): void | never { 5 if (kindCache[kind]) { 6 throw new Error(`Class with kind "${kind}" is already registered.`); 8 kindCache[kind] = true; 11 function ClassFactory<TKind extends string>(kind: TKind) { 12 register(kind); 15 static readonly THE_KIND: TKind = kind; 16 readonly kind [all...] |
H A D | controlFlowOptionalChain2.js | 31 type U = { kind: undefined, u: 'u' } 32 type N = { kind: null, n: 'n' } 33 type X = { kind: 'X', x: 'x' } 36 if (x?.kind === undefined) { 45 if (x?.kind === undefined) { 54 if (x?.kind === undefined) { 63 if (x?.kind === undefined) { 72 if (x?.kind === null) { 81 if (x?.kind === null) { 90 if (x?.kind [all...] |
H A D | exhaustiveSwitchStatements1.js | 56 interface Square { kind: "square"; size: number; } 58 interface Rectangle { kind: "rectangle"; width: number; height: number; } 60 interface Circle { kind: "circle"; radius: number; } 62 interface Triangle { kind: "triangle"; side: number; } 68 switch (s.kind) { 80 switch (s.kind) { 146 kind: "square"; 151 kind: "circle"; 158 switch (s1.kind) { 162 switch (s2.kind) { [all...] |
H A D | narrowingDestructuring.js | 2 type X = { kind: "a", a: string } | { kind: "b", b: string } 5 if (value.kind === "a") { 14 type Z = { kind: "f", f: { a: number, b: string, c: number } } 15 | { kind: "g", g: { a: string, b: number, c: string }}; 18 if (value.kind === "f") { 28 function func3<T extends { kind: "a", a: string } | { kind: "b", b: number }>(t: T) { 29 if (t.kind === "a") { 30 const { kind, [all...] |
H A D | stringLiteralTypesTypePredicates01.js | 4 function kindIs(kind: Kind, is: "A"): kind is "A"; 5 function kindIs(kind: Kind, is: "B"): kind is "B"; 6 function kindIs(kind: Kind, is: Kind): boolean { 7 return kind === is; 27 function kindIs(kind, is) {
28 return kind === is;
47 declare function kindIs(kind: Kind, is: "A"): kind i [all...] |
H A D | errorsForCallAndAssignmentAreSimilar.js | 4 | { kind: "hddvd" } 5 | { kind: "bluray" } 11 { kind: "bluray", }, 12 { kind: "hdpvd", } 16 { kind: "bluray", }, 17 { kind: "hdpvd", } 26 { kind: "bluray" },
27 { kind: "hdpvd" }
30 { kind: "bluray" },
31 { kind [all...] |
/third_party/node/deps/v8/src/objects/ |
H A D | function-kind.h | 72 inline bool IsArrowFunction(FunctionKind kind) { in IsArrowFunction() argument 73 return base::IsInRange(kind, FunctionKind::kArrowFunction, in IsArrowFunction() 77 inline bool IsModule(FunctionKind kind) { in IsModule() argument 78 return base::IsInRange(kind, FunctionKind::kModule, in IsModule() 82 inline bool IsAsyncModule(FunctionKind kind) { in IsAsyncModule() argument 83 return kind == FunctionKind::kAsyncModule; in IsAsyncModule() 86 inline bool IsAsyncGeneratorFunction(FunctionKind kind) { in IsAsyncGeneratorFunction() argument 87 return base::IsInRange(kind, FunctionKind::kAsyncConciseGeneratorMethod, in IsAsyncGeneratorFunction() 91 inline bool IsGeneratorFunction(FunctionKind kind) { in IsGeneratorFunction() argument 92 return base::IsInRange(kind, FunctionKin in IsGeneratorFunction() 96 IsAsyncFunction(FunctionKind kind) IsAsyncFunction() argument 101 IsResumableFunction(FunctionKind kind) IsResumableFunction() argument 105 IsConciseMethod(FunctionKind kind) IsConciseMethod() argument 112 IsStrictFunctionWithoutPrototype(FunctionKind kind) IsStrictFunctionWithoutPrototype() argument 121 IsGetterFunction(FunctionKind kind) IsGetterFunction() argument 126 IsSetterFunction(FunctionKind kind) IsSetterFunction() argument 131 IsAccessorFunction(FunctionKind kind) IsAccessorFunction() argument 136 IsDefaultConstructor(FunctionKind kind) IsDefaultConstructor() argument 141 IsBaseConstructor(FunctionKind kind) IsBaseConstructor() argument 146 IsDerivedConstructor(FunctionKind kind) IsDerivedConstructor() argument 151 IsClassConstructor(FunctionKind kind) IsClassConstructor() argument 156 IsClassMembersInitializerFunction(FunctionKind kind) IsClassMembersInitializerFunction() argument 161 IsConstructable(FunctionKind kind) IsConstructable() argument 166 IsStatic(FunctionKind kind) IsStatic() argument 181 BindsSuper(FunctionKind kind) BindsSuper() argument 186 IsAwaitAsIdentifierDisallowed(FunctionKind kind) IsAwaitAsIdentifierDisallowed() argument 194 FunctionKind2String(FunctionKind kind) FunctionKind2String() argument 254 operator <<(std::ostream& os, FunctionKind kind) operator <<() argument [all...] |
H A D | elements-kind.h | 79 // The "fast" kind for elements that only contain SMI values. Must be first 80 // to make it possible to efficiently check maps for this kind. 84 // The "fast" kind for tagged values. Must be second to make it possible to 85 // efficiently check maps for this and the PACKED_SMI_ELEMENTS kind 90 // The "fast" kind for unwrapped, non-tagged double values. 94 // The nonextensible kind for elements. 98 // The sealed kind for elements. 102 // The frozen kind for elements. 106 // The "slow" kind. 109 // Elements kind o 180 IsDictionaryElementsKind(ElementsKind kind) IsDictionaryElementsKind() argument 184 IsFastArgumentsElementsKind(ElementsKind kind) IsFastArgumentsElementsKind() argument 188 IsSlowArgumentsElementsKind(ElementsKind kind) IsSlowArgumentsElementsKind() argument 192 IsSloppyArgumentsElementsKind(ElementsKind kind) IsSloppyArgumentsElementsKind() argument 197 IsStringWrapperElementsKind(ElementsKind kind) IsStringWrapperElementsKind() argument 202 IsTypedArrayElementsKind(ElementsKind kind) IsTypedArrayElementsKind() argument 207 IsRabGsabTypedArrayElementsKind(ElementsKind kind) IsRabGsabTypedArrayElementsKind() argument 212 IsTypedArrayOrRabGsabTypedArrayElementsKind(ElementsKind kind) IsTypedArrayOrRabGsabTypedArrayElementsKind() argument 217 IsBigIntTypedArrayElementsKind(ElementsKind kind) IsBigIntTypedArrayElementsKind() argument 223 IsFloatTypedArrayElementsKind(ElementsKind kind) IsFloatTypedArrayElementsKind() argument 228 IsWasmArrayElementsKind(ElementsKind kind) IsWasmArrayElementsKind() argument 232 IsTerminalElementsKind(ElementsKind kind) IsTerminalElementsKind() argument 238 IsFastElementsKind(ElementsKind kind) IsFastElementsKind() argument 243 IsTransitionElementsKind(ElementsKind kind) IsTransitionElementsKind() argument 249 IsDoubleElementsKind(ElementsKind kind) IsDoubleElementsKind() argument 253 IsFixedFloatElementsKind(ElementsKind kind) IsFixedFloatElementsKind() argument 257 IsDoubleOrFloatElementsKind(ElementsKind kind) IsDoubleOrFloatElementsKind() argument 262 IsAnyNonextensibleElementsKindUnchecked(ElementsKind kind) IsAnyNonextensibleElementsKindUnchecked() argument 267 IsAnyNonextensibleElementsKind(ElementsKind kind) IsAnyNonextensibleElementsKind() argument 273 IsNonextensibleElementsKind(ElementsKind kind) IsNonextensibleElementsKind() argument 281 IsSealedElementsKind(ElementsKind kind) IsSealedElementsKind() argument 288 IsFrozenElementsKind(ElementsKind kind) IsFrozenElementsKind() argument 295 IsSmiOrObjectElementsKind(ElementsKind kind) IsSmiOrObjectElementsKind() argument 299 IsSmiElementsKind(ElementsKind kind) IsSmiElementsKind() argument 303 IsFastNumberElementsKind(ElementsKind kind) IsFastNumberElementsKind() argument 307 IsObjectElementsKind(ElementsKind kind) IsObjectElementsKind() argument 311 IsAnyHoleyNonextensibleElementsKind(ElementsKind kind) IsAnyHoleyNonextensibleElementsKind() argument 320 IsHoleyElementsKind(ElementsKind kind) IsHoleyElementsKind() argument 324 IsHoleyElementsKindForRead(ElementsKind kind) IsHoleyElementsKindForRead() argument 328 IsHoleyOrDictionaryElementsKind(ElementsKind kind) IsHoleyOrDictionaryElementsKind() argument 332 IsFastPackedElementsKind(ElementsKind kind) IsFastPackedElementsKind() argument [all...] |
H A D | code-kind.h | 48 const char* CodeKindToString(CodeKind kind); 50 const char* CodeKindToMarker(CodeKind kind); 52 inline constexpr bool CodeKindIsInterpretedJSFunction(CodeKind kind) { 53 return kind == CodeKind::INTERPRETED_FUNCTION; 56 inline constexpr bool CodeKindIsBaselinedJSFunction(CodeKind kind) { 57 return kind == CodeKind::BASELINE; 60 inline constexpr bool CodeKindIsUnoptimizedJSFunction(CodeKind kind) { 63 return base::IsInRange(kind, CodeKind::INTERPRETED_FUNCTION, 67 inline constexpr bool CodeKindIsOptimizedJSFunction(CodeKind kind) { 70 return base::IsInRange(kind, CodeKin [all...] |
/third_party/node/deps/v8/src/ast/ |
H A D | ast-source-ranges.h | 75 virtual SourceRange GetRange(SourceRangeKind kind) = 0; 76 virtual bool HasRange(SourceRangeKind kind) = 0; 85 SourceRange GetRange(SourceRangeKind kind) override { 86 DCHECK(HasRange(kind)); 90 bool HasRange(SourceRangeKind kind) override { 91 return kind == SourceRangeKind::kRight; 103 SourceRange GetRange(SourceRangeKind kind) override { 104 DCHECK(HasRange(kind)); 108 bool HasRange(SourceRangeKind kind) override { 109 return kind [all...] |
/third_party/node/deps/v8/src/wasm/ |
H A D | value-type.h | 29 // Format: kind, log2Size, code, machineType, shortName, typeName 186 #define DEF_ENUM(kind, ...) k##kind, 191 constexpr bool is_numeric(ValueKind kind) { in is_numeric() argument 192 switch (kind) { in is_numeric() 193 #define NUMERIC_CASE(kind, ...) \ in is_numeric() 194 case k##kind: \ in is_numeric() 203 constexpr bool is_reference(ValueKind kind) { in is_reference() argument 204 return kind == kRef || kind in is_reference() 207 is_object_reference(ValueKind kind) is_object_reference() argument 211 value_kind_size_log2(ValueKind kind) value_kind_size_log2() argument 223 value_kind_size(ValueKind kind) value_kind_size() argument 236 value_kind_full_size(ValueKind kind) value_kind_full_size() argument 244 short_name(ValueKind kind) short_name() argument 254 name(ValueKind kind) name() argument 265 machine_type(ValueKind kind) machine_type() argument 278 is_packed(ValueKind kind) is_packed() argument 279 unpacked(ValueKind kind) unpacked() argument 283 is_rtt(ValueKind kind) is_rtt() argument 285 is_defaultable(ValueKind kind) is_defaultable() argument 302 Primitive(ValueKind kind) Primitive() argument 322 FromIndex(ValueKind kind, uint32_t index) FromIndex() argument 372 constexpr ValueKind kind() const { return KindField::decode(bit_field_); } kind() function in v8::internal::wasm::ValueType 538 CanonicalWithRelativeIndex(ValueKind kind, uint32_t index) CanonicalWithRelativeIndex() argument [all...] |
/third_party/PyYAML/lib/yaml/ |
H A D | resolver.py | 38 def add_path_resolver(cls, tag, path, kind=None): 44 # matches any kind of a node. `index_check` could be `None`, a boolean 80 if kind is str: 81 kind = ScalarNode 82 elif kind is list: 83 kind = SequenceNode 84 elif kind is dict: 85 kind = MappingNode 86 elif kind not in [ScalarNode, SequenceNode, MappingNode] \ 87 and kind i [all...] |
/third_party/python/Lib/ |
H A D | pipes.py | 33 t.append(command, kind) 34 where kind is a string of two characters: the first is '-' if the 42 t.prepend(command, kind) 113 def append(self, cmd, kind): 114 """t.append(cmd, kind) adds a new step at the end.""" 117 if kind not in stepkinds: 118 raise ValueError('Template.append: bad kind %r' % (kind,)) 119 if kind == SOURCE: 123 if kind[ [all...] |
/third_party/python/Tools/c-analyzer/c_parser/ |
H A D | match.py | 29 return _KIND.is_type_decl(item.kind) 33 return _KIND.is_decl(item.kind) 62 if decl.kind is _KIND.TYPEDEF: 66 elif decl.kind is _KIND.FUNCTION: 69 elif decl.kind is _KIND.VARIABLE: 77 return decl.kind in (_KIND.VARIABLE, _KIND.FUNCTION) 85 if decl.kind is _KIND.FUNCTION: 104 if decl.kind is _KIND.FUNCTION: 111 if not decl.kind is _KIND.VARIABLE: 117 if not decl.kind i [all...] |
/third_party/python/Tools/scripts/ |
H A D | highlight.py | 34 kind = tok_str = '' 40 kind = '' 42 kind = 'comment' 44 kind = 'operator' 46 kind = 'string' 48 kind = 'docstring' 51 kind = 'definition' 53 kind = 'defname' 55 kind = 'keyword' 57 kind [all...] |
/third_party/icu/icu4j/main/classes/core/src/com/ibm/icu/impl/ |
H A D | ICULocaleService.java | 37 * get(ULocale, int, ULocale[]) with KIND_ANY for kind and null for 48 public Object get(ULocale locale, int kind) { in get() argument 49 return get(locale, kind, null); in get() 54 * get(ULocale, int, ULocale[]) with KIND_ANY for kind. 62 * createKey(ULocale.toString(), kind) to create a key, calls getKey, and then 66 public Object get(ULocale locale, int kind, ULocale[] actualReturn) { in get() argument 67 Key key = createKey(locale, kind); in get() 86 * registerObject(Object, ULocale, int kind, boolean visible) 87 * passing KIND_ANY for the kind, and true for the visibility. 95 * registerObject(Object, ULocale, int kind, boolea 107 registerObject(Object obj, ULocale locale, int kind) registerObject() argument 115 registerObject(Object obj, ULocale locale, int kind, boolean visible) registerObject() argument 163 private int kind; global() field in ICULocaleService.LocaleKey 181 createWithCanonicalFallback(String primaryID, String canonicalFallbackID, int kind) createWithCanonicalFallback() argument 192 createWithCanonical(ULocale locale, String canonicalFallbackID, int kind) createWithCanonical() argument 206 LocaleKey(String primaryID, String canonicalPrimaryID, String canonicalFallbackID, int kind) LocaleKey() argument 244 public int kind() { kind() method in ICULocaleService.LocaleKey 437 handleCreate(ULocale loc, int kind, ICUService service) handleCreate() argument 481 private final int kind; global() field in ICULocaleService.SimpleLocaleKeyFactory 484 SimpleLocaleKeyFactory(Object obj, ULocale locale, int kind, boolean visible) SimpleLocaleKeyFactory() argument 488 SimpleLocaleKeyFactory(Object obj, ULocale locale, int kind, boolean visible, String name) SimpleLocaleKeyFactory() argument 592 handleCreate(ULocale loc, int kind, ICUService service) handleCreate() argument 629 createKey(String id, int kind) createKey() argument 633 createKey(ULocale l, int kind) createKey() argument [all...] |
/third_party/icu/ohos_icu4j/src/main/java/ohos/global/icu/impl/ |
H A D | ICULocaleService.java | 41 * get(ULocale, int, ULocale[]) with KIND_ANY for kind and null for 52 public Object get(ULocale locale, int kind) { in get() argument 53 return get(locale, kind, null); in get() 58 * get(ULocale, int, ULocale[]) with KIND_ANY for kind. 66 * createKey(ULocale.toString(), kind) to create a key, calls getKey, and then 70 public Object get(ULocale locale, int kind, ULocale[] actualReturn) { in get() argument 71 Key key = createKey(locale, kind); in get() 90 * registerObject(Object, ULocale, int kind, boolean visible) 91 * passing KIND_ANY for the kind, and true for the visibility. 99 * registerObject(Object, ULocale, int kind, boolea 111 registerObject(Object obj, ULocale locale, int kind) registerObject() argument 119 registerObject(Object obj, ULocale locale, int kind, boolean visible) registerObject() argument 168 private int kind; global() field in ICULocaleService.LocaleKey 186 createWithCanonicalFallback(String primaryID, String canonicalFallbackID, int kind) createWithCanonicalFallback() argument 197 createWithCanonical(ULocale locale, String canonicalFallbackID, int kind) createWithCanonical() argument 211 LocaleKey(String primaryID, String canonicalPrimaryID, String canonicalFallbackID, int kind) LocaleKey() argument 249 public int kind() { kind() method in ICULocaleService.LocaleKey 443 handleCreate(ULocale loc, int kind, ICUService service) handleCreate() argument 488 private final int kind; global() field in ICULocaleService.SimpleLocaleKeyFactory 491 SimpleLocaleKeyFactory(Object obj, ULocale locale, int kind, boolean visible) SimpleLocaleKeyFactory() argument 495 SimpleLocaleKeyFactory(Object obj, ULocale locale, int kind, boolean visible, String name) SimpleLocaleKeyFactory() argument 600 handleCreate(ULocale loc, int kind, ICUService service) handleCreate() argument 637 createKey(String id, int kind) createKey() argument 641 createKey(ULocale l, int kind) createKey() argument [all...] |
/third_party/node/deps/v8/tools/profview/ |
H A D | profile-utils.js | 36 if (code.kind === "LoadIC" || 37 code.kind === "StoreIC" || 38 code.kind === "KeyedStoreIC" || 39 code.kind === "KeyedLoadIC" || 40 code.kind === "LoadGlobalIC" || 41 code.kind === "Handler") { 43 } else if (code.kind === "BytecodeHandler") { 45 } else if (code.kind === "Stub") { 47 } else if (code.kind === "Builtin") { 49 } else if (code.kind [all...] |
/third_party/rust/crates/regex/regex-syntax/src/ast/ |
H A D | parse.rs | 318 kind: ast::ClassSetBinaryOpKind, 383 fn error(&self, span: Span, kind: ast::ErrorKind) -> ast::Error { in error() 384 ast::Error { kind, pattern: self.pattern().to_string(), span } in error() 876 set.kind = prevset; in pop_class() 919 .push(ClassState::Op { kind: next_kind, lhs: new_lhs }); in push_class_op() 931 let (kind, lhs) = match stack.pop() { in pop_class_op() 932 Some(ClassState::Op { kind, lhs }) => (kind, lhs), in pop_class_op() 942 kind, in pop_class_op() 1011 /// The given `kind` shoul [all...] |