Page 2 of 2
Re: List/Map in Structure - recursion error
Posted: Fri Apr 23, 2010 11:07 am
by Kiffi
Fred wrote:Removed for List and Map.
Greetings ... Kiffi
Re: List/Map in Structure - recursion error
Posted: Fri Apr 23, 2010 11:16 am
by NicTheQuick
Juhuu! ...eehm... Yeah!
Re: List/Map in Structure - recursion error
Posted: Fri Apr 23, 2010 11:23 am
by srod
Now that beta 3 is upon us I've been having a real crack at embedding lists/maps within structures. I've nested them 3 deep (structure contains a map of structures each of which contains a list of structures, each of which...)
Seems pretty solid right now. ForEach worked fine with the various levels.
In a word, absolutely bloody awesome! Okay, that was 3 words, but 1 simply wasn't enough.

There is some serious work there behind the scenes by the compiler to get all of this working!
Thanks Fred/Timo.
Re: List/Map in Structure - recursion error
Posted: Fri Apr 23, 2010 3:05 pm
by Little John
srod wrote:absolutely bloody awesome!
I couldn't have said it better.

Thanks a lot, Fred and Timo, for the new powerful possibilities for creating trees and similar data structures!
Regards, Little John
Re: List/Map in Structure - recursion error
Posted: Sat Apr 24, 2010 2:07 am
by freak
Re: List/Map in Structure - recursion error
Posted: Sat Apr 24, 2010 11:19 am
by Fred
It worth noting than you can call FreeArray(), FreeList(), FreeMap(), or even ClearStructure() right after the structure creation if you want the behaviour "structure not initialized by default". The NewList, Dim and NewMap() will have to be called on demand.
Re: List/Map in Structure - recursion error
Posted: Sat Apr 24, 2010 12:14 pm
by freak
Fred wrote:It worth noting than you can call FreeArray(), FreeList(), FreeMap(), or even ClearStructure() right after the structure creation if you want the behaviour "structure not initialized by default". The NewList, Dim and NewMap() will have to be called on demand.
Added a note to the post as well.