when to use intern()
Gregory Trubetskoy
grisha at ispol.com
Thu Apr 27 08:25:06 EDT 2000
More information about the Python-list mailing list
Thu Apr 27 08:25:06 EDT 2000
- Previous message (by thread): accessing BLT vectors from C
- Next message (by thread): when to use intern()
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
It says in the manual that some things in Python get interned
automatically. I'm not sure where intern() is necessary -
if I have a statement like:
if self.config.has_key("PythonOption"):
...
that gets executed a lot - should I consider interning "PythonOption" or
is it done automatically?
what about
PYTHON_OPTION = "PythonOption"
if self.config.has_key(PYTHON_OPTION):
...
is this interned?
Thanks!
--
Gregory (Grisha) Trubetskoy
grisha at ispol.com
- Previous message (by thread): accessing BLT vectors from C
- Next message (by thread): when to use intern()
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list