Functions may leak information about names(!) of local variables.
Subject: Functions may leak information about names(!) of local variables.
From: Michel Van den Bergh
Date: Thu, 28 Dec 2006 14:33:11 +0100
I really don't see how to do robust programming in maxima.
Consider
g(s):=block([t],local(t), t[4]:subvar(s,4), t[4]);
t[n]:=n^3;
u[n]:=n^4;
g(u);
256
g(t);
t_4
What is the correct way of dealing with this? Or should one just say that
arrays are not first class objects and should not be passed around in
this way?
That would be a pity.
Michel