[futurebasic] Re: [FB] re: XREF vs Growing your own

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

From: jonathan <jonathan@...>
Date: Jeu, 26 Nov 98 10:40:31 +0100
>I like XREF.  You still have to make your own handles.  It just allow
>you to pretend that the handle is an array.  I build arrays of records
>using XREF and it makes life much easier.

I agree with the why, but for the how...

I define a record...
DIM RECORD testRec
 DIM testFirstEntry%
 DIM testSecondEntry&
 DIM 25 testThirdEntry$
DIM END RECORD.testRec

Then I use ( 3*_testRec + _testThirdEntry) type constructions
the put and get the info in the handle. This seems as intuitive
as I need. I'm not saying XREFs is not good, just that they
seem to create confusion (would they be a hangover from a
time when there was no support for handles and pointers in FB?)
and thus I have never perceived that the gain I could obtain
from using them would exceed the investment in time and grey
matter to grok and debug the little thingies (This is of course
a reflection on the bad quality of my grey matter, not on XREF,
but my point was that if others have similar 'conceptual' problems
with XREF, there are other techniques...)

jonathan