[Webkit-unassigned] [Bug 12359] New: XPathEvaluator may return some nodes more than once in a result set

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Jan 21 20:22:46 PST 2007


http://bugs.webkit.org/show_bug.cgi?id=12359

           Summary: XPathEvaluator may return some nodes more than once in a
                    result set
           Product: WebKit
           Version: 420+ (nightly)
          Platform: Macintosh
               URL: http://andrewdupont.net/test/double-dollar/
        OS/Version: Mac OS X 10.4
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: HTML DOM
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: webkit at andrewdupont.net
                CC: webkit at andrewdupont.net


While working on routing CSS selector queries through XPath for performance, I
noticed that WebKit's version of document.evaluate doesn't ensure uniqueness of
the result set.  At the test URL, you'll notice that some queries -- like "div
div" (or in XPath: ".//div//div" -- fail: the length of the result set is far
larger than it should be because a DIV with two DIV ancestors would occur
twice.  This is different from the behavior of Firefox or Opera.  Filtering for
uniqueness in my own code solves this problem.

Discovered using document.evaluate with result set of type
ORDERED_NODE_SNAPSHOT_TYPE.


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



More information about the webkit-unassigned mailing list