On Aug 18, 1:44 am, James Kanze wrote:
> On Aug 17, 6:21 pm, Standish P wrote:
>
> > > Garbage collection doesn't use a stack. It uses a "heap",
> > > which is in the abstract a collection of memory blocks of
> > > different lengths, divided into two lists, generally
> > > represented as linked l
On Aug 18, 1:21 am, Standish P wrote:
> > Garbage collection doesn't use a stack. It uses a "heap", which is in
> > the abstract a collection of memory blocks of different lengths,
> > divided into two lists, generally represented as linked lists:
>
> > 1. A list of blocks that are free and may b
On Aug 16, 7:20 pm, Malcolm McLean
wrote:
> On Aug 16, 10:20 am, Standish P wrote:> [Q] How far can
> stack [LIFO] solve do automatic garbage collection and
> > prevent memory leak ?
>
> Most programs can be written so that most of their memory allocations
> are matched by destructors at the sam
On Aug 16, 3:20 pm, Standish P wrote:
> [Q] How far can stack [LIFO] solve do automatic garbage collection and
> prevent memory leak ?
>
> Because a stack has push and pop, it is able to release and allocate
> memory. We envisage an exogenous stack which has malloc() associated
> with a push and f