Re: [css4-selectors]

On Tue, Nov 29, 2011 at 2:42 AM, Florian Rivoal <> wrote:
> In the minutes Fantasai wrote:
>> The ability to select ancestors of elements is a particular area
>> of concern since it is difficult to optimize for CSS selection.
> I have another concert with this than optimization. Given the
> following markup and style, what do you expect to happen:
> <div><div>Foo</div></div>
> div! div {content: "Bar";}
> The selector should match the outer div, the replace its content
> with "Bar", after which it shouldn't match anymore, so we get
> <div>Foo</div> back, at which point it matches again...
> We could solve that by saying "You can't do that", and deciding
> that the rule should be discarded, but I wonder how easy it will
> be do define exactly what it is you can't do, and how costly it
> would be to detect at runtime (maybe not too much, just haven't
> fully thought it through).
> Otherwise, at best, we have an infinite loop. At worse, we're
> one step closer to accidentally being turing complete.

Shorter Oyvind:  Selectors work on the element-tree.  'content'
changes the box tree.


Received on Tuesday, 29 November 2011 19:44:55 UTC