]> granicus.if.org Git - python/commitdiff
Issue #19426: Fixed the opening of Python source file with specified encoding.
authorSerhiy Storchaka <storchaka@gmail.com>
Tue, 29 Oct 2013 08:15:09 +0000 (10:15 +0200)
committerSerhiy Storchaka <storchaka@gmail.com>
Tue, 29 Oct 2013 08:15:09 +0000 (10:15 +0200)
Lib/idlelib/IOBinding.py
Misc/NEWS

index 2eae11b5411bcdeea982ea899b0ce7d9fa5fdac6..f6de4409ddaa3d74f80ec9fc49a965af94801a4d 100644 (file)
@@ -125,7 +125,7 @@ def coding_spec(str):
     Raise LookupError if the encoding is declared but unknown.
     """
     # Only consider the first two lines
-    str = str.split("\n", 2)[:2]
+    lst = str.split("\n", 2)[:2]
     for line in lst:
         match = coding_re.match(line)
         if match is not None:
index c8cf58585ca2eeeb3b18c1a295b9e63431792c2b..f3b979931bc191d76a66cbd31feb31d0b2c143f8 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -12,6 +12,11 @@ Core and Builtins
 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?
 ===============================================