Skip to content

Commit c1592ad

Browse files
authored
Remove compiler runner libFiles option entirely (#63060)
1 parent 2fed590 commit c1592ad

File tree

497 files changed

+3804
-3203
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

497 files changed

+3804
-3203
lines changed

src/harness/harnessIO.ts

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,6 @@ export namespace Compiler {
240240
interface HarnessOptions {
241241
useCaseSensitiveFileNames?: boolean;
242242
baselineFile?: string;
243-
libFiles?: string;
244243
noTypesAndSymbols?: boolean;
245244
captureSuggestions?: boolean;
246245
}
@@ -251,7 +250,6 @@ export namespace Compiler {
251250
{ name: "useCaseSensitiveFileNames", type: "boolean", defaultValueDescription: false },
252251
{ name: "baselineFile", type: "string" },
253252
{ name: "fileName", type: "string" },
254-
{ name: "libFiles", type: "string" },
255253
{ name: "noErrorTruncation", type: "boolean", defaultValueDescription: false },
256254
{ name: "suppressOutputPathCheck", type: "boolean", defaultValueDescription: false },
257255
{ name: "noImplicitReferences", type: "boolean", defaultValueDescription: false },
@@ -368,13 +366,6 @@ export namespace Compiler {
368366
.map(file => options.configFile ? ts.getNormalizedAbsolutePath(file.unitName, currentDirectory) : file.unitName)
369367
.filter(fileName => !ts.fileExtensionIs(fileName, ts.Extension.Json));
370368

371-
// Files from tests\lib that are requested by "@libFiles"
372-
if (options.libFiles) {
373-
for (const fileName of options.libFiles.split(",")) {
374-
programFileNames.push(vpath.combine(vfs.testLibFolder, fileName));
375-
}
376-
}
377-
378369
const docs = inputFiles.concat(otherFiles).map(documents.TextDocument.fromTestFile);
379370
const fs = vfs.createFromFileSystem(IO, !useCaseSensitiveFileNames, { documents: docs, cwd: currentDirectory });
380371
if (symlinks) {
@@ -1008,7 +999,7 @@ export namespace Compiler {
1008999

10091000
function fileOutput(file: documents.TextDocument, harnessSettings: TestCaseParser.CompilerSettings): string {
10101001
const fileName = harnessSettings.fullEmitPaths ? Utils.removeTestPathPrefixes(file.file) : ts.getBaseFileName(file.file);
1011-
return "//// [" + fileName + "]\r\n" + Utils.removeTestPathPrefixes(file.text);
1002+
return "//// [" + fileName + "]\r\n" + file.text;
10121003
}
10131004

10141005
export function collateOutputs(outputFiles: readonly documents.TextDocument[]): string {

tests/baselines/reference/booleanLiteralsContextuallyTypedFromUnion.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
//// [tests/cases/compiler/booleanLiteralsContextuallyTypedFromUnion.tsx] ////
22

33
//// [booleanLiteralsContextuallyTypedFromUnion.tsx]
4+
/// <reference path="/.lib/react.d.ts" />
45
interface A { isIt: true; text: string; }
56
interface B { isIt: false; value: number; }
67
type C = A | B;
@@ -28,6 +29,7 @@ let Success = () => <Funk {...attrs2} />
2829

2930
//// [booleanLiteralsContextuallyTypedFromUnion.jsx]
3031
"use strict";
32+
/// <reference path="/.lib/react.d.ts" />
3133
var isIt = Math.random() > 0.5;
3234
var c = isIt ? { isIt: isIt, text: 'hey' } : { isIt: isIt, value: 123 };
3335
var cc = isIt ? { isIt: isIt, text: 'hey' } : { isIt: isIt, value: 123 };
Lines changed: 52 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,99 +1,100 @@
11
//// [tests/cases/compiler/booleanLiteralsContextuallyTypedFromUnion.tsx] ////
22

33
=== booleanLiteralsContextuallyTypedFromUnion.tsx ===
4+
/// <reference path="react.d.ts" />
45
interface A { isIt: true; text: string; }
56
>A : Symbol(A, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 0, 0))
6-
>isIt : Symbol(A.isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 0, 13))
7-
>text : Symbol(A.text, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 0, 25))
7+
>isIt : Symbol(A.isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 1, 13))
8+
>text : Symbol(A.text, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 1, 25))
89

910
interface B { isIt: false; value: number; }
10-
>B : Symbol(B, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 0, 41))
11-
>isIt : Symbol(B.isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 1, 13))
12-
>value : Symbol(B.value, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 1, 26))
11+
>B : Symbol(B, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 1, 41))
12+
>isIt : Symbol(B.isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 2, 13))
13+
>value : Symbol(B.value, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 2, 26))
1314

