Connecting Tech Pros Worldwide Forums | Help | Site Map

garbage collector c++

Charles T.
Guest
 
Posts: n/a
#1: Aug 19 '05
Hi,

looking for advance article/books on garbage-collected allocation.

thanks, Charles.



Frank Chang
Guest
 
Posts: n/a
#2: Aug 19 '05

re: garbage collector c++


Charles, Which compiler are you using gcc or Microsoft Visual
Studio.net 2003 or Microsoft Visual Studio.net 2005? .NET 2005 allows
the programmer to create objects that are swept away by the .NET
garbage collector. Unix gcc also has garbage collection. Each compiler
uses different types of garbage collection algorithms. But these
garbage collection alogorithms will not prevent all memory leaks. I
would recommend first reading about the general concepts of garbage
collection independent of the language (C++,Java/Scheme, etc).

Frank Chang
Guest
 
Posts: n/a
#3: Aug 19 '05

re: garbage collector c++


Charles, I should preface my earlier comments about Visual Studio .NET
2005 garbage collection by saying this only applies to managed C++
which is used by the .NET CLR. For unmanaged C++ code, it is still best
to define and implement C++ destructors.

Dave Townsend
Guest
 
Posts: n/a
#4: Aug 20 '05

re: garbage collector c++



"Charles T." <rosmarcha@yahoo.com> wrote in message
news:OAkNe.14975$yN.289529@wagner.videotron.net...[color=blue]
> Hi,
>
> looking for advance article/books on garbage-collected allocation.
>
> thanks, Charles.
>
>[/color]
I saw this one in my local bookshop, Garbage Collection : Algorithms for
Automatic Dynamic Memory Management Richard Jones, Rafael Lins

http://www.amazon.com/exec/obidos/tg...books&n=507846


Vijai Kalyan
Guest
 
Posts: n/a
#5: Aug 20 '05

re: garbage collector c++


http://www.iecc.com/gclist/GC-faq.html

Try this.

-vijai.

Dan Cernat
Guest
 
Posts: n/a
#6: Aug 24 '05

re: garbage collector c++



"Frank Chang" <FrankChang91@gmail.com> wrote in message
news:1124462795.321480.93260@z14g2000cwz.googlegro ups.com...[color=blue]
> Charles, I should preface my earlier comments about Visual Studio .NET
> 2005 garbage collection by saying this only applies to managed C++
> which is used by the .NET CLR. For unmanaged C++ code, it is still best
> to define and implement C++ destructors.
>[/color]

How would a C++ destructor help in the program below?

int main()
{
char* myArray = new char[100];

// delete[] my array; // commented out
return 0;
}

Duh!

dan



Closed Thread