<?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>2196</bug_id>
          
          <creation_ts>2005-09-14 19:03:11 +0000</creation_ts>
          <short_desc>R-204: ComplexType mapping rule issue: min=max=0</short_desc>
          <delta_ts>2009-04-21 19:21:35 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>XML Schema</product>
          <component>Structures: XSD Part 1</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard>thimble, easy</status_whiteboard>
          <keywords>resolved</keywords>
          <priority>P4</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Sandy Gao">sandygao</reporter>
          <assigned_to name="C. M. Sperberg-McQueen">cmsmcq</assigned_to>
          
          
          <qa_contact name="XML Schema comments list">www-xml-schema-comments</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>6212</commentid>
    <comment_count>0</comment_count>
    <who name="Sandy Gao">sandygao</who>
    <bug_when>2005-09-14 19:03:11 +0000</bug_when>
    <thetext>What is the content type of the following? 

&lt;complexType&gt;
  &lt;sequence min=max=0&gt;
    &lt;element .../&gt;

According to the complexType complexContent mapping rules, because there IS a 
sequence with an element child, the effective content is not empty, but is the 
particle corresponding to the sequence. But according to section 3.8.2, 
min=max=0 corresponds to no component at all. 

Shouldn&apos;t 2.1.1 of the definition of effective content in the mapping rules (of 
2nd edition) be changed to:

2.1.1 There is no &lt;group&gt; &lt;all&gt; &lt;choice&gt; or &lt;sequence&gt; among the [children], 
which either doesn&apos;t have a maxOccur attribute, or the actual value of such 
attribute is not 0. 

See
http://lists.w3.org/Archives/Public/www-xml-schema-comments/2003JanMar/0038.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>11876</commentid>
    <comment_count>1</comment_count>
    <who name="C. M. Sperberg-McQueen">cmsmcq</who>
    <bug_when>2006-09-19 19:58:29 +0000</bug_when>
    <thetext>There does seem to be a discrepancy between the two locations.

But instead of making 2.1.1 more complicated, I think it would
be simpler to address the case where the outermost group
has min=max=0 with a separate clause (a new 2.1.4, that is), 
so that the beginning of 2.1 reads:

  2.1 If  one of the following is true

    2.1.1 There is no &lt;group&gt;, &lt;all&gt;, &lt;choice&gt; or &lt;sequence&gt; among the
          [children];

    2.1.2 There is an &lt;all&gt; or &lt;sequence&gt; among the [children] with no
          [children] of its own excluding &lt;annotation&gt;;

    2.1.3 There is a &lt;choice&gt; among the [children] with no [children]
          of its own excluding &lt;annotation&gt; whose minOccurs
          [attribute] has the ·actual value· 0;

    2.1.4 The only &lt;group&gt;, &lt;all&gt;, &lt;choice&gt; or &lt;sequence&gt; among the
          [children] has a maxOccurs [attribute] with an actual value
          of 0;

  , then the appropriate case among the following:  ...

(I entertained an alternative analysis, that this case was 
correctly excluded, so as to create an unsatisfiable particle,
but min=0 is never unsatisfiable, and min=max=0 is 
satisfied by the empty sequence, no matter what the min and
max are on.  So the particle created in the status quo accepts
the empty sequence, and only the empty sequence.  We might
as well make it use the keyword.)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12628</commentid>
    <comment_count>2</comment_count>
    <who name="C. M. Sperberg-McQueen">cmsmcq</who>
    <bug_when>2006-10-27 21:08:31 +0000</bug_when>
    <thetext>At its telcon of today, the WG accepted the analysis and wording proposal
in comment #1.  The change will appear in the next version of the
status quo document.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>