diff options
author | Raymond Hettinger <python@rcn.com> | 2008-03-24 08:17:39 +0000 |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2008-03-24 08:17:39 +0000 |
commit | b72233ce6303aabe7960170f98c5626771751fe7 (patch) | |
tree | e638fa954c0b324468881d6c23433524c33c5023 /Lib/copy.py | |
parent | d145240f9a164e7aea8424c844fe0402aab56454 (diff) | |
download | cpython-git-b72233ce6303aabe7960170f98c5626771751fe7.tar.gz |
Issue 2460: Make Ellipsis objects copyable.
Diffstat (limited to 'Lib/copy.py')
-rw-r--r-- | Lib/copy.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/copy.py b/Lib/copy.py index 35c666f7dc..3f2033f5ff 100644 --- a/Lib/copy.py +++ b/Lib/copy.py @@ -101,7 +101,7 @@ def _copy_immutable(x): return x for t in (type(None), int, long, float, bool, str, tuple, frozenset, type, xrange, types.ClassType, - types.BuiltinFunctionType, + types.BuiltinFunctionType, type(Ellipsis), types.FunctionType): d[t] = _copy_immutable for name in ("ComplexType", "UnicodeType", "CodeType"): @@ -197,6 +197,7 @@ _deepcopy_dispatch = d = {} def _deepcopy_atomic(x, memo): return x d[type(None)] = _deepcopy_atomic +d[type(Ellipsis)] = _deepcopy_atomic d[int] = _deepcopy_atomic d[long] = _deepcopy_atomic d[float] = _deepcopy_atomic |