[Bug 4565] Default attribute values not always applied

http://www.w3.org/Bugs/Public/show_bug.cgi?id=4565

           Summary: Default attribute values not always applied
           Product: XML Schema
           Version: 1.0/1.1 both
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: unclassified
          Severity: normal
          Priority: P2
         Component: Structures: XSD Part 1
        AssignedTo: cmsmcq@w3.org
        ReportedBy: sandygao@ca.ibm.com
         QAContact: www-xml-schema-comments@w3.org


Section 3.4.5 of the structures spec currently reads

"For each attribute use in the {attribute uses} whose {required} is false and
whose {value constraint} is not ·absent· ..."

Consider a global attribute declaration:

  <attribute name="a" default="xyz"/>

And a reference to this global declaration:

  <attribute ref="a"/>

In this case, the attribute declaration has a default value, but the reference
(hence the attribute use) doesn't. Strictly following 3.4.5, "xyz" is *not*
applied when "a" is missing in the instance. Intended?

Shouldn't 3.4.5 refer to the "effective value constraint" as opposed to "whose
{value constraint}"?

Received on Thursday, 17 May 2007 16:57:43 UTC