From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Eric Abrahamsen Newsgroups: gmane.emacs.devel Subject: Re: Turning Gnus groups into real objects Date: Mon, 22 Jul 2019 09:38:20 -0700 Message-ID: <87v9vuyqgz.fsf@ericabrahamsen.net> References: <87k1cg5ujl.fsf@ericabrahamsen.net> <87wogf8sei.fsf@mouse.gnus.org> <87zhlb2per.fsf@ericabrahamsen.net> <877e8e89os.fsf@mouse.gnus.org> <87ftn17tey.fsf@ericabrahamsen.net> <87o91o7try.fsf@mouse.gnus.org> <877e8c2mhe.fsf@ericabrahamsen.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="336"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jul 22 18:38:35 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hpbKc-0018FP-SK for ged-emacs-devel@m.gmane.org; Mon, 22 Jul 2019 18:38:34 +0200 Original-Received: from localhost ([::1]:35920 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hpbKb-000838-GA for ged-emacs-devel@m.gmane.org; Mon, 22 Jul 2019 12:38:33 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:46751) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hpbKY-00082o-RN for emacs-devel@gnu.org; Mon, 22 Jul 2019 12:38:31 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hpbKX-0004SI-Sf for emacs-devel@gnu.org; Mon, 22 Jul 2019 12:38:30 -0400 Original-Received: from ericabrahamsen.net ([52.70.2.18]:53164 helo=mail.ericabrahamsen.net) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hpbKX-0004PK-PW for emacs-devel@gnu.org; Mon, 22 Jul 2019 12:38:29 -0400 Original-Received: from localhost (c-73-254-86-141.hsd1.wa.comcast.net [73.254.86.141]) (Authenticated sender: eric@ericabrahamsen.net) by mail.ericabrahamsen.net (Postfix) with ESMTPSA id 289EAFA05A; Mon, 22 Jul 2019 16:38:21 +0000 (UTC) In-Reply-To: (Stefan Monnier's message of "Sun, 21 Jul 2019 09:40:47 -0400") X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 52.70.2.18 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:238794 Archived-At: On 07/21/19 09:40 AM, Stefan Monnier wrote: >> (probably not), or b) adjust gnus-check-backend-function and >> gnus-get-function to check if the server is a list or a struct and >> dispatch to different kinds of functions. > > FWIW, cl-defmethod can also dispatch based on whether it's a struct or > list, but I'm not sure so the "old-style" functionality could maybe be > implemented as a kind of "compatibility backend of type `cons`"? If I'm understanding you correctly, you're saying we could "do something" to the old style backends so that they're more definitely identifiable as a Gnus server, and not just any old list? It's possible to write new specializers for methods, right? If we could use that to positively identify a old-style backend, I would love to move the whole machinery into generic functions.