[Info-vax] DEC Basic and dynamic memory ?

Simon Clubley clubley at remove_me.eisner.decus.org-Earth.UFP
Fri Jan 28 14:57:26 EST 2022


On 2022-01-28, Dave Froble <davef at tsoft-inc.com> wrote:
> On 1/28/2022 12:31 PM, John Reagan wrote:
>> 4) As we've discussed the BASIC cross-compiler is still not available due to G2L not being
>> able to totally handle how the BASIC MAP statement is described to GEM.  The GEM to
>> LLVM module for common blocks is radically different.  Could you write a DIRECTORY
>> replacement in BASIC without using MAP?
>
> Why, yes, I'm rather sure I could.  For example, from one of my routines:
>
>          RECORD FABBLK                                   !
>          RECORD NAMBLK                                   !
>          RECORD FIBBLK                                   !  FIB structure
>
> And now I'm waiting for you to say that the Basic RECORD statement has the same 
> problems as MAP.
>

How easy is it in DEC Basic to build a tree of (say) 1000 nodes of
a custom data structure in dynamic memory and then walk the tree
either depth-first or breadth-first ?

I've had a quick look at the dynamic storage section of the DEC Basic user
manual, but I don't see how you link a set of nodes together into a tree.
However, as mentioned previously, I don't know DEC Basic and searching
for the word pointer didn't reveal anything appropriate, so I assume
it's another keyword I am not aware of.

In addition, how easy is this to do if the nodes are not all of the
same record type, but have a common tag at the start of each record
to say what kind of record it actually is ? I see you have variant
records in DEC Basic. Do they also work in a dynamic memory based
tree structure ?

Simon.

-- 
Simon Clubley, clubley at remove_me.eisner.decus.org-Earth.UFP
Walking destinations on a map are further away than they appear.


More information about the Info-vax mailing list