From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Cecil Westerhof Newsgroups: gmane.emacs.help Subject: Break from a dolist Date: Sun, 09 Sep 2012 10:56:57 +0200 Organization: Decebal Computing Message-ID: <87bohfy3om.fsf@Compaq.site> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1347181773 19284 80.91.229.3 (9 Sep 2012 09:09:33 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 9 Sep 2012 09:09:33 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sun Sep 09 11:09:36 2012 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TAdWG-0005Ca-Js for geh-help-gnu-emacs@m.gmane.org; Sun, 09 Sep 2012 11:09:32 +0200 Original-Received: from localhost ([::1]:50990 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TAdNF-000431-63 for geh-help-gnu-emacs@m.gmane.org; Sun, 09 Sep 2012 05:00:13 -0400 Original-Received: by 10.180.75.168 with SMTP id d8mr1604770wiw.1.1347181018151; Sun, 09 Sep 2012 01:56:58 -0700 (PDT) X-FeedAbuse: http://nntpfeed.proxad.net/abuse.pl feeded by 88.191.116.97 Original-Path: usenet.stanford.edu!yt1no9368813wib.1!news-out.google.com!q11ni43930789wiw.1!nntp.google.com!proxad.net!feeder1-2.proxad.net!nntpfeed.proxad.net!dedibox.gegeweb.org!gegeweb.eu!usenet.pasdenom.info!aioe.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 20 Original-NNTP-Posting-Host: lYLrXPFpjyZ8237ODaoN+w.user.speranza.aioe.org Original-X-Complaints-To: abuse@aioe.org User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) X-Notice: Filtered by postfilter v. 0.8.2 Cancel-Lock: sha1:UYzzayeZHQV7U96R17sQRTRxj14= X-Homepage: http://www.decebal.nl/ Original-Xref: usenet.stanford.edu gnu.emacs.help:194359 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:86703 Archived-At: I have the following code to fetch the email address belonging to a mailing list. I use it to automatically fill the to address when posting to a newsgroup. (defun dcbl-gnus-get-mailing-list-address () "Get gnus-newsgroup-name mailing list address (if it has one);" (let ((to-address nil)) (when gnus-newsgroup-name (dolist (item dcbl-gnus-mailing-lists) (when (string-match (car item) gnus-newsgroup-name) (setq to-address (cdr item))))) to-address)) But when the address is found, it would be better to leave the loop. Is this possible? -- Cecil Westerhof Senior Software Engineer LinkedIn: http://www.linkedin.com/in/cecilwesterhof