Arc Forumnew | comments | leaders | submitlogin
3 points by thaddeus 4926 days ago | link | parent

I agree with everything you're saying... and, also, in thinking about it further, I believe that having namespaces as a first class feature is the best way to solve this kinda problem.

For example, in Clojure, I can just build my project by excluding the function in question and replace it with my version. Anyone else that wants to use Clojure doesn't need to worry about another persons great idea.

; example

  (ns a-project.core
    (:refer-clojure :exclude (best))
    (:gen-class))
  
  (defn best []
    ...)
And anyone else wanting to use my library and/or only use my version can do so, simply:

  (ns your-project.core
    (:refer-clojure :exclude (best))
    (:use [a-project :only (best)])
    (:gen-class))
   
   (defn do-my-stuff []
    (best ....))
And I can't even remember now - did anarki get namespaces? I know there were some implementations, I just don't know if it made its way into anarki.

I also believe namespaces would promote the sharing of libraries, which arc also suffers from.