mirror of https://github.com/python/cpython.git
Don't die if CodeType doesn't exist -- ignore the error. This could
happen in restricted mode.
This commit is contained in:
parent
7999bfb235
commit
2fff84d892
|
@ -85,7 +85,10 @@ def _copy_atomic(x):
|
|||
d[types.LongType] = _copy_atomic
|
||||
d[types.FloatType] = _copy_atomic
|
||||
d[types.StringType] = _copy_atomic
|
||||
d[types.CodeType] = _copy_atomic
|
||||
try:
|
||||
d[types.CodeType] = _copy_atomic
|
||||
except AttributeError:
|
||||
pass
|
||||
d[types.TypeType] = _copy_atomic
|
||||
d[types.XRangeType] = _copy_atomic
|
||||
d[types.ClassType] = _copy_atomic
|
||||
|
|
Loading…
Reference in New Issue