W3C home > Mailing lists > Public > public-qt-comments@w3.org > September 2003

RE: [xslt2 func/op] tokenizing "abba" to ("a","b","b","a")

From: Ashok Malhotra <ashokma@microsoft.com>
Date: Mon, 22 Sep 2003 15:43:51 -0700
Message-ID: <E5B814702B65CB4DA51644580E4853FB0ADB399F@red-msg-12.redmond.corp.microsoft.com>
To: "Tobias Reif" <tobiasreif@pinkjuice.com>, <public-qt-comments@w3.org>
Cc: "Jeni Tennison" <jeni@jenitennison.com>

The WGs discussed this issue in the meeting on 9/16/2003.  We agreed
that the description of fn:tokenize was ambiguous and decided to clarify
it by making it an error for the pattern to match the zero-length
string.   

All the best, Ashok

> -----Original Message-----
> From: Tobias Reif [mailto:tobiasreif@pinkjuice.com]
> Sent: Monday, August 18, 2003 3:13 PM
> To: public-qt-comments@w3.org
> Cc: Ashok Malhotra; Jeni Tennison
> Subject: Re: [xslt2 func/op] tokenizing "abba" to ("a","b","b","a")
> 
> Hi Ashok
> 
>  > Yes, but the spec says that if reluctant quantifiers are used, i.e.
>  > those with ?, then the regex "matches the shortest possible
substring
>  > consistent with the match as a whole succeeding."
> 
> I see (there are a lot of specs to read ...).
> 
> 1.
> 
> I think the example in the spec can confuse.
> 
> Why use
>   fn:tokenize("abba", ".?") returns ("a", "b", "b", "a")
> and not (add)
>   fn:tokenize("abba", "") returns ("a", "b", "b", "a")
> ?
> 
> 2.
> 
> What should
>   fn:tokenize("abba", ".")
> return?
> (Not sure if it's ("","","","",""))
> Perhaps it would be a useful example.
> 
> 3.
> 
> You also might want to consider adding an example where the pattern
> matches something in the input and an empty sequence is returned, if
> there are such cases.
> 
> Tobi
> 
> 
> --
> http://www.pinkjuice.com/
> 
Received on Monday, 22 September 2003 18:43:54 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:14:27 GMT