<br>I think the divergence is coming from the fact that I want a special functionality (package renaming) with a simple syntax and you want a general functionality which cannot be represented by a simple syntax. So it is a tradeoff between simple syntax and general functionality.<br>

<br>As package renaming is already available in a "complex" way, providing another complex way won't improve on its popularity. If it would be possible just with a few more characters in an asd file, people might use it. Otherwise if they have to create different functions, classes in separate files for that, they just keep providing nicknames...<br>

<br>But I am wondering how an asd file would look like with your scenario. Can you provide an example?<br><br>Btw, I imagine before/after implemented in a setup/cleanup style, so if compilation fails, cleanup (after) still runs. So it is wrapped in an unwind-protect.<br>

So the before/after is nothing to do with generic functions in my view. It is just a wrapping around COMPILE-FILE.<br><br>`bg`<br><br><br><div class="gmail_quote">2011/10/17 Faré <span dir="ltr"><<a href="mailto:fahree@gmail.com">fahree@gmail.com</a>></span><br>

<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div class="im">> (defsystem com.host.my-system<br>
>   (:serial t)<br>
>   (:depends-on ("system-1" "system-2")<br>
>   (:components ((:file "file1")<br>
>                 (:file "file2" :class 1)<br>
>                 (:file "file3" :class 2)<br>
>                 (:file "file4" :class 1))<br>
>   (:before-compile 1 #'(lambda (component) (do what you want)))<br>
>   (:after-compile 1 #'(lambda (component) (do what you want)))))<br>
><br>
</div>Once again, :around compile is more general than :before and :after,<br>
and some of its functionality (e.g. binding, condition handling,<br>
unwind-protect, result filtering, etc.) just cannot be properly<br>
achieved with :before and :after methods.<br>
<br>
Also, some files may need special handling. For instance,<br>
the file that defines packages and/or helpers for a :around-compile<br>
function must not be wrapped by the function that depends on it. So it<br>
is not practical to have a system-wide default that cannot be<br>
overridden.<br>
<div class="im"><br>
> And class 0 could be the (unspecified) default.<br>
> However, I would still prefer to have some kind of simplified notation for<br>
> the local package renaming functionality as I think that is the most common.<br>
> And I have no idea how difficult it is to put something like this into asdf<br>
> as I am not familiar with its code...<br>
><br>
</div>I don't see how the numbering helps. Let's keep it with named classes<br>
when needed.<br>
<br>
As to how I'd implement it: I'd add an around-compile slot to<br>
component, with no :initform, an effective-around-compile generic<br>
function that handles "inheritance" from the parent when the slot is<br>
unbound, a (call-with-around-compile-hook component thunk) that does<br>
the wrapping based on the former gf, and use that use that function in<br>
the perform method for compile-op.<br>
<div class="im"><br>
—♯ƒ • François-René ÐVB Rideau •Reflection&Cybernethics• <a href="http://fare.tunes.org" target="_blank">http://fare.tunes.org</a><br>
</div>Mathematics is the Queen of Science but she isn't very Pure; she keeps<br>
having babies by handsome young upstarts and various frog princes.<br>
  — Donald Kingsbury (In "psychohistorical crisis", 2001)<br>
</blockquote></div><br>