> ... signs a contributor agreement.  If he wants to create his own
> version of the module for his own personal use, in which he swaps out
> my function for his faster one, there appears to be no good way to do
> this, short of copying my entire file, commenting out my function, ...

I think Stuart's idea (rather than binding) might be the recipe for a
solution to this. Using the canonical gravity example;

(use 'gravity)

(alter-var-root (var say-grav) (fn [_] (fn [x] (prn "my-version-grav:" x))))

(say-grav 3.0)
"my-version-grav:" 3.0

The alter-var-root could be wrapped in one or more functions or macros
to make the "overriding" a bit more friendly.

Adrian.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To post to this group, send email to clojure@googlegroups.com
To unsubscribe from this group, send email to 
clojure+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/clojure?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to