Skip to content

v0.4.0

Choose a tag to compare

@mathieu17g mathieu17g released this 03 Jul 20:39
056b97f

Breaking release — ground-up rewrite of the internals: token-based parser, Cursor streaming (StAX-style) API, XPath subset, configurable well-formedness. Upgrading from 0.3.x? See the migration guide.

Added

  • Cursor — allocation-light forward streaming (next!, for_each_child, skip_element!).
  • xpath(node, path) — an XPath 1.0 subset.
  • wellformed = :lenient | :structural | :strict on parse/read (default :structural).
  • XMLTokenizer streaming tokenizer; AbstractTrees package extension.

Changed

  • Node is parametric (Node{S}), attributes are Vector{Pair} behind an attributes accessor.
  • parse/read decode entities (value() returns &, not &); write auto-escapes.
  • Inter-element whitespace is preserved as Text nodes; duplicate attributes error; malformed documents are rejected by default (:lenient restores the permissive behavior).
  • Minimum Julia is 1.10. Substantially faster and leaner than 0.3.x — see PERFORMANCE-v0.4.md.

Removed

  • The 0.3 streaming internals: XML.Raw, next/prev, single-argument parent/depth, nodes_equal, escape!/unescape!, DTDBody — replacements in the migration guide.

Full details: CHANGELOG.