Fixed problem with the unification of a list with a
Tue Oct 25 19:17:33 UTC 2005 mantoniotti
* Fixed problem with the unification of a list with a
Fixed problem with the unification of a list with a
SEQUENCE-TEMPLATE. The implementation was not checking that the
length of the list was compatible with the length of the required
elements in the template.
Apart from that, keyword matching is still unimplemented.
diff -rN -u old-cl-unification-1/unifier.lisp new-cl-unification-1/unifier.lisp
--- old-cl-unification-1/unifier.lisp 2013-07-21 19:59:42.000000000 +0000
+++ new-cl-unification-1/unifier.lisp 2013-07-21 19:59:42.000000000 +0000
@@ -331,7 +331,9 @@
(let* ((n-vars (list-length vars))
(n-optionals (list-length optionals))
- (env (unify (subseq a 0 (list-length vars)) vars env))
+ (env (unify (subseq a 0 (min ll (list-length vars)))
+ vars
+ env))
)
(when (and optionals (>= ll (+ n-vars n-optionals)))
(setf env (unify (subseq a n-vars (+ n-vars n-optionals)) optionals env)))