Right now we have a situation in which load-source-op is a second class citizen, rarely used, and for which nobody provides explicit dependencies. More precisely

* Some compilers out there are just efficient compiling and loading source files. The operation is the same.
* LOAD-OP can be viewed as a slightly more efficient version of an operation that loads sources.
* Some users out there do not like compile-before-load procedure.
* ASDF makes no promise that load-source-op will behave similarly as load-op.
* Users define methods for load-op and not for load-source-op.
* In practice the dependencies *must* be the same, for the philosophy of CL is that compiled and not compiled files behave similarly.
* The only differences should be enforced to lay just in the compilation process.

I attach a patch which merges both operations, leaving a trace of compatibility.

* There is only one class, LOAD-OP.
* The class has the promise that it will use the same dependencies when loading sources and binaries.
* When imposing that one does compile the source before, the class issues an additional dependency on a compile-op, which may pull additional dependencies itself.
* A global flag, *compile-before-loading* determines the overall behavior
* A new function ASDF:LOAD-SOURCE-SYSTEM forces no compilation
* The function LOAD-SYSTEM gets a flag, :compile that sets *compile-before-loading*
* With these changes it is easy to get a sorted list of the components that make up a program. Furthermore, this list is guaranteed to work because we are using the same operation that we will use to load the files.

(pprint
 (loop with asdf::*compile-before-loading* = nil
    for (op . component)
    in (asdf::traverse (make-instance 'load-op)
                       (find-system "chunga"))
      collect (list (type-of op) (type-of component)
                    (asdf::component-name component))))

* With this mechanism I can reimplement the fasl concatenation mechanism *without* using classes at all. Same goes for ECL's extensions.

The patch is still not fully tested, but I submit it for discussion, so that ugly corners can be polished.

Juanjo

--
Instituto de Física Fundamental, CSIC
c/ Serrano, 113b, Madrid 28006 (Spain)
http://tream.dreamhosters.com