From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/87716 Path: news.gmane.org!.POSTED!not-for-mail From: Lars Ingebrigtsen Newsgroups: gmane.emacs.devel,gmane.emacs.gnus.general Subject: Re: Gnus work Date: Thu, 05 Oct 2017 15:31:35 +0200 Message-ID: <87h8vdu3ew.fsf@mouse.gnus.org> References: <87vajudasc.fsf@ericabrahamsen.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1507210358 18998 195.159.176.226 (5 Oct 2017 13:32:38 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 5 Oct 2017 13:32:38 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: ding@gnus.org, emacs-devel@gnu.org To: Eric Abrahamsen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Oct 05 15:32:24 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e06GD-0003GX-ES for ged-emacs-devel@m.gmane.org; Thu, 05 Oct 2017 15:32:21 +0200 Original-Received: from localhost ([::1]:39874 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e06GK-0002ZU-Fn for ged-emacs-devel@m.gmane.org; Thu, 05 Oct 2017 09:32:28 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:47003) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e06Fe-0002Z8-Ny for emacs-devel@gnu.org; Thu, 05 Oct 2017 09:31:52 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e06FY-0000gO-WD for emacs-devel@gnu.org; Thu, 05 Oct 2017 09:31:46 -0400 Original-Received: from hermes.netfonds.no ([80.91.224.195]:59384) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e06FY-0000cm-OP for emacs-devel@gnu.org; Thu, 05 Oct 2017 09:31:40 -0400 Original-Received: from cm-84.209.243.26.getinternet.no ([84.209.243.26] helo=mouse) by hermes.netfonds.no with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1e06FT-00010I-Eo; Thu, 05 Oct 2017 15:31:37 +0200 In-Reply-To: <87vajudasc.fsf@ericabrahamsen.net> (Eric Abrahamsen's message of "Wed, 04 Oct 2017 11:32:03 -0700") X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 80.91.224.195 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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:219121 gmane.emacs.gnus.general:87716 Archived-At: Eric Abrahamsen writes: > 1. Replace Gnus' homemade mechanisms with equivalent mechanisms that > have since appeared in core (in many cases Gnus had them first). Sounds good. The backend interface is particularly grungy and could to with a complete rewrite. Since there are probably extremely few out-of-tree backends these days, I think you can massacre the interface with impunity without thinking about compatibility. > 2. Add docstrings and comments to minimize bug-hunter bewilderment. Sounds good. > 3. Look at unpicking functions so that there's a clearer demarcation > between code that does server logic (marks and whatnot) and code that > does UX/presentation stuff. There's a lot of long functions in Gnus, but there's also a reason for many of them being that way. The first is that when setting up modes and stuff, there's a lot of things that just have to be, er, set up. Replacing a long litany of stuff like (setq truncate-lines t mode-line-format foo) with (gnus-set-truncate-lines-to-t) (gnus-set-mode-line-format foo) isn't that much clearer. :-) (I'm just kidding, but that's kinda the Unclean Bob style of refactoring). The other consideration is that Emacs Lisp is really slow. Splitting central functions into many component functions will make Gnus even slower than it already is. And Gnus is slow. > 5. Reduce number of dynamic variables, to cut back on "spooky action at > a distance". To be honest I don't even know where to start here. Good luck, but Gnus has a gazillion settings that modify its workings in many, many ways, and they're all done by variables. Trimming down that overload of settings would be nice, but every time I've tried, there's always somebody that relied on just that single thing you'd think that nobody would be weird enough to actually use. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no