<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>23793</bug_id>
          
          <creation_ts>2013-11-11 10:24:26 +0000</creation_ts>
          <short_desc>&quot;For each element e in elementSet, append the el...&quot;</short_desc>
          <delta_ts>2014-02-12 21:08:10 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebAppsWG</product>
          <component>DOM</component>
          <version>unspecified</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>MOVED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Simon Sapin">simon.sapin</reporter>
          <assigned_to name="Anne">annevk</assigned_to>
          <cc>bzbarsky</cc>
    
    <cc>jackalmage</cc>
    
    <cc>mike</cc>
    
    <cc>www-dom</cc>
          
          <qa_contact>public-webapps-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>96122</commentid>
    <comment_count>0</comment_count>
    <who name="Simon Sapin">simon.sapin</who>
    <bug_when>2013-11-11 10:24:26 +0000</bug_when>
    <thetext>http://dom.spec.whatwg.org/#interface-parentnode

[[
For each element e in elementSet, append the elements that are not in result and result from matching s against e&apos;s root using scoping root e, to result. [SELECTORS]
]]

This should say something about pseudo-elements. In implementations they seem to be valid, but not match anything.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96168</commentid>
    <comment_count>1</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2013-11-12 06:40:09 +0000</bug_when>
    <thetext>I don&apos;t understand why we need to mention them.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96201</commentid>
    <comment_count>2</comment_count>
    <who name="Simon Sapin">simon.sapin</who>
    <bug_when>2013-11-12 21:30:22 +0000</bug_when>
    <thetext>Well, based on the current spec, I don’t know what is supposed to happen when I use document.query(&apos;p::after&apos;). Does it throw? Return null? Ignore ::after and return a &lt;p&gt; element? It’s either specified in a part of the spec that I missed, or it’s not defined which is bad for interop.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96229</commentid>
    <comment_count>3</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2013-11-13 08:52:48 +0000</bug_when>
    <thetext>How would what it is matched be ever up to DOM? That&apos;s up to the Selectors specification.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96512</commentid>
    <comment_count>4</comment_count>
    <who name="Tab Atkins Jr.">jackalmage</who>
    <bug_when>2013-11-19 16:02:07 +0000</bug_when>
    <thetext>It&apos;s not a matter of what gets matched (Selectors does indeed define that), but what gets returned by the function.  When you match a selector against a tree, you might get pseudo-elements.  In that case, what gets added to _result_ and ultimately returned to the user?

(The right answer is to use the new PseudoElement interface, I think, but the match-current-implementation behavior is to ignore them.)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96513</commentid>
    <comment_count>5</comment_count>
    <who name="Boris Zbarsky">bzbarsky</who>
    <bug_when>2013-11-19 16:04:33 +0000</bug_when>
    <thetext>&gt; The right answer is to use the new PseudoElement interface, I think

Defining the right behavior there could get ... pretty exciting.

I think the right thing here is in fact to match current implementations.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96514</commentid>
    <comment_count>6</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2013-11-19 16:30:52 +0000</bug_when>
    <thetext>Wait, Selectors matches against a DOM, not a layout tree Tab. This again shows you not defining the actual tree creates problems.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96515</commentid>
    <comment_count>7</comment_count>
    <who name="Tab Atkins Jr.">jackalmage</who>
    <bug_when>2013-11-19 16:44:40 +0000</bug_when>
    <thetext>(In reply to Anne from comment #6)
&gt; Wait, Selectors matches against a DOM, not a layout tree Tab. This again
&gt; shows you not defining the actual tree creates problems.

Dunno what you&apos;re talking about, bro. Selectors totally returns pseudo-elements when you specify them, at least in CSS.

Agree that there&apos;s still gaps there that need to be filled in, though.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96516</commentid>
    <comment_count>8</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2013-11-19 17:02:12 +0000</bug_when>
    <thetext>Bro? What I talk about is that pseudo-elements are not in the DOM so there&apos;s no way to return them.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>100432</commentid>
    <comment_count>9</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2014-02-12 20:00:05 +0000</bug_when>
    <thetext>Is this solved with the updates to Selectors?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>100437</commentid>
    <comment_count>10</comment_count>
    <who name="Simon Sapin">simon.sapin</who>
    <bug_when>2014-02-12 21:08:10 +0000</bug_when>
    <thetext>It’s not clear to me that the issue is solved, but I guess DOM now says what it can/should and the issue is now in Selectors. Moved to http://lists.w3.org/Archives/Public/www-style/2014Feb/0447.html</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>