[Bug 18367] New: Spec causes continuous loop

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

           Summary: Spec causes continuous loop
           Product: HTML WG
           Version: unspecified
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: HTML5 spec
        AssignedTo: ian@hixie.ch
        ReportedBy: mridul@gmail.com
         QAContact: public-html-bugzilla@w3.org
                CC: mike@w3.org, public-html-wg-issue-tracking@w3.org,
                    public-html@w3.org


Consider the stack of open elements to be :
html, body, form, table, tbody

(form being present is irrelevant to this imo).

The current insertion mode is IN TABLE BODY as expected.


When the next token being consumed is end tag p, then the parser will go into
an infinite loop.

IN TABLE BODY will delegate to IN TABLE, which will delegate to IN BODY with
foster parenting enabled.
The end tag p will cause a 'act as if' start token for p (since there is no P
in button scope) - which will go through same flow to end in IN BODY with
foster parenting enabled.
The resulting insertion of p tag due to then token will get foster parent'ed -
and so, on return, reconsumption of end tag p will essentially cause the same
loop to be repeated indefinitely.


If our understanding of the spec, as detailed above, is incorrect - that would
be great ! Please do let us know.


Thanks,
Mridul

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

Received on Monday, 23 July 2012 23:07:55 UTC