PDA

View Full Version : single array elements in list


Nicknack
07-11-2009, 11:11 PM
took me some time to get the idea it could be a internal problem, but finally I extracted this strange behaviour:
proc test(a$)
dim(r$,2);
r$[1]=5;
add(a$,r$[1]);
end;

proc main
list(l$);
test(&l$);
foreach(l$)
showmessage(l$);
end;
end;

and here is a temporary solution:
proc test(a$)
dim(r$,2);
r$[1]=5;
add(a$,r$[1]+0);
end;

proc main
list(l$);
test(&l$);
foreach(l$)
showmessage(l$);
end;
end;
what goes wrong here? why doesn't the list simply take the value of the element?

zehlein
07-12-2009, 06:29 AM
This is pretty weird! Something for Alain to look into... :)

kornalius
07-14-2009, 05:44 PM
Yep, there was a problem here. I have fixed it, thank you very much.