Bug 53574 - REGRESSION (r76012): :last-child:after not working as expected
Summary: REGRESSION (r76012): :last-child:after not working as expected
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Antti Koivisto
URL:
Keywords: HasReduction, InRadar, Regression
Depends on: 52370
Blocks:
  Show dependency treegraph
 
Reported: 2011-02-01 21:52 PST by Darth
Modified: 2011-02-04 13:17 PST (History)
6 users (show)

See Also:


Attachments
testcase (346 bytes, text/html)
2011-02-01 21:52 PST, Darth
no flags Details
patch (6.42 KB, patch)
2011-02-04 13:08 PST, Antti Koivisto
dglazkov: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Darth 2011-02-01 21:52:13 PST
Created attachment 80888 [details]
testcase

Downstream bug: http://code.google.com/p/chromium/issues/detail?id=71213
Test case attached.
Expected:

*1X
*2X
*3

Actual

*1X
*2X
*3X

Happens in r77333 of webkit nightly, seems fine in r77224.


<!DOCTYPE html>
  <html>
    <head>
      <title>:last-child:after</title>
      <style>
        li:after {
          content:"X";
        }
    
        li:last-child:after{
          content:"";
        }
      </style>
    </head>
    <body>
      <ul>
        <li>1</li>
        <li>2</li>
        <li>3</li>
      </ul>
    </body>
  </html>
Comment 1 Alexey Proskuryakov 2011-02-02 09:15:00 PST
<rdar://problem/8948643>
Comment 2 Andy Estes 2011-02-02 11:09:58 PST
Caused by <http://trac.webkit.org/changeset/76012>.
Comment 3 Dimitri Glazkov (Google) 2011-02-04 10:27:31 PST
Here's another reduction:

http://jsfiddle.net/dglazkov/NmKkQ/

Should display 1234.
Comment 4 Antti Koivisto 2011-02-04 13:08:44 PST
Created attachment 81274 [details]
patch
Comment 5 Dimitri Glazkov (Google) 2011-02-04 13:10:15 PST
Comment on attachment 81274 [details]
patch

yay!
Comment 6 Antti Koivisto 2011-02-04 13:11:57 PST
also fixes Bug 53610
Comment 7 Antti Koivisto 2011-02-04 13:17:27 PST
http://trac.webkit.org/changeset/77664