deftype code reload oddity

2015-09-11 Thread Gregg Reynolds
Here's something a little perplexing that I discovered by trial and error: if you reload (using require :reload) a clj file containing a deftype implementing clojure interfaces (e.g. ISeq, etc.) plus some functions, the functions will be reloaded but not the deftype implementation code. That is,

Re: Why (memoize (fn [_#] (gensym "node")) in rhizome?

2015-09-11 Thread Sam Ritchie
Seems like a good use of “delay”, yeah? Slightly different calling semantics, of course, but still: user> (def f (delay (gensym "node"))) #'user/f user> @f node3330 user> @f node3330 Sam Ritchie (@sritchie) RaceHub Co-Founder 703.863.8561 www.racehubhq.com Twitter

Re: Why (memoize (fn [_#] (gensym "node")) in rhizome?

2015-09-11 Thread Sean Corfield
(memoize (fn [_#] (gensym "node")) How is that different than (gensym "node") The latter returns a string, e.g., "node18051", the former returns a function that, when called, returns a string. Wrapping it in memoize just ensures that if you call it multiple times with the same argument, you g

Why (memoize (fn [_#] (gensym "node")) in rhizome?

2015-09-11 Thread Lawrence Krubner
I'm always interested in the stuff Zach Tellman does, though I don't always understand it. I'm curious about this bit: (memoize (fn [_#] (gensym "node")) How is that different than (gensym "node") I only see with-gensyms called once, so I assume the goal is to have dynamic bindings set up f

Re: Question about equality in HashMaps

2015-09-11 Thread Erlis Vidal
Ohh I was fooled by the editor. http://www.tryclj.com/ shows the right values. Thanks for catching that up for me. instaREPL definitely has a bug there. Time to install light table... Thanks guys!!! On Fri, Sep 11, 2015 at 3:45 PM, Michael Blume wrote: > I wonder why instaREPL prints a as {"a

Re: Question about equality in HashMaps

2015-09-11 Thread Michael Blume
I wonder why instaREPL prints a as {"a" 3, "r" 1, "u" 1} On Fri, Sep 11, 2015 at 3:42 PM Alex Miller wrote: > a uses characters (\a \b \c) > b uses strings ("a" "b" "c") > > Those are not equal... > > Try: > (def b {\a 3 \r 1 \u 1}) > > > On Friday, September 11, 2015 at 5:37:32 PM UTC-5, Erlis

Re: Question about equality in HashMaps

2015-09-11 Thread Alex Miller
a uses characters (\a \b \c) b uses strings ("a" "b" "c") Those are not equal... Try: (def b {\a 3 \r 1 \u 1}) On Friday, September 11, 2015 at 5:37:32 PM UTC-5, Erlis Vidal wrote: > > (def a (apply merge-with + (map #(hash-map %1 1) "aaaur"))) > (def b {"a" 3, "r" 1, "u" 1}) > > (= a b) ;

Question about equality in HashMaps

2015-09-11 Thread Erlis Vidal
(def a (apply merge-with + (map #(hash-map %1 1) "aaaur"))) (def b {"a" 3, "r" 1, "u" 1}) (= a b) ; why false (.equals a b) (type a) (type b) (identity a) (identity b) from http://web.clojurerepl.com/ ​ -- You received this message because you are subscribed to the Google Groups

Re: Leiningen template in private maven repo

2015-09-11 Thread Michael Willis
I figured it out - leiningen looks for template in the default repos, and anything configured under {:user {:plugin-repositories ...}} On Friday, September 11, 2015 at 11:38:24 AM UTC-5, Michael Willis wrote: > > I'm trying to write a leiningen template for company internal use. I have > deplo

Reading Clojure expressions

2015-09-11 Thread Huey Petersen
Hello, I'm not sure the proper terminology -- reading might be wrong. The idea is I'd like to mimic behavior in most Clojure development environments where given a buffer and a position you can find related expressions. e.g. previous expression, enclosing expression, etc. Preferably the resu

Leiningen template in private maven repo

2015-09-11 Thread Michael Willis
I'm trying to write a leiningen template for company internal use. I have deployed it to our internal Artifactory instance, and added the Artifactory URL to :repositories in ~/.lein/profiles.clj, but `lein new` can't resolve it: $ lein new rest-microservice my-new-api Failed to resolve version

[ANN] multi-atom 0.1.0 - a library for dealing with atom-like cells. Includes DynamoDB support.

2015-09-11 Thread Daniel Stone
Hi, I am pleased to announce the first release of: https://github.com/mixradio/multi-atom. Much in the spirit of avout[1] and enduro[2], multi-atom is a library for dealing with things that can behave as atoms, only not limited to in-memory cells. Its approach is to: a. Use the IAtom interf

Re: Beginning Clojure Development

2015-09-11 Thread Alan Moore
One language detail that took me a while to get the hang of at first was destructuring (fm args, let blocks, etc.) I had never encountered anything like it before in other languages and it took me a while to memorize all the different variations. It is awesome powerful but alien at first. Getti

Re: Beginning Clojure Development

2015-09-11 Thread Alan Moore
Dang autocorrect: fm -> fn -- 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 Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this

Re: Beginning Clojure Development

2015-09-11 Thread J.-F. Rompre
I try to get my hands on as many resources from the above as possible. I often found some (generally more advanced) works not to dwelve enough into some intricate, but essential, topics which were better covered in other resources. Also, the toolset evolves quickly so online resources are indis

flexible vectors with aatree 0.2.0

2015-09-11 Thread William la Forge
Second release of aatree: https://github.com/laforge49/aatree -added support for vectors -improved performance by avoiding reflection. Unlike the standard Clojure vectors, aavector also supports add/drop at any point in the vector. This was reasonable because aavector is implemented as a

[ANN] Clojure 1.8.0-alpha5

2015-09-11 Thread Alex Miller
Clojure 1.8.0-alpha5 is now available. Try it via - Download: https://repo1.maven.org/maven2/org/clojure/clojure/1.8.0-alpha5 - Leiningen: [org.clojure/clojure "1.8.0-alpha5"] The 1.8.0-alpha5 release reverts the change made for CLJ-1250

Re: add concurrency feature as language spec.

2015-09-11 Thread Renjith Thankachan
Yea.. Like core.async but as language keyword or standard way so that we can easily switch. -- 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 Note that posts from new members are moderated -