Chris Angelico wrote:

> On Thu, May 28, 2020 at 5:54 PM Peter Otten <__pete...@web.de> wrote:

>> But at least now you have two -- elegant or gross -- hacks to choose from
>> ;)
>>
> 
> Yeah, I thought of this originally as a challenge in redefining the
> concept of "length". But the trouble is that it might not always be
> the len() function that figures out the length - there might be a
> regex with a size threshold or any number of other things that
> effectively think about the length of the string.

So start with your hack, and if the pain becomes too hard do it right, 
perhaps making TextWrapper a bit more intelligible in the process.

-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to