File: importStatementsInterfaces.js

package info (click to toggle)
node-typescript 3.3.3333-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 324,548 kB
  • sloc: makefile: 6; sh: 3
file content (64 lines) | stat: -rw-r--r-- 1,056 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
//// [importStatementsInterfaces.ts]
module A {
    export interface Point {
        x: number;
        y: number;
    }

    export module inA {
        export interface Point3D extends Point {
            z: number;
        }
    }
}

// no code gen expected
module B {
    import a = A;
}

// no code gen expected
module C {
    import a = A;
    import b = a.inA;
    var m: typeof a;
    var p: b.Point3D;
    var p = {x:0, y:0, z: 0 };
}

// no code gen expected
module D {
    import a = A;

    var p : a.Point;
}

// no code gen expected
module E {
    import a = A.inA;
    export function xDist(x: a.Point3D) {
        return 0 - x.x;
    }
}

//// [importStatementsInterfaces.js]
// no code gen expected
var C;
(function (C) {
    var m;
    var p;
    var p = { x: 0, y: 0, z: 0 };
})(C || (C = {}));
// no code gen expected
var D;
(function (D) {
    var p;
})(D || (D = {}));
// no code gen expected
var E;
(function (E) {
    function xDist(x) {
        return 0 - x.x;
    }
    E.xDist = xDist;
})(E || (E = {}));