- From: <bugzilla@wiggum.w3.org>
- Date: Tue, 06 Nov 2007 00:24:24 +0000
- To: public-qt-comments@w3.org
- CC:
http://www.w3.org/Bugs/Public/show_bug.cgi?id=5251
Summary: [FO] Minimal match in starts-with(), ends-with()
Product: XPath / XQuery / XSLT
Version: Recommendation
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: normal
Priority: P2
Component: Functions and Operators
AssignedTo: mike@saxonica.com
ReportedBy: mike@saxonica.com
QAContact: public-qt-comments@w3.org
The rules for starts-with say that the value of $arg1 must start with a
sequence of collation units that provides a minimal match to the collation
units of $arg2.
Consider starts-with(" banana", " b") where space is an ignorable collation
unit. There is a match at the start of the string, but it is not a minimal
match. The first minimal match starts at the second character, "b". It
therefore seems that starts-with() should return false. This is
counter-intuitive, and surely not what the working group intended.
The same applies to ends-with(). I don't think that the other
substring-matching functions (contains, substring-before, substring-after) have
similar problems.
Received on Tuesday, 6 November 2007 00:24:31 UTC