PureXML/Sources/Schema
Mihaela Mihaljevic 711a50b8ea feat(schema): reject ur-type widening in element restriction
Extend NameAndTypeOK: restricting a concrete-typed element to an ur-type
(xs:anyType / xs:anySimpleType / xs:anyAtomicType) is widening, hence an invalid
restriction. The element-vs-element check now rejects it before the atomic
derivation check.

The ur-type is recognised by a type reference whose key is anyType /
anySimpleType / anyAtomicType AND which is absent from the named-type table, so
a user type that merely shares the local name (in another namespace) is not
mistaken for the ur-type. The reverse (an ur-type base narrowed by the
restriction) stays valid.

XSTS: invalid schemas accepted 620 to 616, valid schemas rejected held at 72,
instance buckets unchanged.
2026-06-14 13:07:31 +02:00
..
BuiltinType.swift feat(schema): built-in xsi:type resolution gated by substitution validity 2026-06-13 21:21:35 +02:00
ComplexType.swift fix(schema): honor empty-element default/fixed values and replace enumeration on restriction 2026-06-13 18:04:25 +02:00
ComplexValidator.swift feat(schema): built-in xsi:type resolution gated by substitution validity 2026-06-13 21:21:35 +02:00
ComplexValidatorDerivation.swift
ComplexValidatorHelpers.swift feat(schema): built-in xsi:type resolution gated by substitution validity 2026-06-13 21:21:35 +02:00
ComplexValidatorIDs.swift fix(schema): enforce document-scoped xs:ID uniqueness and xs:IDREF resolution 2026-06-13 19:17:34 +02:00
ComplexValidatorStreaming.swift
ComplexValidatorXSIType.swift feat(schema): built-in xsi:type resolution gated by substitution validity 2026-06-13 21:21:35 +02:00
ContentMatcher.swift
ContentModelDeterminism.swift feat(schema): enforce Unique Particle Attribution (cos-nonambig) 2026-06-14 09:35:33 +02:00
DateTimeParser.swift feat(schema): validate value-bound facet definitions; accept gMonth --MM-- 2026-06-13 22:10:57 +02:00
DateTimeValue.swift
DecimalValue.swift
DerivationMethod.swift
DurationValue.swift
IdentityConstraint.swift
IdentityValidator.swift feat(schema): built-in xsi:type resolution gated by substitution validity 2026-06-13 21:21:35 +02:00
IDTracker.swift fix(schema): enforce document-scoped xs:ID uniqueness and xs:IDREF resolution 2026-06-13 19:17:34 +02:00
Lexical.swift
ParticleRestriction.swift feat(schema): reject ur-type widening in element restriction 2026-06-14 13:07:31 +02:00
Primitive.swift
RelaxNGCompactHelpers.swift
RelaxNGCompactLexer.swift
RelaxNGCompactParser.swift
RelaxNGContentType.swift
RelaxNGDerivative.swift
RelaxNGDiagnostics.swift
RelaxNGFacets.swift
RelaxNGGrammarCheck.swift
RelaxNGGrammarCheckSections.swift
RelaxNGNameClasses.swift
RelaxNGNode.swift
RelaxNGParser.swift
RelaxNGParserIncludes.swift
RelaxNGPattern.swift
RelaxNGRestrictionChecker.swift
RelaxNGRestrictionOverlap.swift
RelaxNGRestrictionPaths.swift
RelaxNGRestrictions.swift
RelaxNGSchema.swift
SchemaContentOrder.swift feat(schema): enforce complexType shorthand content order 2026-06-14 11:15:24 +02:00
SchemaDocument.swift feat(schema): validate constraining-facet definitions at compile time 2026-06-13 21:50:51 +02:00
SchemaFacetApplicability.swift feat(schema): validate built-in-typed default/fixed values 2026-06-14 11:55:55 +02:00
SchemaIDAttribute.swift feat(schema): validate the id attribute (xs:ID) at compile time 2026-06-13 22:29:29 +02:00
SchemaIdentityXPath.swift feat(schema): validate identity-constraint selector/field XPath subset 2026-06-14 10:30:06 +02:00
SchemaNameUniqueness.swift feat(schema): resolve keyref refer to a declared key or unique 2026-06-14 08:04:34 +02:00
SchemaReferences.swift feat(schema): resolve keyref refer to a declared key or unique 2026-06-14 08:04:34 +02:00
SchemaStructure.swift feat(schema): validate built-in-typed default/fixed values 2026-06-14 11:55:55 +02:00
SchemaWildcardNamespace.swift feat(schema): validate wildcard namespace constraint value space 2026-06-14 11:00:45 +02:00
SimpleType.swift feat(schema): built-in xsi:type resolution gated by substitution validity 2026-06-13 21:21:35 +02:00
StreamingXSDValidator.swift
TypeDerivation.swift
XSDAttributeParser.swift fix(schema): resolve <xs:attribute ref> to global attribute declarations 2026-06-13 19:30:11 +02:00
XSDCompletions.swift
XSDComplexContent.swift
XSDContext.swift feat(schema): validate constraining-facet definitions at compile time 2026-06-13 21:50:51 +02:00
XSDDerivation.swift fix(schema): enforce block="substitution" on substitution-group heads 2026-06-13 18:31:07 +02:00
XSDParser.swift feat(schema): enforce Unique Particle Attribution (cos-nonambig) 2026-06-14 09:35:33 +02:00
XSDSchemaValidations.swift feat(schema): check element type in Particle Valid (Restriction) 2026-06-14 12:29:23 +02:00
XSDSimpleParser.swift feat(schema): validate pattern facet regular expressions at compile time 2026-06-13 23:52:11 +02:00
XSDValidations.swift fix(schema): enforce document-scoped xs:ID uniqueness and xs:IDREF resolution 2026-06-13 19:17:34 +02:00
XSDWildcardParser.swift