From 338592f2765b60df40509920b1ebd97b076f55c7 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Mon, 22 Jun 2026 03:33:31 +0900 Subject: feat(php-shim): add DOMDocument/DOMNode XML shim Implements a minimal, PHP-compatible subset of \DOMDocument, \DOMNode and \DOMNodeList for use by Symfony's XmlDescriptor. save_xml mirrors libxml2's formatOutput serialization (XML declaration, 2-space indent, self-closing empty elements, and no pretty-printing of text-bearing elements) and writes to a std::io::Write sink. Verified byte-for-byte against real PHP libxml. Co-Authored-By: Claude Opus 4.8 (1M context) --- crates/shirabe-php-shim/src/lib.rs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'crates/shirabe-php-shim/src/lib.rs') diff --git a/crates/shirabe-php-shim/src/lib.rs b/crates/shirabe-php-shim/src/lib.rs index 0d7f8ef..10e89fe 100644 --- a/crates/shirabe-php-shim/src/lib.rs +++ b/crates/shirabe-php-shim/src/lib.rs @@ -22,6 +22,7 @@ mod stream; mod string; mod url; mod var; +mod xml; mod zip; pub use array::*; @@ -48,6 +49,7 @@ pub use stream::*; pub use string::*; pub use url::*; pub use var::*; +pub use xml::*; pub use zip::*; use indexmap::IndexMap; -- cgit v1.3.1