6 lines
93 B
TypeScript
6 lines
93 B
TypeScript
|
interface Array<T> {
|
||
|
foo(): T;
|
||
|
}
|
||
|
|
||
|
var arr: string[] = [];
|
||
|
var x: number = arr.foo();
|