From: Lennart Borgman <lennart.borgman.073@student.lu.se>
Cc: emacs-devel@gnu.org
Subject: Re: dolist?
Date: Sat, 02 Jul 2005 20:33:23 +0200 [thread overview]
Message-ID: <42C6DDF3.4070605@student.lu.se> (raw)
In-Reply-To: <42C67DD0.4060006@student.lu.se>
Lennart Borgman wrote:
> I am trying to use dolist in the function below. When I comment out
> the line marked below I only get the first det from detlst. What is
> wrong? Is dolist a no-no? Or is this a bug?
Since I sent my last update reply on this to myself instead of the list
I am trying again...
Here is a better example for testing. Please test this with the marked
message commented out and not commented out. Just put it in a buffer and
eval it.
Am I doing something seriously silly? Has someone checked this or should
I file a bug?
--lennart
******** Test example, run with marked line COMMENTED OUT/NOT COMMENTED
OUT. Check *Messages*.
(defconst assoc-assoc-list nil)
(setq assoc-assoc-list
'(
("cedet-1.03b"
(
(description . "CEDET")
(install-function . 'cedet-setup)
))
("nxml-mode-20041004"
(
(description . "NXML")
(install-function . 'nxml-setup)
))
))
(defun check-detail(consdet)
(unless nil
;;(message " consdet=%s" consdet) ;; <---- does not work unless
this is NOT commented out
)
(let ((detname (car consdet)))
(message (concat " ... checking detail \"" (symbol-name detname)
"\""))))
(defun check-list()
(message "Checking package list detail names...")
(mapc
(lambda (pack)
(let ((detlst (nth 1 pack)))
(when detlst
(message "\ndetlst=%s" detlst)
(mapc 'check-detail detlst))))
assoc-assoc-list))
(check-list)
********** If run with marked line COMMENTED OUT it gives this:
Checking package list detail names...
detlst=((description . CEDET) (install-function quote cedet-setup))
... checking detail "install-function"
detlst=((description . NXML) (install-function quote nxml-setup))
... checking detail "install-function"
********** If run with marked line NOT COMMENTED OUT it gives this:
Checking package list detail names...
detlst=((description . CEDET) (install-function quote cedet-setup))
consdet=(description . CEDET)
... checking detail "description"
consdet=(install-function quote cedet-setup)
... checking detail "install-function"
detlst=((description . NXML) (install-function quote nxml-setup))
consdet=(description . NXML)
... checking detail "description"
consdet=(install-function quote nxml-setup)
... checking detail "install-function"
next prev parent reply other threads:[~2005-07-02 18:33 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-02 11:43 dolist? Lennart Borgman
2005-07-02 18:33 ` Lennart Borgman [this message]
2005-07-02 20:09 ` dolist? Lennart Borgman
2005-07-02 20:41 ` dolist? - same result on 21.3 Lennart Borgman
2005-07-02 21:46 ` Drew Adams
2005-07-02 21:01 ` dolist? Miles Bader
2005-07-02 21:01 ` dolist? David Ponce
2005-07-02 21:12 ` dolist? Juanma Barranquero
2005-07-02 21:27 ` dolist? Lennart Borgman
2005-07-02 21:33 ` dolist? Juanma Barranquero
2005-07-02 21:40 ` dolist? Lennart Borgman
2005-07-02 22:33 ` dolist? Adrian Aichner
2005-07-02 21:46 ` dolist? David Ponce
2005-07-02 22:07 ` dolist? Lennart Borgman
2005-07-02 22:44 ` dolist? Drew Adams
2005-07-02 22:12 ` dolist? Drew Adams
2005-07-02 23:35 ` dolist? Miles Bader
2005-07-02 23:50 ` dolist? Drew Adams
2005-07-02 21:50 ` dolist? Drew Adams
2005-07-02 21:28 ` dolist? Juanma Barranquero
2005-07-03 20:42 ` dolist? Richard M. Stallman
2005-07-03 23:09 ` dolist? Drew Adams
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=42C6DDF3.4070605@student.lu.se \
--to=lennart.borgman.073@student.lu.se \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).