Can't get my nesting right

2010-08-10 Thread Alan
I have the following function as part of a card-game system I'm developing: (defn make-suit [suit owner ranks] {suit (map (partial struct-map card :suit suit :owner owner :rank) ranks)}) (make-suit

Re: Can't get my nesting right

2010-08-10 Thread Rasmus Svensson
2010/8/10 Alan a...@malloys.org: I have the following function as part of a card-game system I'm developing: (defn make-suit  [suit owner ranks]    {suit (map (partial struct-map card                        :suit suit                        :owner owner                        :rank)      

Re: Can't get my nesting right

2010-08-10 Thread Meikel Brandmeyer
Hi, Am 10.08.2010 um 20:56 schrieb Alan: which is exactly what I want. But I have failed countless times to define a make-hand function - I'd like to be able to call (make- hand :west {:spade [9 5], :club [10]}) and get back {:spade ({:suit :spade, :owner :west, :rank 9} {:suit :spade,