![]() | Fun 0.41.5 The programming language that makes You have fun |
Lightweight libxml2 handle registry for Fun VM extension helpers. More...

Go to the source code of this file.
Lightweight libxml2 handle registry for Fun VM extension helpers.
This module provides small fixed-size registries for libxml2 objects when compiled with FUN_WITH_XML2. Documents and nodes can be associated with small integer handles to make them easier to pass around inside the interpreter and its C API boundaries. The document registry owns the underlying xmlDoc, while the node registry does not own the xmlNode — nodes are freed when their owning document is freed.
Limits: The registries are fixed-size (docs: 64, nodes: 256). Handle value 0 is reserved and indicates failure/invalid.
Thread-safety: Not thread-safe. Coordinate access externally if needed.
Definition in file xml2.c.