hide local variables from substitution for a user defined object
- Subject: hide local variables from substitution for a user defined object
- From: Sergey Litvinov
- Date: Fri, 29 Nov 2013 19:59:16 +0100
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