68 lines
2.2 KiB
Text
68 lines
2.2 KiB
Text
=== tests/cases/conformance/es6/templates/taggedTemplateStringsWithOverloadResolution2.ts ===
|
|
|
|
function foo1(strs: TemplateStringsArray, x: number): string;
|
|
>foo1 : { (strs: TemplateStringsArray, x: number): string; (strs: string[], x: number): number; }
|
|
>strs : TemplateStringsArray
|
|
>TemplateStringsArray : TemplateStringsArray
|
|
>x : number
|
|
|
|
function foo1(strs: string[], x: number): number;
|
|
>foo1 : { (strs: TemplateStringsArray, x: number): string; (strs: string[], x: number): number; }
|
|
>strs : string[]
|
|
>x : number
|
|
|
|
function foo1(...stuff: any[]): any {
|
|
>foo1 : { (strs: TemplateStringsArray, x: number): string; (strs: string[], x: number): number; }
|
|
>stuff : any[]
|
|
|
|
return undefined;
|
|
>undefined : undefined
|
|
}
|
|
|
|
var a = foo1 `${1}`; // string
|
|
>a : string
|
|
>foo1 `${1}` : string
|
|
>foo1 : { (strs: TemplateStringsArray, x: number): string; (strs: string[], x: number): number; }
|
|
>`${1}` : string
|
|
>1 : number
|
|
|
|
var b = foo1([], 1); // number
|
|
>b : number
|
|
>foo1([], 1) : number
|
|
>foo1 : { (strs: TemplateStringsArray, x: number): string; (strs: string[], x: number): number; }
|
|
>[] : undefined[]
|
|
>1 : number
|
|
|
|
function foo2(strs: string[], x: number): number;
|
|
>foo2 : { (strs: string[], x: number): number; (strs: TemplateStringsArray, x: number): string; }
|
|
>strs : string[]
|
|
>x : number
|
|
|
|
function foo2(strs: TemplateStringsArray, x: number): string;
|
|
>foo2 : { (strs: string[], x: number): number; (strs: TemplateStringsArray, x: number): string; }
|
|
>strs : TemplateStringsArray
|
|
>TemplateStringsArray : TemplateStringsArray
|
|
>x : number
|
|
|
|
function foo2(...stuff: any[]): any {
|
|
>foo2 : { (strs: string[], x: number): number; (strs: TemplateStringsArray, x: number): string; }
|
|
>stuff : any[]
|
|
|
|
return undefined;
|
|
>undefined : undefined
|
|
}
|
|
|
|
var c = foo2 `${1}`; // number
|
|
>c : number
|
|
>foo2 `${1}` : number
|
|
>foo2 : { (strs: string[], x: number): number; (strs: TemplateStringsArray, x: number): string; }
|
|
>`${1}` : string
|
|
>1 : number
|
|
|
|
var d = foo2([], 1); // number
|
|
>d : number
|
|
>foo2([], 1) : number
|
|
>foo2 : { (strs: string[], x: number): number; (strs: TemplateStringsArray, x: number): string; }
|
|
>[] : undefined[]
|
|
>1 : number
|
|
|