|
| 1 | +=== tests/cases/compiler/baseTypeWrappingInstantiationChain.ts === |
| 2 | +class C<T1> extends CBase<T1> { |
| 3 | +>C : Symbol(C, Decl(baseTypeWrappingInstantiationChain.ts, 0, 0)) |
| 4 | +>T1 : Symbol(T1, Decl(baseTypeWrappingInstantiationChain.ts, 0, 8)) |
| 5 | +>CBase : Symbol(CBase, Decl(baseTypeWrappingInstantiationChain.ts, 9, 1)) |
| 6 | +>T1 : Symbol(T1, Decl(baseTypeWrappingInstantiationChain.ts, 0, 8)) |
| 7 | + |
| 8 | + public works() { |
| 9 | +>works : Symbol(works, Decl(baseTypeWrappingInstantiationChain.ts, 0, 31)) |
| 10 | + |
| 11 | + new CBaseBase<Wrapper<T1>>(this); |
| 12 | +>CBaseBase : Symbol(CBaseBase, Decl(baseTypeWrappingInstantiationChain.ts, 13, 1)) |
| 13 | +>Wrapper : Symbol(Wrapper, Decl(baseTypeWrappingInstantiationChain.ts, 21, 1)) |
| 14 | +>T1 : Symbol(T1, Decl(baseTypeWrappingInstantiationChain.ts, 0, 8)) |
| 15 | +>this : Symbol(C, Decl(baseTypeWrappingInstantiationChain.ts, 0, 0)) |
| 16 | + } |
| 17 | + public alsoWorks() { |
| 18 | +>alsoWorks : Symbol(alsoWorks, Decl(baseTypeWrappingInstantiationChain.ts, 3, 5)) |
| 19 | + |
| 20 | + new CBase<T1>(this); // Should not error, parameter is of type Parameter<Wrapper<T1>> |
| 21 | +>CBase : Symbol(CBase, Decl(baseTypeWrappingInstantiationChain.ts, 9, 1)) |
| 22 | +>T1 : Symbol(T1, Decl(baseTypeWrappingInstantiationChain.ts, 0, 8)) |
| 23 | +>this : Symbol(C, Decl(baseTypeWrappingInstantiationChain.ts, 0, 0)) |
| 24 | + } |
| 25 | + |
| 26 | + public method(t: Wrapper<T1>) { } |
| 27 | +>method : Symbol(method, Decl(baseTypeWrappingInstantiationChain.ts, 6, 5)) |
| 28 | +>t : Symbol(t, Decl(baseTypeWrappingInstantiationChain.ts, 8, 18)) |
| 29 | +>Wrapper : Symbol(Wrapper, Decl(baseTypeWrappingInstantiationChain.ts, 21, 1)) |
| 30 | +>T1 : Symbol(T1, Decl(baseTypeWrappingInstantiationChain.ts, 0, 8)) |
| 31 | +} |
| 32 | + |
| 33 | +class CBase<T2> extends CBaseBase<Wrapper<T2>> { |
| 34 | +>CBase : Symbol(CBase, Decl(baseTypeWrappingInstantiationChain.ts, 9, 1)) |
| 35 | +>T2 : Symbol(T2, Decl(baseTypeWrappingInstantiationChain.ts, 11, 12)) |
| 36 | +>CBaseBase : Symbol(CBaseBase, Decl(baseTypeWrappingInstantiationChain.ts, 13, 1)) |
| 37 | +>Wrapper : Symbol(Wrapper, Decl(baseTypeWrappingInstantiationChain.ts, 21, 1)) |
| 38 | +>T2 : Symbol(T2, Decl(baseTypeWrappingInstantiationChain.ts, 11, 12)) |
| 39 | + |
| 40 | +} |
| 41 | + |
| 42 | +class CBaseBase<T3> { |
| 43 | +>CBaseBase : Symbol(CBaseBase, Decl(baseTypeWrappingInstantiationChain.ts, 13, 1)) |
| 44 | +>T3 : Symbol(T3, Decl(baseTypeWrappingInstantiationChain.ts, 15, 16)) |
| 45 | + |
| 46 | + constructor(x: Parameter<T3>) { } |
| 47 | +>x : Symbol(x, Decl(baseTypeWrappingInstantiationChain.ts, 16, 16)) |
| 48 | +>Parameter : Symbol(Parameter, Decl(baseTypeWrappingInstantiationChain.ts, 17, 1)) |
| 49 | +>T3 : Symbol(T3, Decl(baseTypeWrappingInstantiationChain.ts, 15, 16)) |
| 50 | +} |
| 51 | + |
| 52 | +class Parameter<T4> { |
| 53 | +>Parameter : Symbol(Parameter, Decl(baseTypeWrappingInstantiationChain.ts, 17, 1)) |
| 54 | +>T4 : Symbol(T4, Decl(baseTypeWrappingInstantiationChain.ts, 19, 16)) |
| 55 | + |
| 56 | + method(t: T4) { } |
| 57 | +>method : Symbol(method, Decl(baseTypeWrappingInstantiationChain.ts, 19, 21)) |
| 58 | +>t : Symbol(t, Decl(baseTypeWrappingInstantiationChain.ts, 20, 11)) |
| 59 | +>T4 : Symbol(T4, Decl(baseTypeWrappingInstantiationChain.ts, 19, 16)) |
| 60 | +} |
| 61 | + |
| 62 | +class Wrapper<T5> { |
| 63 | +>Wrapper : Symbol(Wrapper, Decl(baseTypeWrappingInstantiationChain.ts, 21, 1)) |
| 64 | +>T5 : Symbol(T5, Decl(baseTypeWrappingInstantiationChain.ts, 23, 14)) |
| 65 | + |
| 66 | + property: T5; |
| 67 | +>property : Symbol(property, Decl(baseTypeWrappingInstantiationChain.ts, 23, 19)) |
| 68 | +>T5 : Symbol(T5, Decl(baseTypeWrappingInstantiationChain.ts, 23, 14)) |
| 69 | +} |
0 commit comments