Changeset 71147 in webkit


Ignore:
Timestamp:
Nov 2, 2010 12:15:19 PM (13 years ago)
Author:
abarth@webkit.org
Message:

2010-11-02 Adam Barth <abarth@webkit.org>

Reviewed by Eric Seidel.

querySelectorAll('body>:last-child') does not work unless HTML file ends with 'new-line'.
https://bugs.webkit.org/show_bug.cgi?id=47166

We need to pop all the open elements when we end the document in the
AfterAfterBody state.

Test: fast/parser/pop-all-after-after-body.html

  • html/parser/HTMLTreeBuilder.cpp: (WebCore::HTMLTreeBuilder::processEndOfFile):

2010-11-02 Adam Barth <abarth@webkit.org>

Reviewed by Eric Seidel.

querySelectorAll('body>:last-child') does not work unless HTML file ends with 'new-line'.
https://bugs.webkit.org/show_bug.cgi?id=47166

Test that :last-child works when we end the document in the
AfterAfterBody state.

  • fast/parser/pop-all-after-after-body-expected.txt: Added.
  • fast/parser/pop-all-after-after-body.html: Added.
Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r71131 r71147  
     12010-11-02  Adam Barth  <abarth@webkit.org>
     2
     3        Reviewed by Eric Seidel.
     4
     5        querySelectorAll('body>:last-child') does not work unless HTML file ends with 'new-line'.
     6        https://bugs.webkit.org/show_bug.cgi?id=47166
     7
     8        Test that :last-child works when we end the document in the
     9        AfterAfterBody state.
     10
     11        * fast/parser/pop-all-after-after-body-expected.txt: Added.
     12        * fast/parser/pop-all-after-after-body.html: Added.
     13
    1142010-11-02  Adele Peterson  <adele@apple.com>
    215
  • trunk/WebCore/ChangeLog

    r71145 r71147  
     12010-11-02  Adam Barth  <abarth@webkit.org>
     2
     3        Reviewed by Eric Seidel.
     4
     5        querySelectorAll('body>:last-child') does not work unless HTML file ends with 'new-line'.
     6        https://bugs.webkit.org/show_bug.cgi?id=47166
     7
     8        We need to pop all the open elements when we end the document in the
     9        AfterAfterBody state.
     10
     11        Test: fast/parser/pop-all-after-after-body.html
     12
     13        * html/parser/HTMLTreeBuilder.cpp:
     14        (WebCore::HTMLTreeBuilder::processEndOfFile):
     15
    1162010-11-02  Patrick Gansterer  <paroga@webkit.org>
    217
  • trunk/WebCore/html/parser/HTMLTreeBuilder.cpp

    r70463 r71147  
    25812581    case AfterAfterBodyMode:
    25822582        ASSERT(insertionMode() == AfterBodyMode || insertionMode() == AfterAfterBodyMode);
    2583         return;
     2583        break;
    25842584    case InHeadNoscriptMode:
    25852585        ASSERT(insertionMode() == InHeadNoscriptMode);
     
    26032603        if (m_tree.currentElement() == m_tree.openElements()->htmlElement()) {
    26042604            ASSERT(isParsingFragment());
    2605             return;
     2605            return; // FIXME: Should we break here instead of returning?
    26062606        }
    26072607        if (!processColgroupEndTagForInColumnGroup()) {
    26082608            ASSERT(isParsingFragment());
    2609             return;
     2609            return; // FIXME: Should we break here instead of returning?
    26102610        }
    26112611        prepareToReprocessToken();
Note: See TracChangeset for help on using the changeset viewer.