- From: Albert Marashi via GitHub <sysbot+gh@w3.org>
- Date: Mon, 27 Nov 2023 04:44:55 +0000
- To: public-css-archive@w3.org
By the way, if anyone implementing this was confused about how to know whether we're parsing a declaration or a rule this was my algorithm: - if parser.match("@") - read_at_rule() - let start_index = parser.index - parser.read_until(SEMICOLON_OR_OPEN_BRACE_OR_CLOSE_BRACE) (don't consume the final char though `;` `{` `}`) - if parser.match("{") - parser.index = start_index (rewind to start of rule) - read_rule() - else we're reading a declaration (it ends with `;` or `}` which are both valid endings) - parser.index = start_index - read_declaration() -- GitHub Notification of comment by AlbertMarashi Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/7961#issuecomment-1827117743 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Monday, 27 November 2023 04:44:56 UTC