TypeScript/tests/baselines/reference/recursivelySpecializedConstructorDeclaration.types

50 lines
2.3 KiB
Text
Raw Normal View History

2014-08-15 23:33:16 +02:00
=== tests/cases/compiler/recursivelySpecializedConstructorDeclaration.ts ===
module MsPortal.Controls.Base.ItemList {
>MsPortal : typeof MsPortal, Symbol(MsPortal,Decl(recursivelySpecializedConstructorDeclaration.ts,0,0))
>Controls : typeof Controls, Symbol(Controls,Decl(recursivelySpecializedConstructorDeclaration.ts,0,16))
>Base : typeof Base, Symbol(Base,Decl(recursivelySpecializedConstructorDeclaration.ts,0,25))
>ItemList : typeof ItemList, Symbol(ItemList,Decl(recursivelySpecializedConstructorDeclaration.ts,0,30))
2014-08-15 23:33:16 +02:00
export interface Interface<TValue> {
>Interface : Interface<TValue>, Symbol(Interface,Decl(recursivelySpecializedConstructorDeclaration.ts,0,40))
>TValue : TValue, Symbol(TValue,Decl(recursivelySpecializedConstructorDeclaration.ts,2,31))
2014-08-15 23:33:16 +02:00
// Removing this line fixes the constructor of ItemValue
options: ViewModel<TValue>;
>options : ViewModel<TValue>, Symbol(options,Decl(recursivelySpecializedConstructorDeclaration.ts,2,40))
>ViewModel : ViewModel<TValue>, Symbol(ViewModel,Decl(recursivelySpecializedConstructorDeclaration.ts,10,5))
>TValue : TValue, Symbol(TValue,Decl(recursivelySpecializedConstructorDeclaration.ts,2,31))
2014-08-15 23:33:16 +02:00
}
export class ItemValue<T> {
>ItemValue : ItemValue<T>, Symbol(ItemValue,Decl(recursivelySpecializedConstructorDeclaration.ts,5,5))
>T : T, Symbol(T,Decl(recursivelySpecializedConstructorDeclaration.ts,7,27))
2014-08-15 23:33:16 +02:00
constructor(value: T) {
>value : T, Symbol(value,Decl(recursivelySpecializedConstructorDeclaration.ts,8,20))
>T : T, Symbol(T,Decl(recursivelySpecializedConstructorDeclaration.ts,7,27))
2014-08-15 23:33:16 +02:00
}
}
export class ViewModel<TValue> extends ItemValue<TValue> {
>ViewModel : ViewModel<TValue>, Symbol(ViewModel,Decl(recursivelySpecializedConstructorDeclaration.ts,10,5))
>TValue : TValue, Symbol(TValue,Decl(recursivelySpecializedConstructorDeclaration.ts,12,27))
>ItemValue : ItemValue<T>, Symbol(ItemValue,Decl(recursivelySpecializedConstructorDeclaration.ts,5,5))
>TValue : TValue, Symbol(TValue,Decl(recursivelySpecializedConstructorDeclaration.ts,12,27))
2014-08-15 23:33:16 +02:00
}
}
// Generates:
/*
declare module MsPortal.Controls.Base.ItemList {
interface Interface<TValue> {
options: ViewModel<TValue>;
}
class ItemValue<T> {
constructor(value: T);
}
class ViewModel<TValue> extends ItemValue<TValue> {
}
}
*/