custom plus-like operator



Dobroe vremja sutok, Valery,
As you might have read, my main concern was to introduce algebraic 
properties for my custom operator. My guess was that I had to define a 
function with the same name, "aa" which would parse its' arguments and 
perform algebraic simplifications needed. In reply to your question, I 
would like to see (D4) and (C4) the same in your case. Comparing your 
code with the following lisp code, we see different behaviour:

---somwhere in a file aa.lisp--
(DEFMFUN $AA (&REST X)
   (PRINT X)
   (CONS (LIST '$AA 'SIMP) X))
--------
(C1) load("aa.lisp")$

(C2) 1 AA 2 AA F AA 3;


(1 2 $F 3)
(D2) 			       1 AA 2 AA F AA 3
--
Andrei Zorine

> 
> On my system I have
> (C1) infix("aa");
> (D1)                                 "AA"
> (C2) nary("aa");
> (D2)                                 "AA"
> (C3) "aa"([x]):=(print(x),'"aa"(x));
> (D3)                    "AA"([x]) := (PRINT(x), 'AA(x))
> (C4) 1 aa 2 aa f aa 3;
> [1, 2, f, 3]
> (D4)                           AA([1, 2, f, 3])
> 
> Is it what do you want to see?