[Bug 17146] New: [Custom]: Constructor generation algorithm doesn’t create the right prototype chain

https://www.w3.org/Bugs/Public/show_bug.cgi?id=17146

           Summary: [Custom]: Constructor generation algorithm doesn’t
                    create the right prototype chain
           Product: WebAppsWG
           Version: unspecified
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Component Model
        AssignedTo: dglazkov@chromium.org
        ReportedBy: dominicc@chromium.org
         QAContact: public-webapps-bugzilla@w3.org
            Blocks: 14968


Specifically in this part:

"Create a new JavaScript object with BASE as prototype"

This is a ambiguous because BASE is described as "a DOM element which
implements the HTMLElement interface." Is it an instance of a DOM element? Or
the constructor like HTMLFooElement?

Anyway, the prototype of the new JavaScript object should be BASE.prototype, eg
HTMLDivElement.prototype.

Probably more precise prose is required here because not all HTML elements have
specific unique prototypes (eg INS, DEL both use HTMLModElement.)

Can I suggest replacing step 1 with language like:

Let BASEINTERFACE be the DOM Interface used by BASE.
Create a new JavaScript object with BASEINTERFACE.prototype as the prototype.

-- 
Configure bugmail: https://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

Received on Tuesday, 22 May 2012 02:30:53 UTC