31 Aug
2005
31 Aug
'05
5:36 p.m.
Fredrik Lundh wrote:
the problem isn't the time it takes to unpack the return value, the problem is that it takes time to create the substrings that you don't need.
I'm actually starting to think that this may be a good use case for views of strings i.e. rather than create 3 new strings, each "string" is a view onto the string that was partitioned. Most of the use cases I've seen, the partitioned bits are discarded almost as soon as the original string, and often the original string persists beyond the partitioned bits. Tim Delaney