diff options
author | Barry Warsaw <barry@python.org> | 2003-02-08 03:18:58 (GMT) |
---|---|---|
committer | Barry Warsaw <barry@python.org> | 2003-02-08 03:18:58 (GMT) |
commit | 9914227caa4f25b7442ea82cd6feab68821bb011 (patch) | |
tree | a26c22ef86bb8379b60d8c6ec4e6979ba8d1d041 /Lib/bsddb/dbobj.py | |
parent | 07534a607bd3d2fd232323811a83279acda10885 (diff) | |
download | cpython-9914227caa4f25b7442ea82cd6feab68821bb011.zip cpython-9914227caa4f25b7442ea82cd6feab68821bb011.tar.gz cpython-9914227caa4f25b7442ea82cd6feab68821bb011.tar.bz2 |
Fix compatibility for earlier versions of Python (than 2.3), which
doesn't have UserDict.DictMixin.
Diffstat (limited to 'Lib/bsddb/dbobj.py')
-rw-r--r-- | Lib/bsddb/dbobj.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Lib/bsddb/dbobj.py b/Lib/bsddb/dbobj.py index f274d56..889e554 100644 --- a/Lib/bsddb/dbobj.py +++ b/Lib/bsddb/dbobj.py @@ -16,7 +16,12 @@ # import db -from UserDict import DictMixin + +try: + from UserDict import DictMixin +except ImportError: + # DictMixin is new in Python 2.3 + class DictMixin: pass class DBEnv: def __init__(self, *args, **kwargs): |