PureXML/Sources
Mihaela Mihaljevic 119894a5a2 fix(schema): implement MapAndSum (sequence restricting a choice) in particle restriction
The W3C "Particle Valid (Restriction)" MapAndSum rule (XSD 1.0 §3.9.6): a derived
sequence restricting a base choice is valid iff each derived particle restricts
some base branch AND the derived sequence's occurrence count times its number of
particles lies within the base choice's occurrence range.

PureXML applied the same-compositor occurrence subsumption (the sequence's own
range against the choice's), which both rejected a valid restriction
(sequence{2,4}(e1,e2) of choice{3,9}(e1,e2): 4..8 elements fit 3..9) and accepted
an invalid one (a two-member sequence restricting a single-occurrence choice,
count-product 2 > 1). The count-product is the spec's measure, matched to the
reference implementation (checkMapAndSum/checkOccurrenceRange).

The (sequence, choice) branch in groupValid is retained: it is reached by the
(element, group) RecurseAsIfGroup path, which wraps an element as a one-particle
sequence against a base choice.

XSTS: valid schemas rejected 2 to 1, invalid schemas accepted 520 to 519, no
other bucket raised. The remaining valid-rejected case (particlesZ001) is a
documented spec ambiguity (RecurseAsIfGroup), recorded in docs/xsts-deviations.md.
2026-06-14 23:46:37 +02:00
..
Canonical feat(canonical): C14N 1.0 spec-example vectors, three conformance fixes 2026-06-10 08:51:47 +02:00
Catalog
Emitting feat(emitting): output encoding for UTF and single-byte families 2026-06-09 09:32:39 +02:00
HTML feat(html): HTML 4 void elements and the ampersand-brace convention 2026-06-10 16:41:54 +02:00
Model docs(model): TreeNode ownership and concurrency contracts 2026-06-10 03:46:44 +02:00
Parsing feat(xpath,parsing): public streaming surface, linear document-order at scale 2026-06-11 06:06:31 +02:00
Pattern
Regex fix(regex): use the XSD definition of \w and \W 2026-06-13 18:31:07 +02:00
Schema fix(schema): implement MapAndSum (sequence restricting a choice) in particle restriction 2026-06-14 23:46:37 +02:00
Stream
Validation refactor(validation): located structured validity findings 2026-06-10 10:45:17 +02:00
XInclude
XPath feat(xpath,xslt,wasm): evaluation budget, tailored collation, WASI runtime proof 2026-06-11 06:26:13 +02:00
XPointer
XSLT fix(schema,regex): bound NFA state explosion and class-subtraction crash; land XSTS baseline 2026-06-13 18:04:25 +02:00
API.swift feat(validation): standalone validity constraints and entity WFC 2026-06-10 07:13:30 +02:00
Lint.swift
PureXML.swift
QuickFix.swift