Re: valid settings for use="..." on <attribute>s in <complexType>s derived by restriction

Sorry for the long delay in replying to you.

mhuffman@ca.ibm.com writes:

> Please consider the following example:
> 
> <xsd:complexType name="baseType">
>      <xsd:attribute name="attrib1" type="xsd:string" use="prohibited"/>
> </xsd:complexType>
> 
> <xsd:complexType name="restrictedType">
>      <xsd:complexContent>
>           <xsd:restriction base="baseType">
>                <xsd:attribute name="attrib1" type="xsd:string" use
> ="required"/>
>           </xsd:restriction>
>      </xsd:complexContent>
> </xsd:complexType>
> 
> According to [1], 2.1.1 this is a valid restriction since 2.1.1.1 and
> 2.1.1.2 are both true.  I could also have used use="optional" in my
> "restrictedType" and this would be valid as per 2.1.1 as well since 2.1.1.1
> would still be true.

The WG considered your point, and concluded that you had misunderstood 
one aspect of the spec. and no erratum was required:

The restriction is disallowed because _at the component level_ the
base type has no attribute of the relevant name.

ht
-- 
  Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
          W3C Fellow 1999--2001, part-time member of W3C Team
     2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440
	    Fax: (44) 131 650-4587, e-mail: ht@cogsci.ed.ac.uk
		     URL: http://www.ltg.ed.ac.uk/~ht/

Received on Thursday, 25 October 2001 04:44:05 UTC