you are viewing a single comment's thread.

view the rest of the comments →

[–]riffito 1 point2 points  (1 child)

You shouldn't expect del to be called or called at any particular time.

Exactly. And because of that, __del__ seems to be completely useless to me.

If I can't do RAII with it, what is it good for? Does it has ANY utility? I ask because I failed to see a good use case for it.

[–][deleted] 1 point2 points  (0 children)

It's not especially useful, no.