11 lines
270 B
TypeScript
11 lines
270 B
TypeScript
//// [functionOverloads32.ts]
|
|
function foo(bar:string):string;
|
|
function foo(bar:number):number;
|
|
function foo(bar:any):any{ return bar }
|
|
var baz:number; var x = foo(baz);
|
|
|
|
|
|
//// [functionOverloads32.js]
|
|
function foo(bar) { return bar; }
|
|
var baz;
|
|
var x = foo(baz);
|