all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Concat var names ?
@ 2012-05-28  4:37 Philippe M. Coatmeur
  2012-05-28  3:59 ` XeCycle
       [not found] ` <mailman.1785.1338177648.855.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 4+ messages in thread
From: Philippe M. Coatmeur @ 2012-05-28  4:37 UTC (permalink / raw)
  To: help-gnu-emacs

Hi ; I have those two functions and I want to make them one :

(defun mail-bug-desktop-notify-one ()
  (mapcar
   (lambda (x)
     (if (not (member x mail-bug-advertised-mails-one))
	 (progn
	   (mail-bug-desktop-notification
	    (format "%s" (first x))
	    (format "%s \n%s" (second x)
		    (third x))
	    "5000" mail-bug-new-mail-icon-one)
	   (add-to-list 'mail-bug-advertised-mails-one x))))
   mail-bug-unseen-mails-one))

But I have to create distinct lists, so I'd really like to be able to
say

(setq suffix "plop")
(setq myvar-plop "value")
(message "%s" (concat "myvar-" suffix))

And get "myvar-value" instead of myvar-plop... 

Or even better, to use the same mechanism, a mapcar, but what about
the creation of mail-bug-advertised-mails-SUFFIX ? How do I instruct
my function to tell one list from the other ?

Phil


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-05-28  7:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-28  4:37 Concat var names ? Philippe M. Coatmeur
2012-05-28  3:59 ` XeCycle
     [not found] ` <mailman.1785.1338177648.855.help-gnu-emacs@gnu.org>
2012-05-28  4:26   ` Barry Margolin
2012-05-28  7:39     ` Philippe M. Coatmeur

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.