libxml-rs 0.1.0-alpha.39

Native-Rust forensic reimplementation of libxml2+libxslt with C ABI drop-in replacement. Cross-version oracle matrix (libxml2 2.7.8-2.15.3, libxslt 1.1.26-1.1.45) with semantic epochs; full xmllint/xmlcatalog/xsltproc CLIs; differential-court-verified C API closure; three-DSO ELF packaging (libxml2.so.16 core + libxslt.so.1/libexslt.so.0 facades, upstream NEEDED chain); fail-closed oracle-isolated ABI-FUNCTION-SIGNATURE plane (SOURCE_PROTOTYPE + MACHINE_ABI fingerprints, zero silent omissions); Phase-12 real downstream substitution (binary/static/docker substitution, export-surface disposition, ELF version graphs); Phase-13 hostile audit courts (ABI/ownership/allocator/callbacks/failure/threads/oracle-contamination) byte-identical vs the system oracle incl. the upstream thread-local globals model; Phase-14 downstream custodian validation courts (lxml/Nokogiri/PHP/Debian). Test counts live in atlas/TEST_COUNTS.json, residuals in atlas/RESIDUAL_LEDGER.json (generated evidence).
Documentation
/**
 * @file
 *
 * Global state API for libxml-rs
 */

#ifndef __XML_GLOBALS_H__
#define __XML_GLOBALS_H__

#include <libxml/xmlversion.h>
#include <libxml/xmlerror.h>
#include <libxml/parser.h>
#include <libxml/HTMLparser.h>

#ifdef __cplusplus
extern "C" {
#endif

XMLPUBFUN void xmlInitGlobals(void);
XMLPUBFUN void xmlCleanupGlobals(void);

/* Exported data globals (upstream globals.h XMLPUBVAR declarations).
 *
 * Phase 13 (HOSTILE-THREADS): the parser defaults, the error-handler slots
 * and the node/IO hooks are THREAD-LOCAL in upstream 2.15
 * (LIBXML_THREAD_ENABLED, globals.c xmlGetThreadLocalStorage): the oracle
 * headers declare them as `(*__xmlXxx())` macro aliases of accessor
 * FUNCTIONS (parser.h / xmlerror.h / xmlIO.h / tree.h), and the oracle DSO
 * exports only those accessors. The candidate headers follow the same
 * contract, so the declarations moved to the matching headers as accessor
 * decls + macros; only the globals the executed oracle keeps as plain data
 * remain declared here. */
XMLPUBVAR int xmlParserDebugEntities;
XMLPUBVAR int xmlTreeIndentNumber;
XMLPUBVAR xmlBufferAllocationScheme xmlBufferAllocScheme;
XMLPUBVAR int xmlDefaultBufferSize;
XMLPUBVAR int xmlParserMaxDepth;

#ifdef __cplusplus
}
#endif

#endif /* __XML_GLOBALS_H__ */