In the nightlies (but not Safari 3.0.3 for Tiger), when performing an XPath query with a preceding axis, some nodes which do precede the context node are not returned. It seems to occur when these missed nodes are nested in another node. E.g.: <div id="test"> <span id="A"/> <div><span id="B"> <span id="C"/> </span></div> <span id="D"/> </div> The query "preceding::xhtml:span" on span#D will not return span#C.
Created attachment 17274 [details] Test case in XHTML and inline Javascript.
Created attachment 17275 [details] Equivalent query in XSLT, to be applied to the test XHTML file.
I probably broke it when fixing bug 15436.
Created attachment 17294 [details] proposed fix
Comment on attachment 17294 [details] proposed fix r=me I love test cases!
Committed revision 27835.