Re: [csswg-drafts] [selectors-4] Clarify :lang() behavior when the language range is not a well-formed BCP 47 code (#8720)

  > Normally, extended filtering does not prevent non-well-formed tags from being matched.

But canonicalization does in RFC 5646 - Section 4.5 (Canonicalization of Language Tags):

  > A language tag is in 'extlang form' when the tag is well-formed according to the rules in Sections 2.1 and 2.2

This implies that the canonicalization ensures that the language tag/ranges are well-formed. But if anything should be validated as well-formed, I think only the language tag needs to be.

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


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

Received on Thursday, 14 May 2026 17:11:11 UTC