1415
type C = A | B;
15-
>C : Symbol(C, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 1, 43))
16+
>C : Symbol(C, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 2, 43))
1617
>A : Symbol(A, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 0, 0))
17-
>B : Symbol(B, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 0, 41))
18+
>B : Symbol(B, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 1, 41))
1819

1920
const isIt = Math.random() > 0.5;
20-
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 3, 5))
21+
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 5))
2122
>Math.random : Symbol(Math.random, Decl(lib.es5.d.ts, --, --))
2223
>Math : Symbol(Math, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --), Decl(lib.es2015.core.d.ts, --, --), Decl(lib.es2015.symbol.wellknown.d.ts, --, --))
2324
>random : Symbol(Math.random, Decl(lib.es5.d.ts, --, --))
2425

2526
const c: C = isIt ? { isIt, text: 'hey' } : { isIt, value: 123 };
26-
>c : Symbol(c, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 5))
27-
>C : Symbol(C, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 1, 43))
28-
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 3, 5))
29-
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 21))
30-
>text : Symbol(text, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 27))
31-
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 45))
32-
>value : Symbol(value, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 51))
27+
>c : Symbol(c, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 5))
28+
>C : Symbol(C, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 2, 43))
29+
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 5))
30+
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 21))
31+
>text : Symbol(text, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 27))
32+
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 45))
33+
>value : Symbol(value, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 51))
3334

3435
const cc: C = isIt ? { isIt: isIt, text: 'hey' } : { isIt: isIt, value: 123 };
35-
>cc : Symbol(cc, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 5))
36-
>C : Symbol(C, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 1, 43))
37-
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 3, 5))
38-
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 22))
39-
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 3, 5))
40-
>text : Symbol(text, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 34))
41-
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 52))
42-
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 3, 5))
43-
>value : Symbol(value, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 64))
36+
>cc : Symbol(cc, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 6, 5))
37+
>C : Symbol(C, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 2, 43))
38+
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 5))
39+
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 6, 22))
40+
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 5))
41+
>text : Symbol(text, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 6, 34))
42+
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 6, 52))
43+
>isIt : Symbol(isIt, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 4, 5))
44+
>value : Symbol(value, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 6, 64))
4445

4546
type ComponentProps =
46-
>ComponentProps : Symbol(ComponentProps, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 78))
47+
>ComponentProps : Symbol(ComponentProps, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 6, 78))
4748

4849
| {
4950
optionalBool: true;
50-
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 8, 7))
51+
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 9, 7))
5152

5253
mandatoryFn: () => void;
53-
>mandatoryFn : Symbol(mandatoryFn, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 9, 27))
54+
>mandatoryFn : Symbol(mandatoryFn, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 10, 27))
5455
}
5556
| {
5657
optionalBool: false;
57-
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 12, 7))
58+
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 13, 7))
5859

5960
};
6061

6162
let Funk = (_props: ComponentProps) => <div>Hello</div>;
62-
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 16, 3))
63-
>_props : Symbol(_props, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 16, 12))
64-
>ComponentProps : Symbol(ComponentProps, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 5, 78))
63+
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 17, 3))
64+
>_props : Symbol(_props, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 17, 12))
65+
>ComponentProps : Symbol(ComponentProps, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 6, 78))
6566
>div : Symbol(JSX.IntrinsicElements.div, Decl(react.d.ts, 2400, 45))
6667
>div : Symbol(JSX.IntrinsicElements.div, Decl(react.d.ts, 2400, 45))
6768

