Re: [csswg-drafts] [css-nesting-1] consider dividing future selector syntax and future declaration syntax differently (#8251)

I [commented over in #8249](https://github.com/w3c/csswg-drafts/issues/8249#issuecomment-1379357471), but a relevant point from that comment is:

> The recovery rules are:
> 
> * if something invalid is being parsed as a declaration, we throw away tokens until the next top-level semicolon.
> * if something invalid is being parsed as a nested rule, we throw away tokens until the next top-level semicolon or top-level {}-block.
> 
> This suggests that (a) we want to bias toward parsing unknown things as nested rules, since the recovery is stricter/safer, and (b) if an older browser parses some pattern as an (invalid) nested rule, and we decide to make that pattern a declaration instead, this is fine so long as it doesn't contain a {}-block followed by something that looks like a complete (prop:val;) declaration.

So I believe we *should* bias towards triggering nested-rule parsing, and thus keep the current spec (which treats all of those currently-invalid-either-way tokens as being selectors).

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/8251#issuecomment-1379360966 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 11 January 2023 19:11:32 UTC