Skip to content

Commit 17b790b

Browse files
Merge branch 'master' into transitiveExports
2 parents ab4d003 + 8bf61c7 commit 17b790b

File tree

2,196 files changed

+70084
-64976
lines changed

Some content is hidden

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

2,196 files changed

+70084
-64976
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ tests/services/baselines/local/*
2121
tests/baselines/prototyping/local/*
2222
tests/baselines/rwc/*
2323
tests/baselines/test262/*
24+
tests/baselines/local/projectOutput/*
2425
tests/services/baselines/prototyping/local/*
2526
tests/services/browser/typescriptServices.js
2627
scripts/processDiagnosticMessages.d.ts

Jakefile

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ var definitionsRoots = [
111111
"compiler/parser.d.ts",
112112
"compiler/checker.d.ts",
113113
"compiler/program.d.ts",
114+
"compiler/commandLineParser.d.ts",
114115
"services/services.d.ts",
115116
];
116117

@@ -222,15 +223,17 @@ function compileFile(outFile, sources, prereqs, prefixes, useBuiltCompiler, noOu
222223
var dir = useBuiltCompiler ? builtLocalDirectory : LKGDirectory;
223224
var options = "--module commonjs -noImplicitAny";
224225

225-
if (!keepComments) {
226-
options += " -removeComments";
226+
// Keep comments when specifically requested
227+
// or when in debug mode.
228+
if (!(keepComments || useDebugMode)) {
229+
options += " --removeComments";
227230
}
228231

229232
if (generateDeclarations) {
230233
options += " --declaration";
231234
}
232235

233-
if (useDebugMode || preserveConstEnums) {
236+
if (preserveConstEnums || useDebugMode) {
234237
options += " --preserveConstEnums";
235238
}
236239

@@ -254,8 +257,6 @@ function compileFile(outFile, sources, prereqs, prefixes, useBuiltCompiler, noOu
254257
options += " --stripInternal"
255258
}
256259

257-
options += " --cacheDownlevelForOfLength --preserveNewLines";
258-
259260
var cmd = host + " " + dir + compilerFilename + " " + options + " ";
260261
cmd = cmd + sources.join(" ");
261262
console.log(cmd + "\n");

bin/lib.core.d.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1170,3 +1170,17 @@ interface ArrayConstructor {
11701170
}
11711171

11721172
declare var Array: ArrayConstructor;
1173+
1174+
interface TypedPropertyDescriptor<T> {
1175+
enumerable?: boolean;
1176+
configurable?: boolean;
1177+
writable?: boolean;
1178+
value?: T;
1179+
get?: () => T;
1180+
set?: (value: T) => void;
1181+
}
1182+
1183+
declare type ClassDecorator = <TFunction extends Function>(target: TFunction) => TFunction | void;
1184+
declare type PropertyDecorator = (target: Object, propertyKey: string | symbol) => void;
1185+
declare type MethodDecorator = <T>(target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor<T>) => TypedPropertyDescriptor<T> | void;
1186+
declare type ParameterDecorator = (target: Function, propertyKey: string | symbol, parameterIndex: number) => void;

bin/lib.core.es6.d.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1170,6 +1170,20 @@ interface ArrayConstructor {
11701170
}
11711171

11721172
declare var Array: ArrayConstructor;
1173+
1174+
interface TypedPropertyDescriptor<T> {
1175+
enumerable?: boolean;
1176+
configurable?: boolean;
1177+
writable?: boolean;
1178+
value?: T;
1179+
get?: () => T;
1180+
set?: (value: T) => void;
1181+
}
1182+
1183+
declare type ClassDecorator = <TFunction extends Function>(target: TFunction) => TFunction | void;
1184+
declare type PropertyDecorator = (target: Object, propertyKey: string | symbol) => void;
1185+
declare type MethodDecorator = <T>(target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor<T>) => TypedPropertyDescriptor<T> | void;
1186+
declare type ParameterDecorator = (target: Function, propertyKey: string | symbol, parameterIndex: number) => void;
11731187
declare type PropertyKey = string | number | symbol;
11741188

11751189
interface Symbol {

bin/lib.d.ts

Lines changed: 168 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1171,6 +1171,20 @@ interface ArrayConstructor {
11711171

11721172
declare var Array: ArrayConstructor;
11731173

1174+
interface TypedPropertyDescriptor<T> {
1175+
enumerable?: boolean;
1176+
configurable?: boolean;
1177+
writable?: boolean;
1178+
value?: T;
1179+
get?: () => T;
1180+
set?: (value: T) => void;
1181+
}
1182+
1183+
declare type ClassDecorator = <TFunction extends Function>(target: TFunction) => TFunction | void;
1184+
declare type PropertyDecorator = (target: Object, propertyKey: string | symbol) => void;
1185+
declare type MethodDecorator = <T>(target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor<T>) => TypedPropertyDescriptor<T> | void;
1186+
declare type ParameterDecorator = (target: Function, propertyKey: string | symbol, parameterIndex: number) => void;
1187+
11741188
/////////////////////////////
11751189
/// IE10 ECMAScript Extensions
11761190
/////////////////////////////
@@ -14209,19 +14223,169 @@ declare function importScripts(...urls: string[]): void;
1420914223
/// Windows Script Host APIS
1421014224
/////////////////////////////
1421114225

14212-
declare var ActiveXObject: { new (s: string): any; };
14226+
14227+
interface ActiveXObject {
14228+
new (s: string): any;
14229+
}
14230+
declare var ActiveXObject: ActiveXObject;
1421314231

1421414232
interface ITextWriter {
1421514233
Write(s: string): void;
1421614234
WriteLine(s: string): void;
1421714235
Close(): void;
1421814236
}
1421914237

14238+
interface TextStreamBase {
14239+
/**
14240+
* The column number of the current character position in an input stream.
14241+
*/
14242+
Column: number;
14243+
/**
14244+
* The current line number in an input stream.
14245+
*/
14246+
Line: number;
14247+
/**
14248+
* Closes a text stream.
14249+
* It is not necessary to close standard streams; they close automatically when the process ends. If you close a standard stream, be aware that any other pointers to that standard stream become invalid.
14250+
*/
14251+
Close(): void;
14252+
}
14253+
14254+
interface TextStreamWriter extends TextStreamBase {
14255+
/**
14256+
* Sends a string to an output stream.
14257+
*/
14258+
Write(s: string): void;
14259+
/**
14260+
* Sends a specified number of blank lines (newline characters) to an output stream.
14261+
*/
14262+
WriteBlankLines(intLines: number): void;
14263+
/**
14264+
* Sends a string followed by a newline character to an output stream.
14265+
*/
14266+
WriteLine(s: string): void;
14267+
}
14268+
14269+
interface TextStreamReader extends TextStreamBase {
14270+
/**
14271+
* Returns a specified number of characters from an input stream, beginning at the current pointer position.
14272+
* Does not return until the ENTER key is pressed.
14273+
* Can only be used on a stream in reading mode; causes an error in writing or appending mode.
14274+
*/
14275+
Read(characters: number): string;
14276+
/**
14277+
* Returns all characters from an input stream.
14278+
* Can only be used on a stream in reading mode; causes an error in writing or appending mode.
14279+
*/
14280+
ReadAll(): string;
14281+
/**
14282+
* Returns an entire line from an input stream.
14283+
* Although this method extracts the newline character, it does not add it to the returned string.
14284+
* Can only be used on a stream in reading mode; causes an error in writing or appending mode.
14285+
*/
14286+
ReadLine(): string;
14287+
/**
14288+
* Skips a specified number of characters when reading from an input text stream.
14289+
* Can only be used on a stream in reading mode; causes an error in writing or appending mode.
14290+
* @param characters Positive number of characters to skip forward. (Backward skipping is not supported.)
14291+
*/
14292+
Skip(characters: number): void;
14293+
/**
14294+
* Skips the next line when reading from an input text stream.
14295+
* Can only be used on a stream in reading mode, not writing or appending mode.
14296+
*/
14297+
SkipLine(): void;
14298+
/**
14299+
* Indicates whether the stream pointer position is at the end of a line.
14300+
*/
14301+
AtEndOfLine: boolean;
14302+
/**
14303+
* Indicates whether the stream pointer position is at the end of a stream.
14304+
*/
14305+
AtEndOfStream: boolean;
14306+
}
14307+
1422014308
declare var WScript: {
14309+
/**
14310+
* Outputs text to either a message box (under WScript.exe) or the command console window followed by a newline (under CScript.ext).
14311+
*/
1422114312
Echo(s: any): void;
14222-
StdErr: ITextWriter;
14223-
StdOut: ITextWriter;
14313+
/**
14314+
* Exposes the write-only error output stream for the current script.
14315+
* Can be accessed only while using CScript.exe.
14316+
*/
14317+
StdErr: TextStreamWriter;
14318+
/**
14319+
* Exposes the write-only output stream for the current script.
14320+
* Can be accessed only while using CScript.exe.
14321+
*/
14322+
StdOut: TextStreamWriter;
1422414323
Arguments: { length: number; Item(n: number): string; };
14324+
/**
14325+
* The full path of the currently running script.
14326+
*/
1422514327
ScriptFullName: string;
14328+
/**
14329+
* Forces the script to stop immediately, with an optional exit code.
14330+
*/
1422614331
Quit(exitCode?: number): number;
14227-
}
14332+
/**
14333+
* The Windows Script Host build version number.
14334+
*/
14335+
BuildVersion: number;
14336+
/**
14337+
* Fully qualified path of the host executable.
14338+
*/
14339+
FullName: string;
14340+
/**
14341+
* Gets/sets the script mode - interactive(true) or batch(false).
14342+
*/
14343+
Interactive: boolean;
14344+
/**
14345+
* The name of the host executable (WScript.exe or CScript.exe).
14346+
*/
14347+
Name: string;
14348+
/**
14349+
* Path of the directory containing the host executable.
14350+
*/
14351+
Path: string;
14352+
/**
14353+
* The filename of the currently running script.
14354+
*/
14355+
ScriptName: string;
14356+
/**
14357+
* Exposes the read-only input stream for the current script.
14358+
* Can be accessed only while using CScript.exe.
14359+
*/
14360+
StdIn: TextStreamReader;
14361+
/**
14362+
* Windows Script Host version
14363+
*/
14364+
Version: string;
14365+
/**
14366+
* Connects a COM object's event sources to functions named with a given prefix, in the form prefix_event.
14367+
*/
14368+
ConnectObject(objEventSource: any, strPrefix: string): void;
14369+
/**
14370+
* Creates a COM object.
14371+
* @param strProgiID
14372+
* @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.
14373+
*/
14374+
CreateObject(strProgID: string, strPrefix?: string): any;
14375+
/**
14376+
* Disconnects a COM object from its event sources.
14377+
*/
14378+
DisconnectObject(obj: any): void;
14379+
/**
14380+
* Retrieves an existing object with the specified ProgID from memory, or creates a new one from a file.
14381+
* @param strPathname Fully qualified path to the file containing the object persisted to disk. For objects in memory, pass a zero-length string.
14382+
* @param strProgID
14383+
* @param strPrefix Function names in the form prefix_event will be bound to this object's COM events.
14384+
*/
14385+
GetObject(strPathname: string, strProgID?: string, strPrefix?: string): any;
14386+
/**
14387+
* Suspends script execution for a specified length of time, then continues execution.
14388+
* @param intTime Interval (in milliseconds) to suspend script execution.
14389+
*/
14390+
Sleep(intTime: number): void;
14391+
};

0 commit comments

Comments
 (0)