- From: Tab Atkins Jr. <jackalmage@gmail.com>
- Date: Thu, 24 Nov 2011 18:58:27 -0800
- To: Yehuda Katz <wycats@gmail.com>
- Cc: Lachlan Hunt <lachlan.hunt@lachy.id.au>, Sean Hogan <shogun70@westnet.com.au>, Boris Zbarsky <bzbarsky@mit.edu>, public-webapps@w3.org
On Thu, Nov 24, 2011 at 10:53 AM, Yehuda Katz <wycats@gmail.com> wrote: >> > * Is :scope always implied if it begins with an explicit combinator >> > other >> > than descendant, even if :scope is used elsewhere? >> > find(">div :scope"); >> > find("+div :scope"); >> > find("~div :scope"); >> >> Yes. > > I think I would be ok with this case throwing, because all of the cases are > nonsense queries. *Those* cases are nonsense. Use the reference combinator, though, and it suddenly becomes possibly reasonable. Alternately, assume that :matches() is eventually changed to allow complex selectors. Using :scope there is completely fine. Rather than trying to carve out some ways that are okay and other ways that throw, I think it's better to just use the simplest possible rule: prepend :scope to them and evaluate them as normal. The selectors above just won't match anything, is all. ~TJ
Received on Friday, 25 November 2011 02:59:22 UTC