[Python-Dev] Re: Alternative implementation of string interning
Ka-Ping Yee
ping@zesty.ca
Wed, 3 Jul 2002 03:14:33 -0700 (PDT)
On Wed, 3 Jul 2002, Oren Tirosh wrote:
> > It appears that what you are proposing is what interned string
> > comparison already does (since == checks for pointer equality first).
>
> But INequality checking may still require strcmp. Inverse logic again.
I never claimed it wouldn't. All i'm saying is that string comparison
already does this: compare pointers, then if not equal, compare strings.
> > So, the only observable effect of the change would be to break all
> > code that tests for type(s) == str.
>
> Yes, that's certainly a problem.
But you haven't responded to my point. Would there be *any* effect
other than breakage?
-- ?!ng