Hello Volker,
> there is an unwanted side effect:
> ( something like variable capture )
Arguments of Maxima functions have dynamic binding, not lexical.
What you've observed is a consequence of that.
I don't see anything incorrect here (i.e. Maxima is
working as designed).
I agree that dynamic binding sometimes leads to unintended
consequences. I'd like to see lexical binding implemented for
Maxima, although it could be some work.
hth
Robert