/third_party/typescript/tests/baselines/reference/ |
D | propagationOfPromiseInitialization.types | 15 >foo.then((x) => { // x is inferred to be a number return "asdf";}).then((x) => { // x is … 16 >foo.then((x) => { // x is inferred to be a number return "asdf";}).then : <TResult>(successC… 17 >foo.then((x) => { // x is inferred to be a number return "asdf";}) : IPromise<string> 21 >(x) => { // x is inferred to be a number return "asdf";} : (x: number) => string 24 // x is inferred to be a number 30 >(x) => { // x is inferred to be string x.length; return 123;} : (x: string) => number 33 // x is inferred to be string
|
D | switchCaseNarrowsMatchingClausesEvenWhenNonMatchingClausesExist.types | 4 >(str: string) => { switch (str) { case 'abc': { // inferred type as `abc` re… 13 // inferred type as `abc` 25 >(str: string, someOtherStr: string) => { switch (str) { case 'abc': { // inferred t… 35 // inferred type should be `abc` 54 … case 'abc': { // inferred type should be `abc` return str; } case someN… 64 // inferred type should be `abc` 71 // inferred type should be `number`
|
D | declarationFiles.errors.txt | 2 tests/cases/conformance/types/thisType/declarationFiles.ts(30,5): error TS2527: The inferred type o… 3 tests/cases/conformance/types/thisType/declarationFiles.ts(32,5): error TS2527: The inferred type o… 4 tests/cases/conformance/types/thisType/declarationFiles.ts(34,5): error TS2527: The inferred type o… 5 tests/cases/conformance/types/thisType/declarationFiles.ts(40,5): error TS2527: The inferred type o… 42 !!! error TS2527: The inferred type of 'x1' references an inaccessible 'this' type. A type annotati… 46 !!! error TS2527: The inferred type of 'x3' references an inaccessible 'this' type. A type annotati… 50 !!! error TS2527: The inferred type of 'f1' references an inaccessible 'this' type. A type annotati… 58 !!! error TS2527: The inferred type of 'f3' references an inaccessible 'this' type. A type annotati…
|
D | targetTypeTest1.errors.txt | 16 // Because Point is a constructor function, this is inferred 17 // to be Point and return type is inferred to be void 35 // this inferred as Point because of obj.prop assignment 36 // dx, dy, and return type inferred using target typing 43 // Object literal type inferred using target typing 44 // this in function add inferred to be type of object literal (i.e. Point) 45 // dx, dy, and return type of add inferred using target typing
|
D | switchCaseNarrowsMatchingClausesEvenWhenNonMatchingClausesExist.symbols | 10 // inferred type as `abc` 28 // inferred type should be `abc` 53 // inferred type should be `abc` 60 // inferred type should be `number`
|
D | declarationEmitExportAssignedNamespaceNoTripleSlashTypesReference.symbols | 55 === tests/cases/compiler/src/inferred-comp-export.ts === 57 >getComp : Symbol(getComp, Decl(inferred-comp-export.ts, 0, 8)) 62 >obj : Symbol(obj, Decl(inferred-comp-export.ts, 4, 12)) 65 >comp : Symbol(comp, Decl(inferred-comp-export.ts, 4, 20)) 66 >getComp : Symbol(getComp, Decl(inferred-comp-export.ts, 0, 8))
|
D | targetTypeTest1.types | 26 // Because Point is a constructor function, this is inferred 27 // to be Point and return type is inferred to be void 80 // this inferred as Point because of obj.prop assignment 81 // dx, dy, and return type inferred using target typing 113 // Object literal type inferred using target typing 114 // this in function add inferred to be type of object literal (i.e. Point) 115 // dx, dy, and return type of add inferred using target typing
|
D | targetTypeTest1.symbols | 28 // Because Point is a constructor function, this is inferred 29 // to be Point and return type is inferred to be void 66 // this inferred as Point because of obj.prop assignment 67 // dx, dy, and return type inferred using target typing 87 // Object literal type inferred using target typing 88 // this in function add inferred to be type of object literal (i.e. Point) 89 // dx, dy, and return type of add inferred using target typing
|
D | propagationOfPromiseInitialization.symbols | 25 >foo.then((x) => { // x is inferred to be a number return "asdf";}).then : Symbol(IPromise.th… 31 // x is inferred to be a number 37 // x is inferred to be string
|
D | declarationEmitExpressionWithNonlocalPrivateUniqueSymbol.errors.txt | 1 tests/cases/compiler/b.ts(2,14): error TS2527: The inferred type of 'A1' references an inaccessible… 11 !!! error TS2527: The inferred type of 'A1' references an inaccessible 'unique symbol' type. A type…
|
D | inferenceShouldFailOnEvolvingArrays.errors.txt | 19 z = logLength(42); // no error; T is inferred as `any` 31 zz.push(logLength(42)); // no error; T is inferred as `any` 34 zz = logFirstLength([42]); // no error; T is inferred as `any[]`
|
D | hugeDeclarationOutputGetsTruncatedWithError.errors.txt | 1 …hugeDeclarationOutputGetsTruncatedWithError.ts(5,14): error TS7056: The inferred type of this node… 11 !!! error TS7056: The inferred type of this node exceeds the maximum length the compiler will seria…
|
D | constructorOverloads7.errors.txt | 17 // Because Point is a constructor function, this is inferred 18 // to be Point and return type is inferred to be void
|
D | arrayFakeFlatNoCrashInferenceDeclarations.errors.txt | 1 …/arrayFakeFlatNoCrashInferenceDeclarations.ts(13,10): error TS5088: The inferred type of 'foo' ref… 19 !!! error TS5088: The inferred type of 'foo' references a type with a cyclic structure which cannot…
|
D | bigintWithoutLib.symbols | 18 bigintVal = bigintVal.valueOf(); // should error - bigintVal inferred as {} 24 let stringVal: string = bigintVal.toString(); // should not error - bigintVal inferred as {} 30 stringVal = bigintVal.toString(2); // should error - bigintVal inferred as {} 36 stringVal = bigintVal.toLocaleString(); // should not error - bigintVal inferred as {} 42 stringVal = bigintVal.toLocaleString('de-DE'); // should not error - bigintVal inferred as {} 48 …tVal.toLocaleString('de-DE', { style: 'currency' }); // should not error - bigintVal inferred as {} 55 …ing('de-DE', { style: 'currency', currency: 'EUR' }) // should not error - bigintVal inferred as {}
|
D | bigintWithoutLib.types | 43 bigintVal = bigintVal.valueOf(); // should error - bigintVal inferred as {} 51 let stringVal: string = bigintVal.toString(); // should not error - bigintVal inferred as {} 58 stringVal = bigintVal.toString(2); // should error - bigintVal inferred as {} 67 stringVal = bigintVal.toLocaleString(); // should not error - bigintVal inferred as {} 75 stringVal = bigintVal.toLocaleString('de-DE'); // should not error - bigintVal inferred as {} 84 …tVal.toLocaleString('de-DE', { style: 'currency' }); // should not error - bigintVal inferred as {} 96 …ing('de-DE', { style: 'currency', currency: 'EUR' }) // should not error - bigintVal inferred as {}
|
D | inferenceShouldFailOnEvolvingArrays.types | 28 z = logLength(42); // no error; T is inferred as `any` 63 zz.push(logLength(42)); // no error; T is inferred as `any` 72 zz = logFirstLength([42]); // no error; T is inferred as `any[]`
|
D | constructorOverloads7.types | 26 // Because Point is a constructor function, this is inferred 27 // to be Point and return type is inferred to be void
|
D | declarationEmitCommonJsModuleReferencedType.errors.txt | 1 tests/cases/compiler/r/entry.ts(3,14): error TS2742: The inferred type of 'x' cannot be named witho… 26 !!! error TS2742: The inferred type of 'x' cannot be named without a reference to 'foo/node_modules…
|
D | inferenceShouldFailOnEvolvingArrays.symbols | 32 z = logLength(42); // no error; T is inferred as `any` 64 zz.push(logLength(42)); // no error; T is inferred as `any` 70 zz = logFirstLength([42]); // no error; T is inferred as `any[]`
|
D | constructorOverloads7.symbols | 28 // Because Point is a constructor function, this is inferred 29 // to be Point and return type is inferred to be void
|
/third_party/mindspore/tests/ut/cpp/pipeline/static_analysis/ |
D | prim_test.cc | 142 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 167 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 192 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 209 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 227 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 243 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 283 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 304 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 317 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 330 AbstractBasePtr res = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() [all …]
|
D | static_analysis_test.cc | 167 AbstractBasePtr abs_base_got = engine_->Run(func_graph, args_spec_list).inferred->abstract(); in TEST_F() 265 AbstractBasePtr abs_base_got = engine_->Run(graph_f_, args_spec_list).inferred->abstract(); in TEST_F() 276 abs_base_got = engine_->Run(graph_alpha_, args_spec_list).inferred->abstract(); in TEST_F() 362 AbstractBasePtr abs_base_got = engine_->Run(func_graph_, args_spec_list).inferred->abstract(); in TEST_F() 394 AbstractBasePtr abs_base_got = engine_->Run(func_graph, args_spec).inferred->abstract(); in TEST_F()
|
/third_party/mindspore/tests/ut/cpp/operator/ |
D | composite_test.cc | 162 …t = dyn_cast<AbstractTuple>(engine_->Run(tupleSliceGraphPtr, args_spec_list).inferred->abstract()); in TEST_F() 188 …t = dyn_cast<AbstractTuple>(engine_->Run(tupleSliceGraphPtr, args_spec_list).inferred->abstract()); in TEST_F() 214 …t = dyn_cast<AbstractTuple>(engine_->Run(tupleSliceGraphPtr, args_spec_list).inferred->abstract()); in TEST_F() 240 …t = dyn_cast<AbstractTuple>(engine_->Run(tupleSliceGraphPtr, args_spec_list).inferred->abstract()); in TEST_F() 267 …t = dyn_cast<AbstractTuple>(engine_->Run(unPackCallGraphPtr, args_spec_list).inferred->abstract()); in TEST_F() 294 …t = dyn_cast<AbstractTuple>(engine_->Run(unPackCallGraphPtr, args_spec_list).inferred->abstract()); in TEST_F() 316 …Ptr ret = dyn_cast<AbstractTuple>(engine_->Run(zip_op_graph, args_spec_list).inferred->abstract()); in TEST_F()
|
/third_party/typescript_eslint/packages/eslint-plugin/docs/rules/ |
D | no-inferrable-types.md | 3 Explicit types where they can be easily inferred may add unnecessary verbosity. 8 and properties where the type can be easily inferred from its value. 138 If you do not want to enforce inferred types.
|