Comment 1 for bug 481187

Revision history for this message
Tobias C. Rittweiler (tcr) wrote :

In Slime's ASDF contrib, we currently use the following

(defun who-depends-on (system)
  (flet ((system-dependencies (op system)
           (mapcar #'(lambda (dep)
                       (asdf::coerce-name (if (consp dep) (second dep) dep)))
                   (cdr (assoc op (asdf:component-depends-on op system))))))
    (let ((system-name (asdf::coerce-name system))
          (result))
      (map-defined-systems
       #'(lambda (system)
           (when (member system-name
                         (system-dependencies 'asdf:load-op system)
                         :test #'string=)
             (push (asdf:component-name system) result))))
      result)))