Re: Multiple indexing for vectors/maps

2008-10-20 Thread kwatford
> get-in is probably what you are looking for. and > No. It does not ignore the extra parameter! This is a default value, > which is returned in case the index is not contained in the vector. Ah, cool. I was going to blame the cold medicine I was on at the time for my inability to find this inf

Re: Multiple indexing for vectors/maps

2008-10-19 Thread Meikel Brandmeyer
Hello, Am 19.10.2008 um 00:12 schrieb kwatford: I don't think adding this should conflict with any existing code, though I did notice that "get" currently accepts and apparently ignores one extra parameter. No. It does not ignore the extra parameter! This is a default value, which is returned

Re: Multiple indexing for vectors/maps

2008-10-18 Thread Parth Malwankar
On Oct 19, 3:12 am, kwatford <[EMAIL PROTECTED]> wrote: > Sorry if this has been asked before, but I couldn't find anything on > it. > If I have: (def A [ [ 1 2 3 ] [ 4 5 6 ] ] ) > then if I want to access a specific element, I have to do: > ((A 1) 1)   -or-  (get (get A 1) 1) get-in is probabl

Multiple indexing for vectors/maps

2008-10-18 Thread kwatford
Sorry if this has been asked before, but I couldn't find anything on it. If I have: (def A [ [ 1 2 3 ] [ 4 5 6 ] ] ) then if I want to access a specific element, I have to do: ((A 1) 1) -or- (get (get A 1) 1) I could make a macro for this of course, but I'd kind of like to change the call seman