RE: I'd appreciate a second-look at this, just to double-check

Michael Kay writes:

>> So it's one of those cases where an 
>> implementor has to choose between doing
>> what the spec says and doing what it means.

Hmm.  I'd respectfully dissagree on that.  In this case, I think the spec 
means what it says, and to be conforming an implementation MUST do what 
the spec says, unappealing as that may be.    The history, as I recall, 
was that we wanted two things that weren't provably achievable together:

1) The simple restriction is subsumption semantic that we'd all like to 
believe is the essence of restriction.
2) A spec that would be implementable with reasonable effort and 
reasonable performance

At the time we did Schema Version 1.0, there were long debates as to 
whether anyone knew how to actually achieve (1) in closed form in an 
implementation.   Clearly subsumption checking is understood for a variety 
of simple regular expression languages, but we did not feel that we had 
the analysis in hand for the particular content models offered by schema. 
Explicit occurrence counts and namespace-aware wildcards were among the 
problematic constructs.  Accordingly, we were not confident that we could 
specify (1) and still achieve (2).

So, for those reasons, we chose the more cumbersome and explicit muti-step 
check.  Many of the shortcomings of those particular rules were known at 
the time of the decision, IMO, and some emerged later.  Nonetheless, I 
would say that the specification represents a conscious decision of the WG 
not to call for generalized subsumption.  So, you might say that XSV and 
similar implementations due what the spec writers gave up on being able to 
do, but I really don't want to promote such implementations as conforming 
to "what the spec means".  To be conforming, you MUST implement the checks 
called for in the specification.

The good news is that such implementations may well be conforming to the 
Schema 1.1 rules.  In the intervening years sufficient progress has been 
made that many of us are convinced that specifying (1) is indeed 
consistent with (2).   I expect Schema 1.1 will therefore define 
restriction as a simple subsumption check.

--------------------------------------
Noah Mendelsohn 
IBM Corporation
One Rogers Street
Cambridge, MA 02142
1-617-693-4036
--------------------------------------

Received on Thursday, 4 November 2004 17:58:04 UTC