
-----------------------------------
corriep
Sat Jan 10, 2009 1:31 pm

Flexible arrays in a record
-----------------------------------
Like the title says is there a way to have a flexible array in a record

like this :


type foo :
    record
        bar : flexible array 1 .. 0 of int
    end record


-----------------------------------
Saad
Sun Jan 11, 2009 6:48 pm

Re: Flexible arrays in a record
-----------------------------------
There is no direct way to my knowledge, however if you know how to use classes in Turing what you can do is create a flexible array class which wraps a flexible array. An object of the class inside the record will then be possible. If you do not know how to use classes and you want to learn, there are tutorials linked to in the Classes Part I/II/III. (Note I will probably be all that you need.)

[url=http://compsci.ca/v3/viewtopic.php?t=16293]This topic is where I posted a flexible array class a while ago. The topic relates also relates to your question in a way.

Enjoy :)

-----------------------------------
corriep
Mon Jan 12, 2009 9:57 pm

RE:Flexible arrays in a record
-----------------------------------
Thanks for the help, I found a work around for this and im actually glad I did, I'll be sure to remember this for the future
