File: typeArgumentsOnFunctionsWithNoTypeParameters.symbols

package info (click to toggle)
node-typescript 3.3.3333-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 324,548 kB
  • sloc: makefile: 6; sh: 3
file content (27 lines) | stat: -rw-r--r-- 1,401 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
=== tests/cases/compiler/typeArgumentsOnFunctionsWithNoTypeParameters.ts ===
function foo<T, U>(f: (v: T) => U) {
>foo : Symbol(foo, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 0))
>T : Symbol(T, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 13))
>U : Symbol(U, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 15))
>f : Symbol(f, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 19))
>v : Symbol(v, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 23))
>T : Symbol(T, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 13))
>U : Symbol(U, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 15))

   var r1 = f<number>(1);
>r1 : Symbol(r1, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 1, 6))
>f : Symbol(f, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 19))

   var r2 = f(1);
>r2 : Symbol(r2, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 2, 6))
>f : Symbol(f, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 19))

   var r3 = f<any>(null);
>r3 : Symbol(r3, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 3, 6))
>f : Symbol(f, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 19))

   var r4 = f(null);
>r4 : Symbol(r4, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 4, 6))
>f : Symbol(f, Decl(typeArgumentsOnFunctionsWithNoTypeParameters.ts, 0, 19))
}