2015-02-12 22:23:49 +01:00
|
|
|
=== tests/cases/compiler/declarationEmitDestructuringOptionalBindingParametersInOverloads.ts ===
|
|
|
|
|
|
|
|
function foo([x, y, z] ?: [string, number, boolean]);
|
2015-04-16 01:44:20 +02:00
|
|
|
>foo : ([x, y, z]?: [string, number, boolean]) => any
|
|
|
|
>x : string
|
|
|
|
>y : number
|
|
|
|
>z : boolean
|
2015-02-12 22:23:49 +01:00
|
|
|
|
|
|
|
function foo(...rest: any[]) {
|
2015-04-16 01:44:20 +02:00
|
|
|
>foo : ([x, y, z]?: [string, number, boolean]) => any
|
|
|
|
>rest : any[]
|
2015-02-12 22:23:49 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
function foo2( { x, y, z }?: { x: string; y: number; z: boolean });
|
2015-04-16 01:44:20 +02:00
|
|
|
>foo2 : ({ x, y, z }?: { x: string; y: number; z: boolean; }) => any
|
|
|
|
>x : string
|
|
|
|
>y : number
|
|
|
|
>z : boolean
|
|
|
|
>x : string
|
|
|
|
>y : number
|
|
|
|
>z : boolean
|
2015-02-12 22:23:49 +01:00
|
|
|
|
|
|
|
function foo2(...rest: any[]) {
|
2015-04-16 01:44:20 +02:00
|
|
|
>foo2 : ({ x, y, z }?: { x: string; y: number; z: boolean; }) => any
|
|
|
|
>rest : any[]
|
2015-02-12 22:23:49 +01:00
|
|
|
|
|
|
|
}
|