matz at netlab.co.jp
Tue Jun 1 08:41:23 CEST 1999
"Vadim Chugunov" <chega_ at yahoo.com> writes:
|> Remember the original statement is like this:
|> >As many people have noted before, you would not be able to use
|> >destructors to free up resources like memory or file descriptors.
|>which, as I understand, means destructors can not be used with real
|>GC. That's just not true.
|I'm sorry for being unclear, but the key words here were: "to free up
|And I meant "to free up resources the moment I expect them to", not "some time
Well, OK. I understand now. Now only thing I can say is, why do you
emphasize so much on reclaiming object at the time you exepcted?
Because of your C++ background?
|BTW, this is a common expectation from anyone coming from a C++ background.
|In C++, deallocation in destructors is the only way you can use exceptions
|without leaking resources.
Yes, but it's not true for HIGHER languages like Python or Java (or Ruby).
More information about the Python-list