Mon Jan 4 01:03:10 UTC 2010 pix@kepibu.org * Make subjects-of use subjects-in-list diff -rN -u old-Oh, Ducks!/selectors.lisp new-Oh, Ducks!/selectors.lisp --- old-Oh, Ducks!/selectors.lisp 2015-11-01 16:47:16.000000000 +0000 +++ new-Oh, Ducks!/selectors.lisp 2015-11-01 16:47:16.000000000 +0000 @@ -104,15 +104,10 @@ (mapcar (curry #'subjects-of selector) element-list))) -(defgeneric subjects-of (selector element) - (:method (selector (element t)) - (flet ((find-in-list (elements) - (mapcar (curry #'subjects-of selector) - elements))) - (nconc - (when (element-matches-p element selector) (list element)) - (reduce #'nconc - (find-in-list (element-children element))))))) +(defun subjects-of (selector element) + (nconc + (when (element-matches-p element selector) (list element)) + (subjects-in-list selector (element-children element)))) (defgeneric element-matches-p (element selector))