bug? in textutil::splitx only first parantheses captured.

From: Klaus Robert Suetterlin From: (krs_at_robert2.mpe-garching.mpg.de)
Date: 07/29/04


Date: Thu, 29 Jul 2004 16:35:15 +0000 (UTC)

I was thinking about a new split variant for tcllib's textutil package
(as proposed by Donald Arseneau). So I checked textutil and found
that it already contained a splitx. I tested it and found it would
not work correct --- as I understand its specification.

It only captures the first parantheses of the separator.

When You do [textutil::splitx "a b c" "( (b) )"] You will get
a [list a { b } c] instead of a [list a { b } b c] as I'd expect.

Is this a feature or a bug?

Regards, Robert S.

P.S.: Of course I did try to create a splitx that captures all
parantheses of the separator correctly. I succeeded, but had some
problems with the regexp command, I will do a separate post on that.