hide local variables from substitution for a user defined object



Robert Dodier <robert.dodier at gmail.com> writes:

>
>   [my_dummy, e1] : blex ([i], ..., [i, my_sum(...)]);
>   subst (my_dummy = ..., e1);
>
> (I didn't try that but I think it should work.)
>

It works as you suggested

(%i1) load ("./blex.lisp") $
(%i2) [my_dummy, e1]: blex([i], [i, my_sum(i, [i])])$
(%i3) is(part(e1, 1)=my_dummy);
(%o3)                                true
(%i4) :lisp $my_dummy
G972
(%i4) aux: part(e1, 1)$
(%i5) :lisp $aux
G972