Commit graph

3 commits

Author SHA1 Message Date
Andreas Kling
a7ece4b062 LibWeb: Make the Rust HTML parser unconditional
Remove the runtime selector between the old C++ tree builder and the new
Rust implementation. Always construct HTML documents and fragments with
the Rust parser now that it matches the existing tests.

Simplify dump-html-tree by dropping the backend option that only made
sense while both parser implementations were available.
2026-05-17 15:35:56 +02:00
Andreas Kling
09296315c2 LibWeb: Add Rust HTML parser host plumbing
Add the C++ and Rust scaffolding that lets the tree builder live in
Rust while the DOM remains owned by LibWeb. Keep the exported surface
small: Rust stores parser state, and C++ provides node creation,
insertion, script, template, and GC hooks.

Route dump-html-tree through the selectable parser backend so the new
implementation can be exercised beside the existing parser while it is
being brought up.
2026-05-17 15:35:56 +02:00
Andreas Kling
edf909f83d Utilities: Add dump-html-tree
Add a small parser utility for inspecting tree-construction output in
the same spirit as dump-html-tokens. Print an annotated DOM tree so
parser changes can be compared without launching the browser.

Keep a silent iteration mode for external benchmark tools, where the
parser still builds the DOM but the utility avoids serialization and
stdout work.
2026-05-17 15:35:56 +02:00