File operations
Fredrik Lundh
fredrik at pythonware.com
Fri Aug 22 03:18:09 EDT 2008
John Machin wrote:
> and don't use the name of the built-in file function as one of your
> own names
"file" is a type, not a function, and has been removed in 3.0.
given that "file" is hardly ever used in properly written Python 2 code
(if you need to check for file-like behaviour in Python 2, check for the
relevant attributes), assigning to "file" is a lot less problematic than
assigning to "len" or "str" or "open" etc.
</F>
More information about the Python-list
mailing list