Re: inconsistency with ref & get

2009-03-30 Thread Allen Rohner
> I disagree. When you understand what's happening (Refs implement IFn > by dispatching, just like Vars), you see that it has nothing to do > with obtaining the value of a ref without deref, and get can't work > since it doesn't take a ref. > Thanks for the explanation. Since get can't work beca

Re: inconsistency with ref & get

2009-03-30 Thread Rich Hickey
On Sun, Mar 29, 2009 at 11:33 PM, Allen Rohner wrote: > > I noticed an inconsistency with refs and get: > > (def ref-map (ref {:a 1, :b 2})) > > (ref-map :a) > => 1 > > (get ref-map :a) > => nil > > Now I haven't seen any documentation that getting the value of a ref > without a @/deref is suppor