Robert Klemme wrote:

> I guess the OP won't like it because the whitespace is not separated
> properly.  And he wanted to be able to provide the tokens conveniently.
> Another solution, which can of course be tweaked and integrated into
String:
> ...

Nice solution, but my idea of specifying your tokens is to have it separate
before and after each token. I don't want to have to specify everything I'm
looking for. Just the significant tokens. Sometimes whitespace is
significant:

'a = "    this is a string    "'.tokenize('"', "=")

should produce:

["a", " ", "=", " ", "\"", "    this is a string    ", "\""]

___________________
John Long
www.wiseheartdesign.com