This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
In certain cases, I'm not sure the current REC makes the right call on when to do recursive checking up the base type chain and when not. Consider the following schema document: <xs:schema> <xs:element name="root" type="top"/> <xs:complexType name="top" final="restriction"> <xs:sequence> <xs:element name="a" minOccurs="0"/> </xs:sequence> </xs:complexType> <xs:complexType name="intermediate"> <xs:complexContent> <xs:extension base="top"> <xs:sequence> <xs:element name="b"/> </xs:sequence> </xs:extension> </xs:complexContent> </xs:complexType> <xs:complexType name="bottom"> <xs:complexContent> <xs:restriction base="intermediate"> <xs:sequence> <xs:element name="b"/> </xs:sequence> </xs:restriction> </xs:complexContent> </xs:complexType> <xs:complexType name="top2"> <xs:sequence> <xs:element name="c" type="top"/> </xs:sequence> </xs:complexType> <xs:complexType name="restrictOKorNot"> <xs:complexContent> <xs:restriction base="top2"> <xs:sequence> <xs:element name="c" type="bottom"/> </xs:sequence> </xs:restriction> </xs:complexContent> </xs:complexType> </xs:schema> The constraints on type definitions do _not_ recurse up the chain when checking 'final', so the type def named 'bottom' above is OK, despite restricting away an element ('a') introduced in a type definition which says it's final for restriction. However, content model checking _does_ recurse up the chain, so the type defn named 'restrictOKorNot' is _not_ OK. Neither is that following instance, wrt the schema corresponding to the above schema doc: <root xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="bottom"> <b/> </root> Is this really what we want? See http://lists.w3.org/Archives/Public/www-xml-schema-comments/2004JanMar/0087.html
The WG agreed that the type RestrictOKorNot is not legal, and that it should not be. The chain of derivation from bottom to top has some non-restriction steps, and that means it should not be OK to substitute bottom for top in the restriction. The WG decided to make no change here. The originator of the comment, Henry Thompson, agrees.