In article <[EMAIL PROTECTED]>,
Ben Finney <[EMAIL PROTECTED]> wrote:
>"Tim Peters" <[EMAIL PROTECTED]> writes:
>> [John Salerno, on the difference between `open` and `file`]
>>>
>>> Interesting. What is the difference between them now?
>>
>> In 2.5 `file` is unchanged but `open` becomes a functi
"Tim Peters" <[EMAIL PROTECTED]> writes:
> [John Salerno, on the difference between `open` and `file`]
> > Interesting. What is the difference between them now?
>
> In 2.5 `file` is unchanged but `open` becomes a function:
>
> >>> file
>
> >>> open
>
In that case I'll happily use 'file()', si
[Tim Peters]
>> In 2.5 `file` is unchanged but `open` becomes a function:
>>
>> >>> file
>>
>> >>> open
>>
[Paul Rubin]
> So which one are we supposed to use?
Use for what? If you're trying to check an object's type, use the
type; if you're trying to open a file, use the function.
>>> type(op
"Tim Peters" <[EMAIL PROTECTED]> writes:
> In 2.5 `file` is unchanged but `open` becomes a function:
>
> >>> file
>
> >>> open
>
So which one are we supposed to use?
--
http://mail.python.org/mailman/listinfo/python-list
Tim Peters wrote:
> [John Salerno, on the difference between `open` and `file`]
>> Interesting. What is the difference between them now?
>
> In 2.5 `file` is unchanged but `open` becomes a function:
>
file
>
open
>
So they are still used in the same way though?
--
http://mail.python
[John Salerno, on the difference between `open` and `file`]
> Interesting. What is the difference between them now?
In 2.5 `file` is unchanged but `open` becomes a function:
>>> file
>>> open
--
http://mail.python.org/mailman/listinfo/python-list
Aahz wrote:
> Python 2.5a2 (trunk:46052, May 19 2006, 19:54:46)
> [GCC 4.0.2 20050808 (prerelease) (Ubuntu 4.0.1-4ubuntu9)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
open is file
> False
>
> Per the other comments in this thread, Guido agreed that mak
In article <[EMAIL PROTECTED]>,
James Stroud <[EMAIL PROTECTED]> wrote:
>Paul McGuire wrote:
>>
>> 1. open("xxx") still works - not sure if it's even deprecated or not - but
>> the new style is to use the file class
>
>Python 2.3.4 (#4, Oct 25 2004, 21:40:10)
>[GCC 3.3.2 (Mandrake Linux 10.0 3.3.