Gnus development mailing list
 help / color / mirror / Atom feed
From: kai.grossjohann@uni-duisburg.de (Kai Großjohann)
Subject: Re: Oort: Font-Encoding Problem?
Date: Sun, 17 Nov 2002 12:54:54 +0100	[thread overview]
Message-ID: <84of8oh0mp.fsf@lucy.cs.uni-dortmund.de> (raw)
In-Reply-To: <19437485731.20021117112550@gmx.net>

Marcus Frings <iam-est-hora-surgere@fuckmicrosoft.com> writes:

> Are there any (dis)advantages using add-to-list instead of setq?

That's impossible to answer.  They just do different things.  With
(setq foo '(a b c)) you set the variable foo to that value.  With
(add-to-list 'foo 'a) you add an element to the list foo.

It depends on the circumstances whether you want to delete the old
entries or just add new ones.

That said, I find that I usually just add items to alists because
usually the alists will do a useful job for most cases, so I just
need to modify one case or two.  Also, I then profit from new entries
into the alist in newer versions of the software.  Note that Lisp
traverses alists from the beginning and uses the first matching
item.  And add-to-list adds an item to the beginning.  This means
that even if there is an item in the alist already, the item you add
will take precedence.

Does this make sense?

kai
-- 
~/.signature is: umop ap!sdn    (Frank Nobis)



  reply	other threads:[~2002-11-17 11:54 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-11-16 19:38 Marcus Frings
2002-11-16 21:05 ` Kai Großjohann
2002-11-16 21:45   ` Marcus Frings
2002-11-16 22:17     ` Jesper Harder
2002-11-16 23:26       ` Marcus Frings
2002-11-17  2:41         ` Jesper Harder
2002-11-17 10:25           ` Marcus Frings
2002-11-17 11:54             ` Kai Großjohann [this message]
2002-11-17 19:48               ` Marcus Frings
2002-11-16 23:31     ` Christoph Conrad

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=84of8oh0mp.fsf@lucy.cs.uni-dortmund.de \
    --to=kai.grossjohann@uni-duisburg.de \
    /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.
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 NNTP newsgroup(s).