From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Daniel Colascione Newsgroups: gmane.emacs.devel Subject: Re: Multiple next-error sources Date: Fri, 07 Nov 2014 17:10:29 +0000 Message-ID: <545CFD05.6060104@dancol.org> References: <20141103084433.12117c03@forcix> <86fvdwgxqs.fsf@yandex.ru> <20141106180815.207bf7ad@forcix> <20141107104914.17f04967@forcix> <20141107165551.GA2865@acm.acm> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="Ra7PIw8bFSDpf5ih7NeWWhCsMBfLKDBaw" X-Trace: ger.gmane.org 1415380283 12925 80.91.229.3 (7 Nov 2014 17:11:23 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 7 Nov 2014 17:11:23 +0000 (UTC) Cc: Jorgen Schaefer , Helmut Eller , emacs-devel@gnu.org To: Alan Mackenzie , Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Nov 07 18:11:17 2014 Return-path: Envelope-to: ged-emacs-devel@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 1Xmn44-00044f-8T for ged-emacs-devel@m.gmane.org; Fri, 07 Nov 2014 18:11:12 +0100 Original-Received: from localhost ([::1]:33046 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xmn43-0000bp-LF for ged-emacs-devel@m.gmane.org; Fri, 07 Nov 2014 12:11:11 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:37753) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xmn3h-0000bU-KH for emacs-devel@gnu.org; Fri, 07 Nov 2014 12:10:56 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xmn3b-0003kj-7k for emacs-devel@gnu.org; Fri, 07 Nov 2014 12:10:49 -0500 Original-Received: from dancol.org ([2600:3c01::f03c:91ff:fedf:adf3]:39153) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xmn3a-0003kV-H5 for emacs-devel@gnu.org; Fri, 07 Nov 2014 12:10:43 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=dancol.org; s=x; h=Content-Type:In-Reply-To:References:Subject:CC:To:MIME-Version:From:Date:Message-ID; bh=PJHTTybnq4xfdJLldlVJdto4QIxcLohrfPTz0jyElKM=; b=fnc/ZJCWmWXiO7Q1JY7soeoPMWN054lI7JgSC4XFlevS8jx5DxDOSktgOWbUG8bc7+DFVgrXdstp86hUj66xM/JMIHo0JXLrVkqg4qa/Rd+JBqIrFO1/wV4wrL5c+usza4X0qNOQ/KcRp9CO973Z7acbLzvzt00o6p7AAvJO4lW4OX0u/hRDXLlx+vBwW0IXyYpEC7+GWkTTQmq+y2pxmgDNk2dGyoJH1zyY7Y/5lTSvMB9LM685cw/+XoX50GOUI+XlTqT9XaeHwjqg7H545cTBHwZmYhWIR3TX1nwuK2Tiyz85RACvGRh8aTFcMB7+b77XJoZa19n1x97CwjX7/A==; Original-Received: from [199.201.65.2] (helo=[172.30.31.126]) by dancol.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84) (envelope-from ) id 1Xmn3V-0003wU-6l; Fri, 07 Nov 2014 09:10:37 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 In-Reply-To: <20141107165551.GA2865@acm.acm> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2600:3c01::f03c:91ff:fedf:adf3 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 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-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:176539 Archived-At: This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --Ra7PIw8bFSDpf5ih7NeWWhCsMBfLKDBaw Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 11/07/2014 04:55 PM, Alan Mackenzie wrote: > Hello, Stefan. >=20 > On Fri, Nov 07, 2014 at 09:59:12AM -0500, Stefan Monnier wrote: >>> The advantage of hooks is that it makes it easier for users to >>> customize the behavior by adding and removing various entries. >=20 >> While it's true that >=20 >> (add-hook 'next-error-functions #'my-function) >=20 >> is shorter than >=20 >> (add-function :before-until next-error-function #'my-function) >=20 >> I don't think it warrants the addition of a next-error-functions. >=20 > Why not? >=20 >> If the :before-until is the problematic part, then I guess we should >> look for ways to improve that (e.g. a better name, or some way for >> a variable to say that :before-until is the default when adding >> functions to it?). >=20 >>> Is add-function intended to replace hooks like this in general? >=20 >> Somewhat, yes. I have no intention to go around and replace existing >> hooks in the forseeable future (except for those rare hooks that used >> with-wrapper-hook), but I'll favor new foo-function over new >> foo-functions. >=20 > Why? I'm adding my voice to the clamour of dissent. >=20 > It would seem that the use of single functions, with `add-function' is > inferior to the conventional hook mechanism in every way. What am I > missing? In addition to the things cited by Daniel, there's: >=20 > (i) the danger (near certainty) that somebody is going to use `setq' > rather than `add-function' to configure it; The same critique applies to regular hooks, doesn't it? > (ii) the additional incompatibility with other Emacsen; I'm not sure that compatibility with other Emacsen is as important as it once was. AIUI, GNU Emacs is receiving the vast majority of development effort. > (iii) the difficulty (or perhaps clumsiness) in looking at the contents= > of an advised function. There would seem to be nothing equivalent to > M-: after-change-functions. >=20 > So why are you changing from the conventional hook mechanism, which wor= ks > so well? What is the advantage of the new scheme. >=20 > Incidentally, I had a look at the documentation for add-advice, and > there's a problem with it. "Advice" in English has no plural - there's= > no such word as "advices". If it's necessary to emphasize the pluralit= y, > then "pieces of advice" can be used. There's no such thing as "an > advice", rather you'd say "some advice". It's a bit like you wouldn't > refer to a lake as "a big water"; you'd say it contains "a lot of water= ". > I think there's a term in linguistics for such a word, but I don't know= > it off hand. I think "advise" works like "code" in the software sense and "furniture". The term is "mass noun". > Incidentally 2, the verb corresponding to the noun "advice" is "to > advise". Isn't English fun? --Ra7PIw8bFSDpf5ih7NeWWhCsMBfLKDBaw Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCAAGBQJUXP0FAAoJEN4WImmbpWBliKQP/iIbgGuOwClqU3mxsBLDXYlH wsblq2yoWZruMAIveqstuyHmqUx9iHNrjDoztjeJNWqB5n2Eb4pvxo26hmKS4msE LCR28XPc/tDpVI6ry3DMl3viyoJSW4whF4Ki6/uOm/2K5GViGVImODS0OZv/8AI7 qkPCIiAkSeLY+ZR8Z86GgdlF01ZIgiuVaD7m7MhSSgLxWmaC+bRj0UA/Qr2PgT7O jTAu99Ht3KZ7fkTqGbtqU/Kk+LhzxfMaHw5azUTsK+kcIk66cHKPXFpGEnbUtbxz rzB21bU1I18ZqHQq86Kzf8ebeoWyN5DjG7/ycDYLe/cDpxgvTIs/3h3MIJBgDG+0 sfuLHy74g9oM+KST7EK0m/cDcQ3LvZGXeksg83Wsx77fur+EbXT7af6QDhpilmZb VsCO0sJDJ9UhblT/eaJoi2gP8R2mqoAwZgOWYsgxMJxCU07iB1neqZSghrQSC3p0 IMwbfB3DgyE3LWwUSMnsIupr2ClWLskoC0708LOhRT3ZD7vOBPRneTabbIac6UhB CyBn5eBgwi3uSbQXBp0dyO4S4PcAHwcN9vfrkFnbJ0styPGqt/yZz27XoMz/lWKq XlcyGOMvxA9d4jx1TJWW80HpaqK79VCUCJSTNsnx4BdbrI4C4/Ox+rBR6LQo3q6H jX/R5BL6BResCAHTxaZh =D9pT -----END PGP SIGNATURE----- --Ra7PIw8bFSDpf5ih7NeWWhCsMBfLKDBaw--