Re: [PATCH] have OPERATION-DONE-P return NIL for TEST-OP by default
Gary King <[email protected]> Mon, 10 Dec 2007 15:27:31 -0500
| Newsgroups | gmane.lisp.cclan.general |
|---|---|
| Message-ID | <[email protected]> |
As someone who has inserted: > (defmethod operation-done-p > ((o test-op) (c (eql (find-system 'xxx)))) > (values nil)) and > :in-order-to ((test-op (load-op :splitz-test))) over and over again, I can certainly see the desire for both of these behaviors. I think, however, that I'd prefer to dispatch only on systems, not components (only because it seems more minimal). I'm also less convinced about the component-depends-on method. Maybe that should also go only for systems. Either way, if these are documented, it shouldn't be a problem for people to override them as needed. (Though that should be tested). On Dec 10, 2007, at 2:48 PM, Luis Oliveira wrote: > Hello, > > The attached patch adds a default method to the OPERATION-DONE-P > generic > function for TEST-OP operations. This way one can run (oos 'test-op > :foo) several times without having to pass :FORCE T after the first > run. > > I might also argue that (oos 'test-op :foo) should also cause LOAD- > OP to > kick in. Something like: > > (defmethod component-depends-on ((operation test-op) (c component)) > (cons (list 'load-op (component-name c)) > (call-next-method))) > > I'm not 100% sure about either proposal because I probably don't > understand TEST-OP fully (for instance, I suppose it might have other > meanings besides running a test-suite) but the attached patch seems > fairly benign. > > Index: asdf.lisp > =================================================================== > RCS file: /cvsroot/cclan/asdf/asdf.lisp,v > retrieving revision 1.110 > diff -u -r1.110 asdf.lisp > --- asdf.lisp 27 Sep 2007 13:15:06 -0000 1.110 > +++ asdf.lisp 10 Dec 2007 16:59:09 -0000 > @@ -861,6 +861,9 @@ > (defmethod perform ((operation test-op) (c component)) > nil) > > +(defmethod operation-done-p ((operation test-op) (c component)) > + nil) > + > (defgeneric load-preferences (system operation) > (:documentation "Called to load system preferences after <perform > operation system>. Typical uses are to set parameters that don't > exist until after the system has been loaded.")) > > > -- > Luís Oliveira > http://student.dei.uc.pt/~lmoliv/ > ------------------------------------------------------------------------- > SF.Net email is sponsored by: > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php_______________________________________________ > cclan-list mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/cclan-list -- Gary Warren King, metabang.com Cell: (413) 559 8738 Fax: (206) 338-4052 gwkkwg on Skype * garethsan on AIM ------------------------------------------------------------------------- SF.Net email is sponsored by: Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ cclan-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/cclan-list