Hi,

First, thanks all for this good XPath implementation.
I've tried it and I think I've found a bug in substring-after
implementation. 

>From the http://www.w3.org/TR/xpath, 
---------------------------
Function: string substring-after(string, string) 
The substring-after function returns the substring of the first argument
string that follows the first occurrence of the second argument string
in the first argument string, or the empty string if the first argument
string does not contain the second argument string. For example,
substring-after("1999/04/01","/") returns 04/01, and
substring-after("1999/04/01","19") returns 99/04/01.
---------------------------

The current code returns "999/04/01" instead of "99/04/01", it seems
that is due to an error in SubstringAfterFunction.java. The code (line
49) should be :
        return str.substring(loc+match.length());
Instead of 
        return str.substring(loc+1);

Eric

SubstringAfterFunction.java

Reply via email to