Created
May 29, 2010 04:17
-
-
Save jkk/418036 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (setq swank-clojure-init-files (list "/Users/tin/src/clj/user.clj")) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| user> (def x 1) | |
| #'user/x | |
| user> x | |
| 1 | |
| user> (clear-ns) | |
| user> x | |
| ; Unable to resolve symbol: x in this context |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (defn clear-ns [] | |
| (let [n (ns-name *ns*) temp (gensym)] | |
| (in-ns temp) | |
| (clojure.core/remove-ns n) | |
| (clojure.core/in-ns n) | |
| (clojure.core/refer-clojure) | |
| (remove-ns temp) | |
| (load-file "/Users/tin/src/clj/user.clj"))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment