PureXML/Sources/Regex
Mihaela Mihaljevic b4c1285d8e fix(regex): reject malformed pattern facets as schema-invalid (#145)
A pattern facet with an unambiguously malformed regular expression was
compiled leniently and the schema accepted. Three such constructs are now
rejected: a reversed character-class range ([b-a]), an empty class ([]),
and a reversed bounded quantifier ({37,17}). The parser raises distinct
RegexError cases (reversedRange, emptyClass, reversedQuantifier) that the
schema-validity check treats as invalid.

Constructs the engine merely does not support (an untabulated \p{Is...}
block, the lenient {,m} form) stay non-rejecting, so a valid pattern is
never refused. XSTS invalid-schemas-accepted 262 to 244, no other bucket
moved; the 27 regex unit tests still pass.
2026-06-17 10:49:09 +02:00
..
RegexAutomaton.swift
RegexCategory.swift
RegexParser.swift fix(regex): reject malformed pattern facets as schema-invalid (#145) 2026-06-17 10:49:09 +02:00
RegexSyntax.swift fix(regex): reject malformed pattern facets as schema-invalid (#145) 2026-06-17 10:49:09 +02:00
Unicode32Assigned.swift
XSDCategory.swift