Error report: unify and '

Started by Kazimir Majorinc, January 27, 2011, 08:49:54 AM

Previous topic - Next topic

Kazimir Majorinc

> (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
>
http://kazimirmajorinc.com/\">WWW site; http://kazimirmajorinc.blogspot.com\">blog.

Lutz

#1
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.