Commit db844ea9 authored by Jeremy Hylton's avatar Jeremy Hylton

Explicit assignment of __module__ to classes, so that we don't catch

types that grow an __module__ in future versions of Python.
parent c33a7a79
...@@ -17,6 +17,5 @@ from _IIBTree import * ...@@ -17,6 +17,5 @@ from _IIBTree import *
# We don't really want _ names in pickles, so update all of the __module__ # We don't really want _ names in pickles, so update all of the __module__
# references. # references.
##for o in globals().values(): for obj in IIBucket, IIBTree, IISet, IITreeSet:
## if hasattr(o, '__module__'): obj.__module__ = __name__
## o.__module__=__name__
...@@ -17,6 +17,5 @@ from _IOBTree import * ...@@ -17,6 +17,5 @@ from _IOBTree import *
# We don't really want _ names in pickles, so update all of the __module__ # We don't really want _ names in pickles, so update all of the __module__
# references. # references.
##for o in globals().values(): for obj in IOBucket, IOBTree, IOSet, IOTreeSet:
## if hasattr(o, '__module__'): obj.__module__ = __name__
## o.__module__=__name__
...@@ -17,6 +17,5 @@ from _OIBTree import * ...@@ -17,6 +17,5 @@ from _OIBTree import *
# We don't really want _ names in pickles, so update all of the __module__ # We don't really want _ names in pickles, so update all of the __module__
# references. # references.
for o in globals().values(): for obj in OIBucket, OIBTree, OISet, OITreeSet:
if hasattr(o, '__module__'): obj.__module__ = __name__
o.__module__=__name__
...@@ -17,6 +17,5 @@ from _OOBTree import * ...@@ -17,6 +17,5 @@ from _OOBTree import *
# We don't really want _ names in pickles, so update all of the __module__ # We don't really want _ names in pickles, so update all of the __module__
# references. # references.
for o in globals().values(): for obj in OOBucket, OOBTree, OOSet, OOTreeSet:
if hasattr(o, '__module__'): obj.__module__ = __name__
o.__module__=__name__
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment