|
|
Darren New <dne### [at] sanrrcom> wrote:
> John VanSickle wrote:
> > You can always override the new and delete operators for a class so that
> > garbage collection becomes unnecessary,
> You know, I keep asking for people to show me an example of that, and I
> don't see any examples. :-) They all fall down as soon as you get enough
> complexity in the data structure.
The next C++ standard will commit a big sin and will define the concept
of garbage collection in C++. They couldn't resist the hype, I suppose... :P
Seriously, though, it will actually be a great thing. It will be optional
(ie. GC is not shoved down your throat by force) and even if you use it you
can still destroy things explicitly (eg. because some resource needs to be
freed right now and not tomorrow), and it will obviously not affect the
lifetime of local instances.
--
- Warp
Post a reply to this message
|
|