[Python-checkins] cpython: unittest.mock: removed another bit of Python 2 only code
michael.foord
python-checkins at python.org
Mon Mar 26 00:27:08 CEST 2012
http://hg.python.org/cpython/rev/f8d01c8baf6a
changeset: 75939:f8d01c8baf6a
user: Michael Foord <michael at voidspace.org.uk>
date: Sun Mar 25 23:27:12 2012 +0100
summary:
unittest.mock: removed another bit of Python 2 only code
files:
Lib/unittest/mock.py | 6 ------
1 files changed, 0 insertions(+), 6 deletions(-)
diff --git a/Lib/unittest/mock.py b/Lib/unittest/mock.py
--- a/Lib/unittest/mock.py
+++ b/Lib/unittest/mock.py
@@ -1086,12 +1086,6 @@
patching.__exit__(*exc_info)
patched.patchings = [self]
- if hasattr(func, 'func_code'):
- # not in Python 3
- patched.compat_co_firstlineno = getattr(
- func, "compat_co_firstlineno",
- func.func_code.co_firstlineno
- )
return patched
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list