[Python-checkins] cpython: Issue #17516: remove dead code
victor.stinner
python-checkins at python.org
Tue Mar 26 01:16:04 CET 2013
http://hg.python.org/cpython/rev/9dba3bc7c2a6
changeset: 82959:9dba3bc7c2a6
user: Victor Stinner <victor.stinner at gmail.com>
date: Tue Mar 26 01:14:35 2013 +0100
summary:
Issue #17516: remove dead code
files:
Lib/_pyio.py | 1 -
Lib/sre_compile.py | 7 -------
Lib/test/test_decimal.py | 1 -
3 files changed, 0 insertions(+), 9 deletions(-)
diff --git a/Lib/_pyio.py b/Lib/_pyio.py
--- a/Lib/_pyio.py
+++ b/Lib/_pyio.py
@@ -2054,7 +2054,6 @@
if not isinstance(initial_value, str):
raise TypeError("initial_value must be str or None, not {0}"
.format(type(initial_value).__name__))
- initial_value = str(initial_value)
self.write(initial_value)
self.seek(0)
diff --git a/Lib/sre_compile.py b/Lib/sre_compile.py
--- a/Lib/sre_compile.py
+++ b/Lib/sre_compile.py
@@ -65,13 +65,6 @@
elif op in REPEATING_CODES:
if flags & SRE_FLAG_TEMPLATE:
raise error("internal: unsupported template operator")
- emit(OPCODES[REPEAT])
- skip = _len(code); emit(0)
- emit(av[0])
- emit(av[1])
- _compile(code, av[2], flags)
- emit(OPCODES[SUCCESS])
- code[skip] = _len(code) - skip
elif _simple(av) and op is not REPEAT:
if op is MAX_REPEAT:
emit(OPCODES[REPEAT_ONE])
diff --git a/Lib/test/test_decimal.py b/Lib/test/test_decimal.py
--- a/Lib/test/test_decimal.py
+++ b/Lib/test/test_decimal.py
@@ -290,7 +290,6 @@
global skip_expected
if skip_expected:
raise unittest.SkipTest
- return
with open(file) as f:
for line in f:
line = line.replace('\r\n', '').replace('\n', '')
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list