--- In [email protected], "brucexs" <[EMAIL PROTECTED]> wrote: > > > > > It's the vector handle. There are problems even if I take regex > > out of the picture. > > > > http://tech.groups.yahoo.com/group/power-pro/message/30226 > > > > In 2006 message above, Bruce said vectors are automatically > > released when you recreate them with vec.create. > > What I meant was that vectors assigned to local variables are > automatically released when you exit the script.
[..snip..] > You have to free all vectors before re-assigning to a variable > which still could have a vector assigned to it. Longstanding misunderstanding!!!! I need to review all my scripts. Oh well. > > There is a limit to how deeply you can nest for each, I think 4 or > so, and then includes in script calls. I suspect you ran into the > above because of the other errors in the for statement, which > possibly meant the for each memory was not properly cleaned up. > I think my real script is now working fine. It had several more vectors (and also maps) inside the loop that needed attention. I guess my nesting must be ok. I have several "for each" nested once under the main one, and several if's nested once or twice under those. > > Now you know why people like automatic gargage collection. I > debated implementing it (through reference counting) when I > implemented objects and classes (which do have automatic garbage > collection), but decided to leave well enough alone. I wish you'd post some easy scriptlets that use them. I did read thru the turing machine back when you implemented objects and classes, but it was over my head. Regards, Sheri
