[Webkit-unassigned] [Bug 83885] CSS3 Selectors failures on css3test.com

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Apr 16 05:43:15 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=83885





--- Comment #7 from Uday Kiran <udaykiran at motorola.com>  2012-04-16 05:43:15 PST ---
Thanks for review.

(In reply to comment #6)
> (From update of attachment 137311 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=137311&action=review
> 
> > Source/WebCore/ChangeLog:14
> > +        In parseIdentifier function, loop doesn't break for numbers as isCSSLetter(digit) is true,
> > +        CharacterDash is greater than CharacterNumber.
> > +        Set m_currentCharacter to '-' and resume parsing of number.
> 
> Ok this is somewhat better, but I don't think anyone will understand this except me.
> 
> Basically the issue is that n-100 is a valid CSS identifier, since it is built from letters, numbers and dashes. However, in NthChildMode we need to check whether this identifier is a valid nth child descriptor. The original code only checked this if the string was n- but this is not enough. We need to check everything which starts with an n- prefix.

Right. I will change that.
> 
> > LayoutTests/css3/parsing-css3-nthchild-expected.txt:8
> > +#a:nth-child(n-1) { color: green; }
> > +#b:nth-child(n- 10) { color: green; }
> > +#c:nth-child(-n-1) { color: green; }
> > +#d:nth-child(-n- 10) { color: green; }
> 
> I think we should add some invalid forms as well, which enters the new condition, but fails later like: n-a n-1a1 and such.

I will add more tests and upload new patch.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list