Skip to content

script: Skip some steps when determining encoding for XML document#41637

Merged
simonwuelker merged 2 commits intoservo:mainfrom
simonwuelker:no-inherit-for-xml
Jan 2, 2026
Merged

script: Skip some steps when determining encoding for XML document#41637
simonwuelker merged 2 commits intoservo:mainfrom
simonwuelker:no-inherit-for-xml

Conversation

@simonwuelker
Copy link
Copy Markdown
Contributor

@simonwuelker simonwuelker commented Jan 2, 2026

XML documents do not use the "determine the encoding" algorithm. As far as I can tell, it is unspecified how they should determine the encoding instead. We now check the BOM, Content-Type header and prescan for an xml encoding declaration (but don't inherit encodings from iframes or attempt to determine the encoding from heuristics).

Testing: New tests start to pass
Part of #6414

@simonwuelker simonwuelker requested a review from gterzian as a code owner January 2, 2026 17:41
@servo-highfive servo-highfive added the S-awaiting-review There is new code that needs to be reviewed. label Jan 2, 2026
Copy link
Copy Markdown
Member

@mrobinson mrobinson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@servo-highfive servo-highfive removed the S-awaiting-review There is new code that needs to be reviewed. label Jan 2, 2026
@simonwuelker simonwuelker enabled auto-merge January 2, 2026 17:48
@simonwuelker simonwuelker added this pull request to the merge queue Jan 2, 2026
@servo-highfive servo-highfive added the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Jan 2, 2026
Merged via the queue into servo:main with commit 9ca7628 Jan 2, 2026
33 checks passed
@simonwuelker simonwuelker deleted the no-inherit-for-xml branch January 2, 2026 18:28
@servo-highfive servo-highfive removed the S-awaiting-merge The PR is in the process of compiling and running tests on the automated CI. label Jan 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants