Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

use does accept an :as option:

    => (use '[clojure.set :as set])
    => set/intersection
    #<set$intersection clojure.set$intersection@58ca40be>
Prior to the addition of :refer to require, this was often paired with an :only (...) in order to alias a namespace as well as refer in some limited set of vars if desired, all in one declaration.


Huh, I checked the docs before I commented. It is indistinguishable from require :as, thought, right?


As far as I know. Honestly, by use/require/refer-fu is not very strong, I always just use the ns macro.


Yes, the :as option is the same whether you use it with require or use.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: