Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: schema for XHTML 1.0

From: "C. M. Sperberg-McQueen" <cmsmcq@---.--->
To: Wolfgang Jeltsch <wolfgang@-------.--->
Date: 9/15/2006 2:07:00 PM

On 15 Sep 2006, at 13:36 , Wolfgang Jeltsch wrote:

> ...
> 	[1]
> 	cannot derive simpleType by restriction: "([-+]?(\d+|\d+(\.\d+)?%) 
> (,\s*[-+]?
> 	(\d+|\d+(\.\d+)?%))*)" invalid value for pattern facet: character  
> "-" must be
> 	escaped with "\" in this context [st-props-correct.1]
>
> 	[2]
> 	cannot derive simpleType by restriction: "([-+]?(\d+|\d+(\.\d+)? 
> %))" invalid
> 	value for pattern facet: character "-" must be escaped with "\" in  
> this
> 	context [st-props-correct.1]
>
> 	[3]
> 	cannot derive simpleType by restriction: "([-+]?(\d+|\d+(\.\d+)?%)| 
> [1-9]
> 	(\d+)?\*)" invalid value for pattern facet: character "-" must be  
> escaped
> 	with "\" in this context [st-props-correct.1]
>
> What's the reason for this?  Is escaping the - characters enough to  
> get a
> correct schema?

As Michael Kay has noted, the first edition of the spec had an error
(ambiguity in the grammar, if I remember correctly), which the Working
Group fixed in an erratum by requiring that hyphens be escaped in
the context shown here.  When the Proposed Edited Recommendation
for XML Schema 1.0 Second Edition was published, there was a
comment arguing that the erratum was unnecessary and badly done,
and proposing a less problematic way to repair the original problem.
On consideration, the Working Group agreed with that comment, and
made another correction.

It is (or should be, if the grammar is now correct) unnecessary to  
escape
the hyphens above.  But it should also be harmless to do so (and to be
honest I thought the HTML Working Group had drawn the obvious
conclusion and put the escapes in, since doing so would mean the
schema had a better chance of working with all processors -- are you
sure you're working with the most recent schema documents for the
XHTML namespace?).

I hope this helps.

--Michael Sperberg-McQueen


From cmsmcq@a... Sat Sep 16 02:51:54 2006
Received: from lisa.w3.org ([128.30.52


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent