This sample is the same as `reftest2.bas' with the addition that the function is calling itself recursively ten times. This time when the command ref is issued the argument is a variable referencing reference, referencing ... ten times. Still the effect has to be the same.
Example reftest3.bas :
if s = 1 then
for i=1 to 10
z[i] = i
next
ref a = z
else
test(a,s-1)
endif
end sub
test q,100
for i=1 to 10
print i,". ",q[i],"\n"
next i
sub test(a,s)
local z,i
Result executing reftest3.bas :
Possible error messages sent to stderr: