62 lines
3.2 KiB
Text
62 lines
3.2 KiB
Text
=== tests/cases/compiler/specializedInheritedConstructors1.ts ===
|
|
interface ViewOptions<TModel> {
|
|
>ViewOptions : ViewOptions<TModel>, Symbol(ViewOptions,Decl(specializedInheritedConstructors1.ts,0,0))
|
|
>TModel : TModel, Symbol(TModel,Decl(specializedInheritedConstructors1.ts,0,22))
|
|
|
|
model: TModel;
|
|
>model : TModel, Symbol(model,Decl(specializedInheritedConstructors1.ts,0,31))
|
|
>TModel : TModel, Symbol(TModel,Decl(specializedInheritedConstructors1.ts,0,22))
|
|
}
|
|
|
|
class View<TModel> {
|
|
>View : View<TModel>, Symbol(View,Decl(specializedInheritedConstructors1.ts,2,1))
|
|
>TModel : TModel, Symbol(TModel,Decl(specializedInheritedConstructors1.ts,4,11))
|
|
|
|
constructor(options: ViewOptions<TModel>) { }
|
|
>options : ViewOptions<TModel>, Symbol(options,Decl(specializedInheritedConstructors1.ts,5,16))
|
|
>ViewOptions : ViewOptions<TModel>, Symbol(ViewOptions,Decl(specializedInheritedConstructors1.ts,0,0))
|
|
>TModel : TModel, Symbol(TModel,Decl(specializedInheritedConstructors1.ts,4,11))
|
|
|
|
model: TModel;
|
|
>model : TModel, Symbol(model,Decl(specializedInheritedConstructors1.ts,5,49))
|
|
>TModel : TModel, Symbol(TModel,Decl(specializedInheritedConstructors1.ts,4,11))
|
|
}
|
|
|
|
class Model { }
|
|
>Model : Model, Symbol(Model,Decl(specializedInheritedConstructors1.ts,7,1))
|
|
|
|
class MyView extends View<Model> { }
|
|
>MyView : MyView, Symbol(MyView,Decl(specializedInheritedConstructors1.ts,9,15))
|
|
>View : View<TModel>, Symbol(View,Decl(specializedInheritedConstructors1.ts,2,1))
|
|
>Model : Model, Symbol(Model,Decl(specializedInheritedConstructors1.ts,7,1))
|
|
|
|
var m: ViewOptions<Model> = { model: new Model() };
|
|
>m : ViewOptions<Model>, Symbol(m,Decl(specializedInheritedConstructors1.ts,12,3))
|
|
>ViewOptions : ViewOptions<TModel>, Symbol(ViewOptions,Decl(specializedInheritedConstructors1.ts,0,0))
|
|
>Model : Model, Symbol(Model,Decl(specializedInheritedConstructors1.ts,7,1))
|
|
>{ model: new Model() } : { model: Model; }
|
|
>model : Model, Symbol(model,Decl(specializedInheritedConstructors1.ts,12,29))
|
|
>new Model() : Model
|
|
>Model : typeof Model, Symbol(Model,Decl(specializedInheritedConstructors1.ts,7,1))
|
|
|
|
var aView = new View({ model: new Model() });
|
|
>aView : View<Model>, Symbol(aView,Decl(specializedInheritedConstructors1.ts,13,3))
|
|
>new View({ model: new Model() }) : View<Model>
|
|
>View : typeof View, Symbol(View,Decl(specializedInheritedConstructors1.ts,2,1))
|
|
>{ model: new Model() } : { model: Model; }
|
|
>model : Model, Symbol(model,Decl(specializedInheritedConstructors1.ts,13,22))
|
|
>new Model() : Model
|
|
>Model : typeof Model, Symbol(Model,Decl(specializedInheritedConstructors1.ts,7,1))
|
|
|
|
var aView2 = new View(m);
|
|
>aView2 : View<Model>, Symbol(aView2,Decl(specializedInheritedConstructors1.ts,14,3))
|
|
>new View(m) : View<Model>
|
|
>View : typeof View, Symbol(View,Decl(specializedInheritedConstructors1.ts,2,1))
|
|
>m : ViewOptions<Model>, Symbol(m,Decl(specializedInheritedConstructors1.ts,12,3))
|
|
|
|
var myView = new MyView(m); // was error
|
|
>myView : MyView, Symbol(myView,Decl(specializedInheritedConstructors1.ts,15,3))
|
|
>new MyView(m) : MyView
|
|
>MyView : typeof MyView, Symbol(MyView,Decl(specializedInheritedConstructors1.ts,9,15))
|
|
>m : ViewOptions<Model>, Symbol(m,Decl(specializedInheritedConstructors1.ts,12,3))
|
|
|