String pooling

Python itself contains an implementation of this, which it uses for
attributes and variable names. Take a look at the builtin function
intern().

···

On Wed, Aug 11, 2004 at 08:00:17PM -0500, Chris Mellon wrote:

I have an application that needs to store a log buffer of up hundreds
of thousands of lines, many of which may be identical. Does anyone
know of any implementations of string pooling I might be able to use
to cut the memory footprint for this down to something reasonable?

--
Tim Lesher <tim@lesher.ws>
http://www.lesher.ws