newLISP Fan Club

Forum => newLISP in the real world => Topic started by: Kazimir Majorinc on January 27, 2011, 08:49:54 AM

Title: Error report: unify and '
Post by: Kazimir Majorinc on January 27, 2011, 08:49:54 AM
> (unify '((quote X) (quote Y) (quote Z)) '((quote (a a)) (quote (b b)) (quote (c c))))
((X (a a)) (Y (b b)) (Z (c c)))
> (unify '('X 'Y 'Z) '('(a a) '(b b) '(c c)))
nil
>
Title: Re: Error report: unify and '
Post by: Lutz on January 27, 2011, 01:00:24 PM
In the current 'unify' implementation quoted expressions like: 'X or '(a a) are seen as atomic and not recursed into, but (quote X) is seen as a list. The 'unify' function doesn't know anything about LISP evaluation rules, it just sees symbolic expressions.