From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/39657 Path: main.gmane.org!not-for-mail From: Per Abrahamsen Newsgroups: gmane.emacs.gnus.general Subject: Re: new Mail-Followup-To patch...please take a look... Date: Tue, 23 Oct 2001 19:32:42 +0200 Organization: The Church of Emacs Sender: owner-ding@hpc.uh.edu Message-ID: References: <87wv1m9y6j.fsf@mclinux.com> <87bsiy9txe.fsf@mclinux.com> NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1035175334 29138 80.91.224.250 (21 Oct 2002 04:42:14 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 21 Oct 2002 04:42:14 +0000 (UTC) Return-Path: Original-Received: (qmail 8181 invoked from network); 23 Oct 2001 17:36:25 -0000 Original-Received: from malifon.math.uh.edu (mail@129.7.128.13) by mastaler.com with SMTP; 23 Oct 2001 17:36:25 -0000 Original-Received: from sina.hpc.uh.edu ([129.7.128.10] ident=lists) by malifon.math.uh.edu with esmtp (Exim 3.20 #1) id 15w5Qn-0001LA-00; Tue, 23 Oct 2001 12:33:37 -0500 Original-Received: by sina.hpc.uh.edu (TLB v0.09a (1.20 tibbs 1996/10/09 22:03:07)); Tue, 23 Oct 2001 12:33:14 -0500 (CDT) Original-Received: from sclp3.sclp.com (qmailr@sclp3.sclp.com [209.196.61.66]) by sina.hpc.uh.edu (8.9.3/8.9.3) with SMTP id MAA07864 for ; Tue, 23 Oct 2001 12:33:03 -0500 (CDT) Original-Received: (qmail 8111 invoked by alias); 23 Oct 2001 17:33:16 -0000 Original-Received: (qmail 8106 invoked from network); 23 Oct 2001 17:33:15 -0000 Original-Received: from sheridan.dina.kvl.dk (130.225.40.227) by gnus.org with SMTP; 23 Oct 2001 17:33:15 -0000 Original-Received: from ssv2.dina.kvl.dk (ssv2.dina.kvl.dk [130.225.40.226]) by sheridan.dina.kvl.dk (8.9.3/8.9.3/Debian 8.9.3-21) with ESMTP id TAA28959; Tue, 23 Oct 2001 19:32:42 +0200 Original-Received: from abraham by ssv2.dina.kvl.dk with local (Exim 3.12 #1 (Debian)) id 15w5Pu-00027G-00; Tue, 23 Oct 2001 19:32:42 +0200 Original-To: ding@gnus.org X-Face: +kRV2]2q}lixHkE{U)mY#+6]{AH=yN~S9@IFiOa@X6?GM|8MBp/ In-Reply-To: <87bsiy9txe.fsf@mclinux.com> (Josh Huber's message of "Tue, 23 Oct 2001 12:56:29 -0400") Original-Lines: 30 User-Agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/21.0.106 (i686-pc-linux-gnu) Precedence: list X-Majordomo: 1.94.jlt7 Xref: main.gmane.org gmane.emacs.gnus.general:39657 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:39657 Josh Huber writes: > The problem with this is, this search function appears to be expensive > enough that I wouldn't want it as a default... This version is fast enough to be enabled by default, and also avoids the cl dependencies: (defun gnus-find-subscribed-adresses () "Return a regexp matching the addresses of all subscribed mail groups. It consists of the `to-address' or `to-list' parameter of all groups with a non-nil `subscribed' parameter." (let ((addresses nil)) (mapc (lambda (entry) (let ((group (car entry))) (when (gnus-group-get-parameter group 'subscribed) (let ((address (or (gnus-group-get-parameter group 'to-address) (gnus-group-get-parameter group 'to-list)))) (when address (setq addresses (const address addresses))))))) gnus-newsrc-alist) (mapconcat 'regexp-quote addresses "\\|"))) However, most of the speed advantage come from gnus-group-get-parameter instead of gnus-group-find-parameter, which mean it won't work with topic parameters. A quick look suggest gnus-group-find-parameter is a memory pig. I suspect we with a little care can speed it up enough in the single parameter case, to make is useable for our purpose.