6869
let Fail1 = () => <Funk mandatoryFn={() => { }} optionalBool={true} />
69-
>Fail1 : Symbol(Fail1, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 18, 3))
70-
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 16, 3))
71-
>mandatoryFn : Symbol(mandatoryFn, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 18, 23))
72-
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 18, 47))
73-
74-
let Fail2 = () => <Funk mandatoryFn={() => { }} optionalBool={true as true} />
75-
>Fail2 : Symbol(Fail2, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 19, 3))
76-
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 16, 3))
70+
>Fail1 : Symbol(Fail1, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 19, 3))
71+
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 17, 3))
7772
>mandatoryFn : Symbol(mandatoryFn, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 19, 23))
7873
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 19, 47))
7974

75+
let Fail2 = () => <Funk mandatoryFn={() => { }} optionalBool={true as true} />
76+
>Fail2 : Symbol(Fail2, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 20, 3))
77+
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 17, 3))
78+
>mandatoryFn : Symbol(mandatoryFn, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 20, 23))
79+
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 20, 47))
80+
8081
let True = true as true;
81-
>True : Symbol(True, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 20, 3))
82+
>True : Symbol(True, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 21, 3))
8283

8384
let Fail3 = () => <Funk mandatoryFn={() => { }} optionalBool={True} />
84-
>Fail3 : Symbol(Fail3, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 21, 3))
85-
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 16, 3))
86-
>mandatoryFn : Symbol(mandatoryFn, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 21, 23))
87-
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 21, 47))
88-
>True : Symbol(True, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 20, 3))
85+
>Fail3 : Symbol(Fail3, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 22, 3))
86+
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 17, 3))
87+
>mandatoryFn : Symbol(mandatoryFn, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 22, 23))
88+
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 22, 47))
89+
>True : Symbol(True, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 21, 3))
8990

9091
let attrs2 = { optionalBool: true as true, mandatoryFn: () => { } }
91-
>attrs2 : Symbol(attrs2, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 22, 3))
92-
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 22, 14))
93-
>mandatoryFn : Symbol(mandatoryFn, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 22, 42))
92+
>attrs2 : Symbol(attrs2, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 23, 3))
93+
>optionalBool : Symbol(optionalBool, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 23, 14))
94+
>mandatoryFn : Symbol(mandatoryFn, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 23, 42))
9495

9596
let Success = () => <Funk {...attrs2} />
96-
>Success : Symbol(Success, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 23, 3))
97-
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 16, 3))
98-
>attrs2 : Symbol(attrs2, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 22, 3))
97+
>Success : Symbol(Success, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 24, 3))
98+
>Funk : Symbol(Funk, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 17, 3))
99+
>attrs2 : Symbol(attrs2, Decl(booleanLiteralsContextuallyTypedFromUnion.tsx, 23, 3))
99100

tests/baselines/reference/booleanLiteralsContextuallyTypedFromUnion.types

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
//// [tests/cases/compiler/booleanLiteralsContextuallyTypedFromUnion.tsx] ////
22

33
=== booleanLiteralsContextuallyTypedFromUnion.tsx ===
4+
/// <reference path="react.d.ts" />
45
interface A { isIt: true; text: string; }
56
>isIt : true
67
> : ^^^^

