From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/52321 Path: main.gmane.org!not-for-mail From: prj@po.cwru.edu (Paul Jarc) Newsgroups: gmane.emacs.gnus.general Subject: Re: mail-sources backend specific? Date: Mon, 05 May 2003 12:38:08 -0400 Organization: What did you have in mind? A short, blunt, human pyramid? Sender: ding-owner@lists.math.uh.edu Message-ID: References: <84u1cknes9.fsf@lucy.is.informatik.uni-duisburg.de> <87fznxzemr.fsf@wmipf.in-berlin.de> <84d6j1bhn3.fsf@lucy.is.informatik.uni-duisburg.de> <87el3hxw5b.fsf@wmipf.in-berlin.de> <84isstiewq.fsf@lucy.is.informatik.uni-duisburg.de> <87he8d752z.fsf@wmipf.in-berlin.de> <87he8cav01.fsf@wmipf.in-berlin.de> <8465ost014.fsf@lucy.is.informatik.uni-duisburg.de> <87znm3g5qz.fsf@wmipf.in-berlin.de> <847k97zr1k.fsf@lucy.is.informatik.uni-duisburg.de> <87r87fph6s.fsf@wmipf.in-berlin.de> <84el3eet60.fsf@lucy.is.informatik.uni-duisburg.de> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: main.gmane.org 1052153957 8473 80.91.224.249 (5 May 2003 16:59:17 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 5 May 2003 16:59:17 +0000 (UTC) Original-X-From: ding-owner+M864@lists.math.uh.edu Mon May 05 18:59:03 2003 Return-path: Original-Received: from malifon.math.uh.edu ([129.7.128.13]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 19Cixr-0000bh-00 for ; Mon, 05 May 2003 18:37:19 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by malifon.math.uh.edu with smtp (Exim 3.20 #1) id 19Ciyq-0000tI-00; Mon, 05 May 2003 11:38:20 -0500 Original-Received: from sclp3.sclp.com ([64.157.176.121]) by malifon.math.uh.edu with smtp (Exim 3.20 #1) id 19Ciyi-0000tC-00 for ding@lists.math.uh.edu; Mon, 05 May 2003 11:38:12 -0500 Original-Received: (qmail 15389 invoked by alias); 5 May 2003 16:38:12 -0000 Original-Received: (qmail 15384 invoked from network); 5 May 2003 16:38:12 -0000 Original-Received: from multivac.student.cwru.edu (HELO multivac.cwru.edu) (@129.22.114.26) by sclp3.sclp.com with SMTP; 5 May 2003 16:38:12 -0000 Original-Received: (qmail 6034 invoked by uid 500); 5 May 2003 16:38:30 -0000 Original-To: ding@gnus.org In-Reply-To: <84el3eet60.fsf@lucy.is.informatik.uni-duisburg.de> (Kai =?iso-8859-1?q?Gro=DFjohann's?= message of "Sun, 04 May 2003 15:29:59 +0200") Mail-Copies-To: nobody Mail-Followup-To: ding@gnus.org Original-Lines: 38 User-Agent: Gnus/5.1002 (Gnus v5.10.2) Emacs/21.3 (gnu/linux) Precedence: bulk Xref: main.gmane.org gmane.emacs.gnus.general:52321 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:52321 kai.grossjohann@gmx.net (Kai Gro=DFjohann) wrote: > Suppose you have this situation: > > (setq gnus-secondary-select-methods > '((nnml "one" (nnml-mail-sources foo)) > (nnml "two" (nnml-mail-sources bar)))) > > Clearly there must be a mechanism that prevents the two settings for > nnml-mail-sources stomping on each other. Yes: the nnml backend has the notion of a "current server", and only one setting is in effect at a time. nnoo is used to set nnml-mail-sources, according to the server name ("one" or "two"). > So can't this mechanism be used to also protect mail-sources, instead > of only nnml-mail-sources? No, because the mechanism is tied to the backend's notion of its current server. If two backends are involved, there are two current servers, so variables must have different names to avoid interference. nnmaildir does not use nnoo, and its server parameters are not prefixed with "nnmaildir-". It does not use global variables to represent its server parameters. So there is no problem here: (setq gnus-secondary-select-methods '((nnmaildir "one" (directory "~/one")) (nnmaildir "two" (directory "~/two")))) This works because nnmaildir does not set "directory" as a global variable; instead, it looks up the string keyed by the symbol 'directory in the select method. (Actually, the information in the select method is copied into a more efficient vector, but that's not important. The point is that private, anonymous data structures are used instead of global variables.) The same could be made to work with nnoo-derived backends, but they would not be able to refer to such parameters as if they were global variables. paul