TypeScript/tests/baselines/reference/arrayConcat2.types

33 lines
1.1 KiB
Plaintext
Raw Normal View History

2014-08-15 23:33:16 +02:00
=== tests/cases/compiler/arrayConcat2.ts ===
var a: string[] = [];
>a : string[]
2014-10-13 15:56:58 +02:00
>[] : undefined[]
2014-08-15 23:33:16 +02:00
a.concat("hello", 'world');
>a.concat("hello", 'world') : string[]
>a.concat : { <U extends string[]>(...items: U[]): string[]; (...items: string[]): string[]; }
>a : string[]
>concat : { <U extends string[]>(...items: U[]): string[]; (...items: string[]): string[]; }
2015-04-13 21:36:11 +02:00
>"hello" : string
>'world' : string
2014-08-15 23:33:16 +02:00
a.concat('Hello');
>a.concat('Hello') : string[]
>a.concat : { <U extends string[]>(...items: U[]): string[]; (...items: string[]): string[]; }
>a : string[]
>concat : { <U extends string[]>(...items: U[]): string[]; (...items: string[]): string[]; }
2015-04-13 21:36:11 +02:00
>'Hello' : string
2014-08-15 23:33:16 +02:00
var b = new Array<string>();
>b : string[]
2014-08-15 23:33:16 +02:00
>new Array<string>() : string[]
>Array : ArrayConstructor
2014-08-15 23:33:16 +02:00
b.concat('hello');
>b.concat('hello') : string[]
>b.concat : { <U extends string[]>(...items: U[]): string[]; (...items: string[]): string[]; }
>b : string[]
>concat : { <U extends string[]>(...items: U[]): string[]; (...items: string[]): string[]; }
2015-04-13 21:36:11 +02:00
>'hello' : string
2014-08-15 23:33:16 +02:00