[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: basic help evaluating function in an alist
From: |
WJ |
Subject: |
Re: basic help evaluating function in an alist |
Date: |
1 Dec 2012 23:12:28 GMT |
User-agent: |
XanaNews/1.18.1.6 |
Matt Price wrote:
> Hi,
>
> i'm trying to figure out what's wrong with this simple code:
>
> (add-to-list 'my-winlist
> '(guide . (selected-window) )
> )
> (windmove-right)
> (select-window(cdr(assoc 'guide my-winlist)) )
>
> So, what I would hope happens here is that I add an element (guide .
> (selected-window)) to an alist, but that the second element would be
> the actual window object in question, not the text string
> "(selected-window)". Lisp puzzles me pretty thoroughly so I know I'm
> missing a very basic feature, but I can't figure it out by flipping
> through the info pages... Thanks everyone!
> Matt
: (setq mylist '((b . 2)))
((b . 2))
: (add-to-list 'mylist (cons 'c (sqrt 3)))
((c . 1.7320508075688772) (b . 2))
- Re: basic help evaluating function in an alist,
WJ <=