<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>22294</bug_id>
          
          <creation_ts>2013-06-06 08:43:24 +0000</creation_ts>
          <short_desc>SchemaImport/emptyUnion11.xsd is not valid</short_desc>
          <delta_ts>2013-06-07 17:31:34 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>XPath / XQuery / XSLT</product>
          <component>XQuery 3 &amp; XPath 3 Test Suite</component>
          <version>Working drafts</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Sorin Nasoi">spungi</reporter>
          <assigned_to name="Michael Kay">mike</assigned_to>
          <cc>mike</cc>
    
    <cc>oneil</cc>
          
          <qa_contact name="Mailing list for public feedback on specs from XSL and XML Query WGs">public-qt-comments</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>88818</commentid>
    <comment_count>0</comment_count>
    <who name="Sorin Nasoi">spungi</who>
    <bug_when>2013-06-06 08:43:24 +0000</bug_when>
    <thetext>SchemaImport/emptyUnion11.xsd contains an empty union type that is not valid according to:

http://www.w3.org/TR/xmlschema11-2/#defn-rep-constr
&quot;Either the memberTypes [attribute] of the &lt;union&gt; element must be non-empty or there must be at least one simpleType [child].&quot;

Here is the error thrown by Xerces when validating the mentioned schema:
E [Xerces] src-union-memberTypes-or-simpleTypes: A &lt;union&gt; element must have either a non-empty memberTypes [attribute] or at least one &lt;simpleType&gt; element among its [children].</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>88834</commentid>
    <comment_count>1</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2013-06-06 18:13:22 +0000</bug_when>
    <thetext>As I pointed out in message

https://lists.w3.org/Archives/Member/w3c-xsl-query/2013May/0042.html

the XSD 1.1 spec is a little unclear whether unions with no members are allowed.

However, the reference you provided seems to make it clear that even if they are allowed at the schema component level (which is necessary to support xs:empty) they are not allowed at the XML representation level, which makes them effectively untestable. So I think we will have to withdraw this collection of tests.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>88835</commentid>
    <comment_count>2</comment_count>
    <who name="Sorin Nasoi">spungi</who>
    <bug_when>2013-06-06 18:17:46 +0000</bug_when>
    <thetext>(In reply to comment #1)
&gt; As I pointed out in message
&gt; 
&gt; https://lists.w3.org/Archives/Member/w3c-xsl-query/2013May/0042.html
&gt; 
&gt; the XSD 1.1 spec is a little unclear whether unions with no members are
&gt; allowed.
&gt; 
&gt; However, the reference you provided seems to make it clear that even if they
&gt; are allowed at the schema component level (which is necessary to support
&gt; xs:empty) they are not allowed at the XML representation level, which makes
&gt; them effectively untestable. So I think we will have to withdraw this
&gt; collection of tests.

Here is the list of test-cases from &quot;prod-SchemaImport&quot; that are using the SchemaImport/emptyUnion11.xsd:

prod-SchemaImport empty-union-001, prod-SchemaImport empty-union-005, prod-SchemaImport empty-union-006, prod-SchemaImport empty-union-007, prod-SchemaImport empty-union-015, prod-SchemaImport empty-union-016, prod-SchemaImport empty-union-020, prod-SchemaImport empty-union-028, prod-SchemaImport empty-union-034, prod-SchemaImport empty-union-035, prod-SchemaImport empty-union-037, prod-SchemaImport empty-union-041, prod-SchemaImport empty-union-042, prod-SchemaImport empty-union-049</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>88906</commentid>
    <comment_count>3</comment_count>
    <who name="O&apos;Neil Delpratt">oneil</who>
    <bug_when>2013-06-07 16:40:36 +0000</bug_when>
    <thetext>Removed test cases specified in comment #2.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>88907</commentid>
    <comment_count>4</comment_count>
    <who name="Michael Kay">mike</who>
    <bug_when>2013-06-07 17:31:34 +0000</bug_when>
    <thetext>The list of tests in comment #2 was (very) incomplete. All the tests with names beginning &quot;emptyUnion&quot; have now been removed.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>