[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Using setq to obtain a symbol from a list, so that I can assign a fu
From: |
Kevin Rodgers |
Subject: |
Re: Using setq to obtain a symbol from a list, so that I can assign a function to it |
Date: |
Tue, 22 Apr 2008 23:10:58 -0600 |
User-agent: |
Thunderbird 2.0.0.12 (Macintosh/20080213) |
srinik001@hotmail.com wrote:
Oops... I got the subject wrong. Instead of
" Using setq to obtain a symbol from a list, so that I can assign a
function to it", it should read, "Using setq to assign value to the
result of a function". Sorry about that.
Use set instead of setq:
,----[ C-h f setq RET ]
| setq is a special form in `C source code'.
| (setq [sym val]...)
|
| Set each sym to the value of its val.
| The symbols sym are variables; they are literal (not evaluated).
| The values val are expressions; they are evaluated.
| Thus, (setq x (1+ y)) sets `x' to the value of `(1+ y)'.
| The second val is not computed until after the first sym is set, and
so on;
| each val can use the new value of variables set earlier in the `setq'.
| The return value of the `setq' form is the value of the last val.
|
| [back]
`----
,----[ C-h f set RET ]
| set is a built-in function in `C source code'.
| (set symbol newval)
|
| Set symbol's value to newval, and return newval.
|
| [back]
`----
--
Kevin Rodgers
Denver, Colorado, USA
- Re: Using setq to obtain a symbol from a list, so that I can assign a function to it, (continued)
- Re: Using setq to obtain a symbol from a list, so that I can assign a function to it, srinik001, 2008/04/22
- Re: Using setq to obtain a symbol from a list, so that I can assign a function to it, Barry Margolin, 2008/04/22
- Re: Using setq to obtain a symbol from a list, so that I can assign a function to it, srinik001, 2008/04/23
- Re: Using setq to obtain a symbol from a list, so that I can assign a function to it, Pascal Bourguignon, 2008/04/23
- Re: Using setq to obtain a symbol from a list, so that I can assign a function to it, Barry Margolin, 2008/04/23
- Re: Using setq to obtain a symbol from a list, so that I can assign a function to it, srinik001, 2008/04/27
Re: Using setq to obtain a symbol from a list, so that I can assign a function to it,
Kevin Rodgers <=