8000 Migrate _everything_ to modules · microsoft/TypeScript@802f955 · GitHub
[go: up one dir, main page]

Skip to content

Commit 802f955

Browse files
committed
Migrate _everything_ to modules
1 parent ff04220 commit 802f955

File tree

466 files changed

+198509
-228003
lines changed
  • services
  • shims
  • testRunner
  • Some content is hidden

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

    466 files changed

    +198509
    -228003
    lines changed

    src/cancellationToken/cancellationToken.ts

    Lines changed: 1 addition & 5 deletions
    Original file line numberDiff line numberDiff line change
    @@ -1,13 +1,10 @@
    11
    /// <reference types="node"/>
    2-
    32
    import fs = require("fs");
    4-
    53
    interface ServerCancellationToken {
    64
    isCancellationRequested(): boolean;
    75
    setRequest(requestId: number): void;
    86
    resetRequest(requestId: number): void;
    97
    }
    10-
    118
    function pipeExists(name: string): boolean {
    129
    // Unlike statSync, existsSync doesn't throw an exception if the target doesn't exist.
    1310
    // A comment in the node code suggests they're stuck with that decision for back compat
    @@ -18,7 +15,6 @@ function pipeExists(name: string): boolean {
    1815
    // implementation returned false from its catch block.
    1916
    return fs.existsSync(name);
    2017
    }
    21-
    2218
    function createCancellationToken(args: string[]): ServerCancellationToken {
    2319
    let cancellationPipeName: string | undefined;
    2420
    for (let i = 0; i < args.length - 1; i++) {
    @@ -62,7 +58,7 @@ function createCancellationToken(args: string[]): ServerCancellationToken {
    6258
    }
    6359
    else {
    6460
    return {
    65-
    isCancellationRequested: () => pipeExists(cancellationPipeName!), // TODO: GH#18217
    61+
    isCancellationRequested: () => pipeExists(cancellationPipeName!),
    6662
    setRequest: (_requestId: number): void => void 0,
    6763
    resetRequest: (_requestId: number): void => void 0
    6864
    };

    src/compiler/binder.ts

    Lines changed: 3682 additions & 4096 deletions
    Large diffs are not rendered by default.

    src/compiler/builder.ts

    Lines changed: 1002 additions & 1108 deletions
    Large diffs are not rendered by default.

    src/compiler/builderPublic.ts

    Lines changed: 155 additions & 161 deletions
    Large diffs are not rendered by default.

    src/compiler/builderState.ts

    Lines changed: 455 additions & 511 deletions
    Large diffs are not rendered by default.

    src/compiler/builderStatePublic.ts

    Lines changed: 11 additions & 13 deletions
    Original file line numberDiff line numberDiff line change
    @@ -1,13 +1,11 @@
    1-
    namespace ts {
    2-
    export interface EmitOutput {
    3-
    outputFiles: OutputFile[];
    4-
    emitSkipped: boolean;
    5-
    /* @internal */ exportedModulesFromDeclarationEmit?: ExportedModulesFromDeclarationEmit;
    6-
    }
    7-
    8-
    export interface OutputFile {
    9-
    name: string;
    10-
    writeByteOrderMark: boolean;
    11-
    text: string;
    12-
    }
    13-
    }
    1+
    import { ExportedModulesFromDeclarationEmit } from "./ts";
    2+
    export interface EmitOutput {
    3+
    outputFiles: OutputFile[];
    4+
    emitSkipped: boolean;
    5+
    /* @internal */ exportedModulesFromDeclarationEmit?: ExportedModulesFromDeclarationEmit;
    6+
    }
    7+
    export interface OutputFile {
    8+
    name: string;
    9+
    writeByteOrderMark: boolean;
    10+
    text: string;
    11+
    }

    src/compiler/checker.ts

    Lines changed: 31343 additions & 34894 deletions
    Large diffs are not rendered by default.

    src/compiler/commandLineParser.ts

    Lines changed: 2703 additions & 3040 deletions
    Large diffs are not rendered by default.

    0 commit comments

    Comments
     (0)
    0