Skip to content

Commit 25be912

Browse files
committed
Merge branch 'master' into ownJsonParsing
2 parents 0b3074f + 79bf477 commit 25be912

File tree

258 files changed

+5509
-4858
lines changed

Some content is hidden

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

258 files changed

+5509
-4858
lines changed

Jakefile.js

+6-8
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ var harnessSources = harnessCoreSources.concat([
258258
"commandLineParsing.ts",
259259
"configurationExtension.ts",
260260
"convertCompilerOptionsFromJson.ts",
261-
"convertTypingOptionsFromJson.ts",
261+
"convertTypeAcquisitionFromJson.ts",
262262
"tsserverProjectSystem.ts",
263263
"compileOnSave.ts",
264264
"typingsInstaller.ts",
@@ -932,7 +932,7 @@ function runConsoleTests(defaultReporter, runInParallel) {
932932
}
933933

934934
if (tests && tests.toLocaleLowerCase() === "rwc") {
935-
testTimeout = 400000;
935+
testTimeout = 800000;
936936
}
937937

938938
colors = process.env.colors || process.env.color;
@@ -1088,12 +1088,10 @@ task("tests-debug", ["setDebugMode", "tests"]);
10881088
// Makes the test results the new baseline
10891089
desc("Makes the most recent test results the new baseline, overwriting the old baseline");
10901090
task("baseline-accept", function () {
1091-
acceptBaseline("");
1091+
acceptBaseline(localBaseline, refBaseline);
10921092
});
10931093

1094-
function acceptBaseline(containerFolder) {
1095-
var sourceFolder = path.join(localBaseline, containerFolder);
1096-
var targetFolder = path.join(refBaseline, containerFolder);
1094+
function acceptBaseline(sourceFolder, targetFolder) {
10971095
console.log('Accept baselines from ' + sourceFolder + ' to ' + targetFolder);
10981096
var files = fs.readdirSync(sourceFolder);
10991097
var deleteEnding = '.delete';
@@ -1117,12 +1115,12 @@ function acceptBaseline(containerFolder) {
11171115

11181116
desc("Makes the most recent rwc test results the new baseline, overwriting the old baseline");
11191117
task("baseline-accept-rwc", function () {
1120-
acceptBaseline("rwc");
1118+
acceptBaseline(localRwcBaseline, refRwcBaseline);
11211119
});
11221120

11231121
desc("Makes the most recent test262 test results the new baseline, overwriting the old baseline");
11241122
task("baseline-accept-test262", function () {
1125-
acceptBaseline("test262");
1123+
acceptBaseline(localTest262Baseline, refTest262Baseline);
11261124
});
11271125

11281126

scripts/parallel-lint.js

+12-8
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,29 @@
1-
var Linter = require("tslint");
1+
var tslint = require("tslint");
22
var fs = require("fs");
33

44
function getLinterOptions() {
55
return {
6-
configuration: require("../tslint.json"),
76
formatter: "prose",
87
formattersDirectory: undefined,
98
rulesDirectory: "built/local/tslint"
109
};
1110
}
11+
function getLinterConfiguration() {
12+
return require("../tslint.json");
13+
}
1214

13-
function lintFileContents(options, path, contents) {
14-
var ll = new Linter(path, contents, options);
15-
return ll.lint();
15+
function lintFileContents(options, configuration, path, contents) {
16+
var ll = new tslint.Linter(options);
17+
ll.lint(path, contents, configuration);
18+
return ll.getResult();
1619
}
1720

18-
function lintFileAsync(options, path, cb) {
21+
function lintFileAsync(options, configuration, path, cb) {
1922
fs.readFile(path, "utf8", function (err, contents) {
2023
if (err) {
2124
return cb(err);
2225
}
23-
var result = lintFileContents(options, path, contents);
26+
var result = lintFileContents(options, configuration, path, contents);
2427
cb(undefined, result);
2528
});
2629
}
@@ -30,7 +33,8 @@ process.on("message", function (data) {
3033
case "file":
3134
var target = data.name;
3235
var lintOptions = getLinterOptions();
33-
lintFileAsync(lintOptions, target, function (err, result) {
36+
var lintConfiguration = getLinterConfiguration();
37+
lintFileAsync(lintOptions, lintConfiguration, target, function (err, result) {
3438
if (err) {
3539
process.send({ kind: "error", error: err.toString() });
3640
return;

scripts/tslint/booleanTriviaRule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Lint from "tslint/lib/lint";
1+
import * as Lint from "tslint/lib";
22
import * as ts from "typescript";
33

44
export class Rule extends Lint.Rules.AbstractRule {

scripts/tslint/nextLineRule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Lint from "tslint/lib/lint";
1+
import * as Lint from "tslint/lib";
22
import * as ts from "typescript";
33

44
const OPTION_CATCH = "check-catch";

scripts/tslint/noInOperatorRule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Lint from "tslint/lib/lint";
1+
import * as Lint from "tslint/lib";
22
import * as ts from "typescript";
33

44

scripts/tslint/noIncrementDecrementRule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Lint from "tslint/lib/lint";
1+
import * as Lint from "tslint/lib";
22
import * as ts from "typescript";
33

44

scripts/tslint/noTypeAssertionWhitespaceRule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Lint from "tslint/lib/lint";
1+
import * as Lint from "tslint/lib";
22
import * as ts from "typescript";
33

44

scripts/tslint/objectLiteralSurroundingSpaceRule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Lint from "tslint/lib/lint";
1+
import * as Lint from "tslint/lib";
22
import * as ts from "typescript";
33

44

scripts/tslint/preferConstRule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Lint from "tslint/lib/lint";
1+
import * as Lint from "tslint/lib";
22
import * as ts from "typescript";
33

44
export class Rule extends Lint.Rules.AbstractRule {

scripts/tslint/typeOperatorSpacingRule.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Lint from "tslint/lib/lint";
1+
import * as Lint from "tslint/lib";
22
import * as ts from "typescript";
33

44

src/compiler/binder.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -599,8 +599,8 @@ namespace ts {
599599
// Binding of JsDocComment should be done before the current block scope container changes.
600600
// because the scope of JsDocComment should not be affected by whether the current node is a
601601
// container or not.
602-
if (isInJavaScriptFile(node) && node.jsDocComments) {
603-
forEach(node.jsDocComments, bind);
602+
if (isInJavaScriptFile(node) && node.jsDoc) {
603+
forEach(node.jsDoc, bind);
604604
}
605605
if (checkUnreachable(node)) {
606606
bindEachChild(node);

0 commit comments

Comments
 (0)