File: commentsInterface.types

package info (click to toggle)
node-typescript 2.1.5-1
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 203,952 kB
  • ctags: 52,987
  • sloc: sh: 11; makefile: 5
file content (274 lines) | stat: -rw-r--r-- 5,401 bytes parent folder | download | duplicates (2)
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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
=== tests/cases/compiler/commentsInterface.ts ===
/** this is interface 1*/
interface i1 {
>i1 : i1
}
var i1_i: i1;
>i1_i : i1
>i1 : i1

interface nc_i1 {
>nc_i1 : nc_i1
}
var nc_i1_i: nc_i1;
>nc_i1_i : nc_i1
>nc_i1 : nc_i1

/** this is interface 2 with memebers*/
interface i2 {
>i2 : i2

    /** this is x*/
    x: number;
>x : number

    /** this is foo*/
    foo: (/**param help*/b: number) => string;
>foo : (b: number) => string
>b : number

    /** this is indexer*/
    [/**string param*/i: string]: any;
>i : string

    /**new method*/
    new (/** param*/i: i1);
>i : i1
>i1 : i1

    nc_x: number;
>nc_x : number

    nc_foo: (b: number) => string;
>nc_foo : (b: number) => string
>b : number

    [i: number]: number;
>i : number

    /** this is call signature*/
    (/**paramhelp a*/a: number,/**paramhelp b*/ b: number) : number;
>a : number
>b : number

    /** this is fnfoo*/
    fnfoo(/**param help*/b: number): string;
>fnfoo : (b: number) => string
>b : number

    nc_fnfoo(b: number): string;
>nc_fnfoo : (b: number) => string
>b : number

    // nc_y
    nc_y: number;
>nc_y : number
}
var i2_i: i2;
>i2_i : i2
>i2 : i2

var i2_i_x = i2_i.x;
>i2_i_x : number
>i2_i.x : number
>i2_i : i2
>x : number

var i2_i_foo = i2_i.foo;
>i2_i_foo : (b: number) => string
>i2_i.foo : (b: number) => string
>i2_i : i2
>foo : (b: number) => string

var i2_i_foo_r = i2_i.foo(30);
>i2_i_foo_r : string
>i2_i.foo(30) : string
>i2_i.foo : (b: number) => string
>i2_i : i2
>foo : (b: number) => string
>30 : 30

var i2_i_i2_si = i2_i["hello"];
>i2_i_i2_si : any
>i2_i["hello"] : any
>i2_i : i2
>"hello" : "hello"

var i2_i_i2_ii = i2_i[30];
>i2_i_i2_ii : number
>i2_i[30] : number
>i2_i : i2
>30 : 30

var i2_i_n = new i2_i(i1_i);
>i2_i_n : any
>new i2_i(i1_i) : any
>i2_i : i2
>i1_i : i1

var i2_i_nc_x = i2_i.nc_x;
>i2_i_nc_x : number
>i2_i.nc_x : number
>i2_i : i2
>nc_x : number

var i2_i_nc_foo = i2_i.nc_foo;
>i2_i_nc_foo : (b: number) => string
>i2_i.nc_foo : (b: number) => string
>i2_i : i2
>nc_foo : (b: number) => string

var i2_i_nc_foo_r = i2_i.nc_foo(30);
>i2_i_nc_foo_r : string
>i2_i.nc_foo(30) : string
>i2_i.nc_foo : (b: number) => string
>i2_i : i2
>nc_foo : (b: number) => string
>30 : 30

var i2_i_r = i2_i(10, 20);
>i2_i_r : number
>i2_i(10, 20) : number
>i2_i : i2
>10 : 10
>20 : 20

var i2_i_fnfoo = i2_i.fnfoo;
>i2_i_fnfoo : (b: number) => string
>i2_i.fnfoo : (b: number) => string
>i2_i : i2
>fnfoo : (b: number) => string

var i2_i_fnfoo_r = i2_i.fnfoo(10);
>i2_i_fnfoo_r : string
>i2_i.fnfoo(10) : string
>i2_i.fnfoo : (b: number) => string
>i2_i : i2
>fnfoo : (b: number) => string
>10 : 10

var i2_i_nc_fnfoo = i2_i.nc_fnfoo;
>i2_i_nc_fnfoo : (b: number) => string
>i2_i.nc_fnfoo : (b: number) => string
>i2_i : i2
>nc_fnfoo : (b: number) => string

var i2_i_nc_fnfoo_r = i2_i.nc_fnfoo(10);
>i2_i_nc_fnfoo_r : string
>i2_i.nc_fnfoo(10) : string
>i2_i.nc_fnfoo : (b: number) => string
>i2_i : i2
>nc_fnfoo : (b: number) => string
>10 : 10

interface i3 {
>i3 : i3

    /** Comment i3 x*/
    x: number;
>x : number

    /** Function i3 f*/
    f(/**number parameter*/a: number): string;
>f : (a: number) => string
>a : number

    /** i3 l*/
    l: (/**comment i3 l b*/b: number) => string;
>l : (b: number) => string
>b : number

    nc_x: number;
>nc_x : number

    nc_f(a: number): string;
>nc_f : (a: number) => string
>a : number

    nc_l: (b: number) => string;
>nc_l : (b: number) => string
>b : number
}
var i3_i: i3;
>i3_i : i3
>i3 : i3

i3_i = {
>i3_i = {    f: /**own f*/ (/**i3_i a*/a: number) => "Hello" + a,    l: this.f,    /** own x*/    x: this.f(10),    nc_x: this.l(this.x),    nc_f: this.f,    nc_l: this.l} : { f: (a: number) => string; l: any; x: any; nc_x: any; nc_f: any; nc_l: any; }
>i3_i : i3
>{    f: /**own f*/ (/**i3_i a*/a: number) => "Hello" + a,    l: this.f,    /** own x*/    x: this.f(10),    nc_x: this.l(this.x),    nc_f: this.f,    nc_l: this.l} : { f: (a: number) => string; l: any; x: any; nc_x: any; nc_f: any; nc_l: any; }

    f: /**own f*/ (/**i3_i a*/a: number) => "Hello" + a,
>f : (a: number) => string
>(/**i3_i a*/a: number) => "Hello" + a : (a: number) => string
>a : number
>"Hello" + a : string
>"Hello" : "Hello"
>a : number

    l: this.f,
>l : any
>this.f : any
>this : any
>f : any

    /** own x*/
    x: this.f(10),
>x : any
>this.f(10) : any
>this.f : any
>this : any
>f : any
>10 : 10

    nc_x: this.l(this.x),
>nc_x : any
>this.l(this.x) : any
>this.l : any
>this : any
>l : any
>this.x : any
>this : any
>x : any

    nc_f: this.f,
>nc_f : any
>this.f : any
>this : any
>f : any

    nc_l: this.l
>nc_l : any
>this.l : any
>this : any
>l : any

};
i3_i.f(10);
>i3_i.f(10) : string
>i3_i.f : (a: number) => string
>i3_i : i3
>f : (a: number) => string
>10 : 10

i3_i.l(10);
>i3_i.l(10) : string
>i3_i.l : (b: number) => string
>i3_i : i3
>l : (b: number) => string
>10 : 10

i3_i.nc_f(10);
>i3_i.nc_f(10) : string
>i3_i.nc_f : (a: number) => string
>i3_i : i3
>nc_f : (a: number) => string
>10 : 10

i3_i.nc_l(10);
>i3_i.nc_l(10) : string
>i3_i.nc_l : (b: number) => string
>i3_i : i3
>nc_l : (b: number) => string
>10 : 10