summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVladimir Rudnyh <rudnyh@corp.mail.ru>2014-05-10 01:08:42 +0400
committerVladimir Rudnyh <rudnyh@corp.mail.ru>2014-05-10 01:09:53 +0400
commitb2b195efa62d1465b753b7c9bf8e62793f0b6b01 (patch)
tree58725ff12c652c2849e143e77922cca95dccc355
parent2e8e47168d53e2dc11d904eabc3a84e0d43a699c (diff)
downloadpep8-b2b195efa62d1465b753b7c9bf8e62793f0b6b01.tar.gz
Always open files with universal newline flag
-rwxr-xr-xpep8.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pep8.py b/pep8.py
index 0d7e294..92042fb 100755
--- a/pep8.py
+++ b/pep8.py
@@ -1037,7 +1037,7 @@ if '' == ''.encode():
# Python 2: implicit encoding.
def readlines(filename):
"""Read the source code."""
- with open(filename) as f:
+ with open(filename, 'rU') as f:
return f.readlines()
isidentifier = re.compile(r'[a-zA-Z_]\w*').match
stdin_get_value = sys.stdin.read