Anonymous file closing

Sergey Krushinsky lunarium at comail.ru
Fri Jun 11 03:59:58 EDT 2004


Hello all,

If I need to read a string from a file and use syntax like:
text = open(filename, 'r').read()
...
is the file object ever closed?

With best regards,
Sergey




More information about the Python-list mailing list