core
core copied to clipboard
Inheriting from a stub class
The prototype chain is not set correctly. The following code:
[<Stub>]
type ParentClass() = class end
[<JavaScript>]
type ComponentClass() =
inherit ParentClass()
should generate this:
ComponentClass=Runtime.Class({},ParentClass,ComponentClass);
ComponentClass.New=Runtime.Ctor(function()
{
ParentClass.call(this);
},ComponentClass);
but instead generates this:
ComponentClass=Runtime.Class({},null,ComponentClass);
// ^^^^ this should be ParentClass
ComponentClass.New=Runtime.Ctor(function()
{
ParentClass.call(this);
},ComponentClass);