function fn(m)
# very compley function... and "m" would be a complex shit... that is hard to print
@track modelsss m[1]=4+9 # mimicing a possible case
# ex.: using m[1] later on
end
c=[3,4]
fn(c)
modelsss
I have this @track macro:
macro track(var, ex)
esc(quote
((@isdefined $var) == false) && ($var = []); # create the variable... but it is only LOCAL scope :(
res = $ex
push!($var, res)
end)
end
But this create a local variable.
Is this even possible? Or I have to have a evasion maneuver like creating the variable outside and calling global beforehand