[futurebasic] Re: Linked Lists

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : September 1998 : Group Archive : Group : All Groups

From: Rick Brown <rbrown@...>
Date: Wed, 30 Sep 1998 20:07:28 -0500
Waverly wrote:

> I've been programming for years and have only used pointers when IM
> stated that it must be used for a toolbox call.  The only benefit I can
> see in using a pointer would be that I don't have to spend time locking
> and unlocking it.  Outside of this it seems to be a detriment.  If you
> don't allocate your pointers at the beginning of your program then you
> end up fragmenting memory.  I say this based on this supposition:   The
> intent of using a pointer is to permanently allocate memory during the
> entire life of the program.

In my post about "pointers" to the data elements in a linked list, I was
using the word "pointer" in the generic sense, meaning "a long integer
containing the address of some (any) useful chunk of memory."  The kinds
of pointers you're talking about are those which specifically point to a
thing called a "non-relocatable block," which is a special kind of data
structure managed by the Memory Manager.

In the _generic_ sense, you'll find yourself using pointers all the
time: for example whenever you use syntax like "@myVar" you're using a
pointer--it's just not a pointer to a non-relocatable memory block, and
it's not handled by the Memory Manager.

- Rick