Re: delete this
From: Ioannis Vranos (ivr_at_guesswh.at.emails.ru)
Date: 04/14/04
- Next message: Julie: "Re: How to initialize a char*?"
- Previous message: David Harmon: "Re: Does your favorite C++ compiler support 64-bit integer types?"
- In reply to: Allan Bruce: "delete this"
- Next in thread: Julie: "Re: delete this"
- Reply: Julie: "Re: delete this"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Wed, 14 Apr 2004 03:00:37 +0300
"Allan Bruce" <allanmb@TAKEAWAYf2s.com> wrote in message
news:c5h2su$90g$1@news.freedom2surf.net...
> Is it ok to delete a class from within one of is own methods? It works on
> VC7 but I want to know if this is generally or portably ok.
No it is not. Always delete an object from the outside and place any cleanup
of resources you may use in the class at the destructor.
Ioannis Vranos
- Next message: Julie: "Re: How to initialize a char*?"
- Previous message: David Harmon: "Re: Does your favorite C++ compiler support 64-bit integer types?"
- In reply to: Allan Bruce: "delete this"
- Next in thread: Julie: "Re: delete this"
- Reply: Julie: "Re: delete this"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]