substring-before and substring-after

I was looking at these two functions and I have a question about the
implementation of this. Specifically I'm wondering why you chose to make
both return an empty string if the substring string does not occure within
the main string. It seems to me to make more sense for substring-before to
return the main string if the substring does not occur within the main
string. That is the following should always be true:
<<Some String>> = concat(substring-before(<<Some String>>, <<Some
Substring>>) , <<Some Substring>>, substring-after(<<Some String>>, <<Some
Substring>>))

Additionally, it would be nice to have an indexof function so that the
substring function can have some intelligent meaning.

> Adam van den Hoven
> Internet Application Developer
> Blue Zone
> tel. 604.685.4310
> fax. 604.685.4391
> Blue Zone makes you interactive.(tm) http://www.bluezone.net/
> 

Received on Monday, 5 March 2001 13:26:35 UTC