]> granicus.if.org Git - python/commitdiff
Change string exceptions to class exceptions.
authorGuido van Rossum <guido@python.org>
Thu, 29 Jun 2000 16:15:52 +0000 (16:15 +0000)
committerGuido van Rossum <guido@python.org>
Thu, 29 Jun 2000 16:15:52 +0000 (16:15 +0000)
Lib/pickle.py

index ebfde4f1a0c91e4fb2ff4c0b2e9baada8b4021b9..6c1bcbeae554ebe437d92a7afa742fbf0be5a89b 100644 (file)
@@ -38,8 +38,9 @@ compatible_formats = ["1.0", "1.1", "1.2"] # Old format versions we can read
 mdumps = marshal.dumps
 mloads = marshal.loads
 
-PicklingError = "pickle.PicklingError"
-UnpicklingError = "pickle.UnpicklingError"
+class PickleError(Exception): pass
+class PicklingError(PickleError): pass
+class UnpicklingError(PickleError): pass
 
 try:
     from org.python.core import PyStringMap