error by correct function definitions
Hi,
I am new in LW. Former I used GCM. I don’t understand: some function definitions I can’t evaluate in the Editor – I get a error message: “The variable L1 is unbound.” though the definition is correct. In the Listener Window the same function definition has been evaluated. What is the matter?
Example:
(DEFUN MY-MERGE (L1 L2)
(COND ((NULL L1) L2)
((NULL L2) L1)
((< (CAR L1) (CAR L2)) (CONS (CAR L1) (MY-MERGE (CDR L1) L2)))
(T (CONS (CAR L2) (MY-MERGE L1 (CDR L2))))))
Thanks
Boris