tests/baselines/reference/callsOnComplexSignatures.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
112112
return (mod && mod.__esModule) ? mod : { "default": mod };
113113
};
114114
Object.defineProperty(exports, "__esModule", { value: true });
115-
/// <reference path="react16.d.ts" />
115+
/// <reference path="/.lib/react16.d.ts" />
116116
var react_1 = __importDefault(require("react"));
117117
// Simple calls from real usecases
118118
function test1() {

tests/baselines/reference/checkJsxChildrenCanBeTupleType.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const testErr = <ResizablePanel>
2525

2626
//// [checkJsxChildrenCanBeTupleType.js]
2727
"use strict";
28-
/// <reference path="react16.d.ts" />
28+
/// <reference path="/.lib/react16.d.ts" />
2929
var __extends = (this && this.__extends) || (function () {
3030
var extendStatics = function (d, b) {
3131
extendStatics = Object.setPrototypeOf ||

tests/baselines/reference/checkJsxChildrenProperty1.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
//// [tests/cases/conformance/jsx/checkJsxChildrenProperty1.tsx] ////
22

33
//// [file.tsx]
4+
/// <reference path="/.lib/react.d.ts" />
5+
46
import React = require('react');
57

68
interface Prop {
@@ -26,6 +28,7 @@ let k2 =
2628

2729
//// [file.jsx]
2830
"use strict";
31+
/// <reference path="/.lib/react.d.ts" />
2932
Object.defineProperty(exports, "__esModule", { value: true });
3033
var React = require("react");
3134
function Comp(p) {
Lines changed: 27 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,69 +1,71 @@
11
//// [tests/cases/conformance/jsx/checkJsxChildrenProperty1.tsx] ////
22

33
=== file.tsx ===
4+
/// <reference path="react.d.ts" />
5+
46
import React = require('react');
57
>React : Symbol(React, Decl(file.tsx, 0, 0))
68

79
interface Prop {
8-
>Prop : Symbol(Prop, Decl(file.tsx, 0, 32))
10+
>Prop : Symbol(Prop, Decl(file.tsx, 2, 32))
911

1012
a: number,
11-
>a : Symbol(Prop.a, Decl(file.tsx, 2, 16))
13+
>a : Symbol(Prop.a, Decl(file.tsx, 4, 16))
1214

1315
b: string,
14-
>b : Symbol(Prop.b, Decl(file.tsx, 3, 14))
16+
>b : Symbol(Prop.b, Decl(file.tsx, 5, 14))
1517

1618
children: string | JSX.Element
17-
>children : Symbol(Prop.children, Decl(file.tsx, 4, 14))
19+
>children : Symbol(Prop.children, Decl(file.tsx, 6, 14))
1820
>JSX : Symbol(JSX, Decl(react.d.ts, 2353, 1))
1921
>Element : Symbol(JSX.Element, Decl(react.d.ts, 2356, 27))
2022
}
2123

2224
function Comp(p: Prop) {
23-
>Comp : Symbol(Comp, Decl(file.tsx, 6, 1))
24-
>p : Symbol(p, Decl(file.tsx, 8, 14))
25-
>Prop : Symbol(Prop, Decl(file.tsx, 0, 32))
25+
>Comp : Symbol(Comp, Decl(file.tsx, 8, 1))
26+
>p : Symbol(p, Decl(file.tsx, 10, 14))
27+
>Prop : Symbol(Prop, Decl(file.tsx, 2, 32))
2628

2729
return <div>{p.b}</div>;
2830
>div : Symbol(JSX.IntrinsicElements.div, Decl(react.d.ts, 2400, 45))
29-
>p.b : Symbol(Prop.b, Decl(file.tsx, 3, 14))
30-
>p : Symbol(p, Decl(file.tsx, 8, 14))
31-
>b : Symbol(Prop.b, Decl(file.tsx, 3, 14))
31+
>p.b : Symbol(Prop.b, Decl(file.tsx, 5, 14))
32+
>p : Symbol(p, Decl(file.tsx, 10, 14))
33+
>b : Symbol(Prop.b, Decl(file.tsx, 5, 14))
3234
>div : Symbol(JSX.IntrinsicElements.div, Decl(react.d.ts, 2400, 45))
3335
}
3436

3537
// OK
3638
let k = <Comp a={10} b="hi" children ="lol" />;
37-
>k : Symbol(k, Decl(file.tsx, 13, 3))
38-
>Comp : Symbol(Comp, Decl(file.tsx, 6, 1))
39-
>a : Symbol(a, Decl(file.tsx, 13, 13))
40-
>b : Symbol(b, Decl(file.tsx, 13, 20))
41-
>children : Symbol(children, Decl(file.tsx, 13, 27))
39+
>k : Symbol(k, Decl(file.tsx, 15, 3))
40+
>Comp : Symbol(Comp, Decl(file.tsx, 8, 1))
41+
>a : Symbol(a, Decl(file.tsx, 15, 13))
42+
>b : Symbol(b, Decl(file.tsx, 15, 20))
43+
>children : Symbol(children, Decl(file.tsx, 15, 27))
4244

4345
let k1 =
44-
>k1 : Symbol(k1, Decl(file.tsx, 14, 3))
46+
>k1 : Symbol(k1, Decl(file.tsx, 16, 3))
4547

4648
<Comp a={10} b="hi">
47-
>Comp : Symbol(Comp, Decl(file.tsx, 6, 1))
48-
>a : Symbol(a, Decl(file.tsx, 15, 9))
49-
>b : Symbol(b, Decl(file.tsx, 15, 16))
49+
>Comp : Symbol(Comp, Decl(file.tsx, 8, 1))
50+
>a : Symbol(a, Decl(file.tsx, 17, 9))
51+
>b : Symbol(b, Decl(file.tsx, 17, 16))
5052

5153
hi hi hi!
5254
</Comp>;
53-
>Comp : Symbol(Comp, Decl(file.tsx, 6, 1))
55+
>Comp : Symbol(Comp, Decl(file.tsx, 8, 1))
5456

5557
let k2 =
56-
>k2 : Symbol(k2, Decl(file.tsx, 18, 3))
58+
>k2 : Symbol(k2, Decl(file.tsx, 20, 3))
5759

5860
<Comp a={10} b="hi">
59-
>Comp : Symbol(Comp, Decl(file.tsx, 6, 1))
60-
>a : Symbol(a, Decl(file.tsx, 19, 9))
61-
>b : Symbol(b, Decl(file.tsx, 19, 16))
61+
>Comp : Symbol(Comp, Decl(file.tsx, 8, 1))
62+
>a : Symbol(a, Decl(file.tsx, 21, 9))
63+
>b : Symbol(b, Decl(file.tsx, 21, 16))
6264

6365
<div>hi hi hi!</div>
6466
>div : Symbol(JSX.IntrinsicElements.div, Decl(react.d.ts, 2400, 45))
6567
>div : Symbol(JSX.IntrinsicElements.div, Decl(react.d.ts, 2400, 45))
6668

6769
</Comp>;
68-
>Comp : Symbol(Comp, Decl(file.tsx, 6, 1))
70+
>Comp : Symbol(Comp, Decl(file.tsx, 8, 1))
6971

tests/baselines/reference/checkJsxChildrenProperty1.types

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
//// [tests/cases/conformance/jsx/checkJsxChildrenProperty1.tsx] ////
22

33
=== file.tsx ===
4+
/// <reference path="react.d.ts" />
5+
46
import React = require('react');
57
>React : typeof React
68
> : ^^^^^^^^^^^^

tests/baselines/reference/checkJsxChildrenProperty12.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
//// [tests/cases/conformance/jsx/checkJsxChildrenProperty12.tsx] ////
22

33
//// [file.tsx]
4+
/// <reference path="/.lib/react.d.ts" />
5+
46
import React = require('react');
57

68
interface ButtonProp {
@@ -36,6 +38,7 @@ class InnerButton extends React.Component<InnerButtonProp, any> {
3638

3739
//// [file.jsx]
3840
"use strict";
41+
/// <reference path="/.lib/react.d.ts" />
3942
var __extends = (this && this.__extends) || (function () {
4043
var extendStatics = function (d, b) {
4144
extendStatics = Object.setPrototypeOf ||

0 commit comments

Comments
 (0)