W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > April to June 2011

[Bug 12185] Conditional Type Assignment and substitutability

From: <bugzilla@jessica.w3.org>
Date: Sat, 23 Apr 2011 18:24:18 +0000
To: www-xml-schema-comments@w3.org
Message-Id: <E1QDhVC-0004oy-7I@jessica.w3.org>
http://www.w3.org/Bugs/Public/show_bug.cgi?id=12185

--- Comment #8 from Michael Kay <mike@saxonica.com> 2011-04-23 18:24:16 UTC ---
Responding to comment #4, in particular:

Q1: You don't say so explicitly, but I understand you to be thinking of
a pair of complex types B and R each of which has a content model
including the top-level 'chap'.  But in that case, the Conditional
Type Substitutable rules will have no objection.

A1: I'm not entirely sure what I was thinking of, but it might have been this:
a complex type B that allows a sequence of chap elements whose element
declaration is akin to that of element chap in my original example, and a
complex type R that allows a sequence of chap elements whose element
declaration (necessarily local) is akin to that of element appendix in my
original example. I think this is the situation in which (under the status quo)
we discover at "validation time" that R is not a valid restriction of B. But I
might be wrong - I'm writing this without re-reading the rules, which is
probably not a good idea.

Q2: A second comment, on a side point.  The bug description says 

    it's very unsatisfactory that problems with the schema should be
    detected during instance validation.

It may be unsatisfactory to find schema errors at instance
validation time (it doesn't bother me much, but I agree that it does
bother some intelligent observers), but violations of Conditional
Type Substitutable are not defined as problems with the schema; 

A2: I'm not saying that the spec says it's a problem with the schema. I'm
saying that in practice, it's going to be the schema that has to be fixed. Just
as if you define an assertion that's always false, the schema is technically
correct but in practice unusable; anyone who discovers this is going to
complain to the author of the schema. I'm concerned with the practicality, not
with the letter of the law.

-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
Received on Saturday, 23 April 2011 18:24:19 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 23 April 2011 18:24:20 GMT