W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > July to September 2004

1.1 FPWD: error in derived-from-duration regexes

From: Dave Peterson <davep@iit.edu>
Date: Tue, 7 Sep 2004 10:38:37 -0400
Message-Id: <a05210635bd6376ab8a68@[192.168.0.2]>
To: www-xml-schema-comments@w3.org

Ashok has caused me to look closely at the regex given in the text
of each derived-from-duration datatype, and I find that I forgot
to escape the '-' and '.' characters.  They should be escaped:

    \-?P([0-9]+D)?(T([0-9]+H)?([0-9]+M)?([0-9]+(\.[0-9]+)?S)?)?

    \-?P([0-9]+Y)?([0-9]+M)?

for dayTimeDuration and yearMonthDuration respectively.

(Note that these regexes by themselves do not exactly define the
lexical spaces of their respective datatypes, but they do provide
an adequate regex for use in derivation from duration.  Exact
regexes would be messier; compare the regex for duration itself.)
-- 
Dave Peterson
SGMLWorks!

davep@iit.edu
Received on Tuesday, 7 September 2004 14:38:41 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 5 February 2014 23:39:42 UTC