Commit 1c760cab authored by Serhiy Storchaka's avatar Serhiy Storchaka

Issue #19426: Fixed the opening of Python source file with specified encoding.

parent 712e951f
No related merge requests found
...@@ -125,7 +125,7 @@ def coding_spec(str): ...@@ -125,7 +125,7 @@ def coding_spec(str):
Raise LookupError if the encoding is declared but unknown. Raise LookupError if the encoding is declared but unknown.
""" """
# Only consider the first two lines # Only consider the first two lines
str = str.split("\n", 2)[:2] lst = str.split("\n", 2)[:2]
for line in lst: for line in lst:
match = coding_re.match(line) match = coding_re.match(line)
if match is not None: if match is not None:
......
...@@ -12,6 +12,11 @@ Core and Builtins ...@@ -12,6 +12,11 @@ Core and Builtins
Library Library
------- -------
IDLE
----
- Issue #19426: Fixed the opening of Python source file with specified encoding.
What's New in Python 2.7.6 release candidate 1? What's New in Python 2.7.6 release candidate 1?
=============================================== ===============================================
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment