Author: Brian Kearns <[email protected]>
Branch: use-file-star-for-file
Changeset: r73153:c0e3a6041194
Date: 2014-08-29 01:23 -0400
http://bitbucket.org/pypy/pypy/changeset/c0e3a6041194/

Log:    kill unused code

diff --git a/pypy/module/_file/interp_file.py b/pypy/module/_file/interp_file.py
--- a/pypy/module/_file/interp_file.py
+++ b/pypy/module/_file/interp_file.py
@@ -33,7 +33,6 @@
     softspace= 0     # Required according to file object docs
     encoding = None
     errors   = None
-    fd       = -1
     cffi_fileobj = None    # pypy/module/_cffi_backend
 
     newlines = 0     # Updated when the stream is closed
@@ -62,16 +61,6 @@
         self.binary = "b" in mode
         getopenstreams(self.space)[stream] = None
 
-    def check_not_dir(self, fd):
-        try:
-            st = os.fstat(fd)
-        except OSError:
-            pass
-        else:
-            if (stat.S_ISDIR(st[0])):
-                ose = OSError(errno.EISDIR, '')
-                raise wrap_oserror_as_ioerror(self.space, ose, self.w_name)
-
     def check_mode_ok(self, mode):
         if (not mode or mode[0] not in ['r', 'w', 'a', 'U'] or
             ('U' in mode and ('w' in mode or 'a' in mode))):
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to