38 lines
1.7 KiB
Text
38 lines
1.7 KiB
Text
=== tests/cases/conformance/es6/yieldExpressions/generatorTypeCheck46.ts ===
|
|
declare function foo<T, U>(x: T, fun: () => Iterable<(x: T) => U>, fun2: (y: U) => T): T;
|
|
>foo : Symbol(foo, Decl(generatorTypeCheck46.ts, 0, 0))
|
|
>T : Symbol(T, Decl(generatorTypeCheck46.ts, 0, 21))
|
|
>U : Symbol(U, Decl(generatorTypeCheck46.ts, 0, 23))
|
|
>x : Symbol(x, Decl(generatorTypeCheck46.ts, 0, 27))
|
|
>T : Symbol(T, Decl(generatorTypeCheck46.ts, 0, 21))
|
|
>fun : Symbol(fun, Decl(generatorTypeCheck46.ts, 0, 32))
|
|
>Iterable : Symbol(Iterable, Decl(lib.d.ts, 1668, 1))
|
|
>x : Symbol(x, Decl(generatorTypeCheck46.ts, 0, 54))
|
|
>T : Symbol(T, Decl(generatorTypeCheck46.ts, 0, 21))
|
|
>U : Symbol(U, Decl(generatorTypeCheck46.ts, 0, 23))
|
|
>fun2 : Symbol(fun2, Decl(generatorTypeCheck46.ts, 0, 66))
|
|
>y : Symbol(y, Decl(generatorTypeCheck46.ts, 0, 74))
|
|
>U : Symbol(U, Decl(generatorTypeCheck46.ts, 0, 23))
|
|
>T : Symbol(T, Decl(generatorTypeCheck46.ts, 0, 21))
|
|
>T : Symbol(T, Decl(generatorTypeCheck46.ts, 0, 21))
|
|
|
|
foo("", function* () {
|
|
>foo : Symbol(foo, Decl(generatorTypeCheck46.ts, 0, 0))
|
|
|
|
yield* {
|
|
*[Symbol.iterator]() {
|
|
>Symbol.iterator : Symbol(SymbolConstructor.iterator, Decl(lib.d.ts, 1236, 31))
|
|
>Symbol : Symbol(Symbol, Decl(lib.d.ts, 1186, 52), Decl(lib.d.ts, 1292, 11))
|
|
>iterator : Symbol(SymbolConstructor.iterator, Decl(lib.d.ts, 1236, 31))
|
|
|
|
yield x => x.length
|
|
>x : Symbol(x, Decl(generatorTypeCheck46.ts, 5, 17))
|
|
>x.length : Symbol(String.length, Decl(lib.d.ts, 414, 19))
|
|
>x : Symbol(x, Decl(generatorTypeCheck46.ts, 5, 17))
|
|
>length : Symbol(String.length, Decl(lib.d.ts, 414, 19))
|
|
}
|
|
}
|
|
}, p => undefined); // T is fixed, should be string
|
|
>p : Symbol(p, Decl(generatorTypeCheck46.ts, 8, 2))
|
|
>undefined : Symbol(undefined)
|
|
|