Question about "Element Declarations Consistent" constraint

Consider the following:

<<
Constraint on Schemas: Element Declarations Consistent 

  If the {particles} contains, either directly, indirectly (that is,
within the {particles} of a contained model group, recursively) or
implicitly two or more element declaration particles with the same
{name} and {target namespace}, all their {type definition}s must be
the same.
>>

What does the phrase "must be the same" mean?

Pretty clearly, the following should be ok.

       <sequence>
         <element name="a" type="x"/>
	 <element name="a" type="x"/>
       </sequence>

But is this ok, or not ok?

       <sequence>
         <element name="a">
	   <type>
	     <element name="b" type="x"/>
	   </type>	     
         </element>
         <element name="a">
	   <type>
	     <element name="b" type="x"/>
	   </type>	     
         </element>
       </sequence>

-- Jerome Simeon and Philip Wadler

Received on Friday, 11 August 2000 11:46:05 UTC