From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Artur Malabarba Newsgroups: gmane.emacs.devel Subject: Re: Proposed new core library: alert.el Date: Fri, 6 Nov 2015 10:42:29 +0000 Message-ID: References: <87io5g2po3.fsf@lifelogs.com> <87egg31muc.fsf@gmx.us> Reply-To: bruce.connor.am@gmail.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a11401f8a79b04d0523dce671 X-Trace: ger.gmane.org 1446806572 10402 80.91.229.3 (6 Nov 2015 10:42:52 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 6 Nov 2015 10:42:52 +0000 (UTC) Cc: emacs-devel To: Rasmus Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Nov 06 11:42:52 2015 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 1ZueTp-0004Ls-C9 for ged-emacs-devel@m.gmane.org; Fri, 06 Nov 2015 11:42:49 +0100 Original-Received: from localhost ([::1]:37828 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZueTo-0006d1-56 for ged-emacs-devel@m.gmane.org; Fri, 06 Nov 2015 05:42:48 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33441) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZueTY-0006cw-AI for emacs-devel@gnu.org; Fri, 06 Nov 2015 05:42:33 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZueTX-00010g-Cg for emacs-devel@gnu.org; Fri, 06 Nov 2015 05:42:32 -0500 Original-Received: from mail-lf0-x22e.google.com ([2a00:1450:4010:c07::22e]:35333) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZueTX-00010b-4r for emacs-devel@gnu.org; Fri, 06 Nov 2015 05:42:31 -0500 Original-Received: by lfbn126 with SMTP id n126so70471737lfb.2 for ; Fri, 06 Nov 2015 02:42:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:sender:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=O46xr6pXiSW6D2QcvBMxxV1T7Bn1PA5xoR+vP1PNoUI=; b=N9gl3bLVBwpYfbCsw3u1fH5g2/Cqxk5VFEpsotuAuaadjERW0LmbBr59LC1jhug+1v lyGGiRMgdcs+NnimhZ9Nx4EogzOmDxCcIZARaK7NRTRtMMxNtkJLsFy6zhGp80gvlMTE c4s+t2U2d9dp0ngJn399UqCfr/rFYp118ALdECU6kuv5glRNLKhxAUPVQML28VO13Xpq SvnaLTXMal+RMrOtcYoUjcHLH9ZCItGtBuRHQktvMNstyDT/WpspAYtYGQnlFyQwetV5 Y+w4xuvX/+vAfNyDeDylx2/NJBQHLcaFs0HkDl84JgYOFlvnWSLLEEqvxYH7zs7bbhri YA+Q== X-Received: by 10.25.141.77 with SMTP id p74mr3844077lfd.17.1446806550063; Fri, 06 Nov 2015 02:42:30 -0800 (PST) Original-Received: by 10.112.63.70 with HTTP; Fri, 6 Nov 2015 02:42:29 -0800 (PST) Original-Received: by 10.112.63.70 with HTTP; Fri, 6 Nov 2015 02:42:29 -0800 (PST) In-Reply-To: <87egg31muc.fsf@gmx.us> X-Google-Sender-Auth: 3rGFTIY4Tm0sbOjmmBNd6fgV-rA X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c07::22e 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:193396 Archived-At: --001a11401f8a79b04d0523dce671 Content-Type: text/plain; charset=UTF-8 On 6 Nov 2015 9:47 am, "Rasmus" wrote: > > John Wiegley writes: > > >>>>>> raman writes: > > > >> You could do this seamlessly by attaching an around advice to message and > >> having that call alert > > > > Advice is only to be used by user code, not in core. It's the "last line" of > > customization, but shouldn't be a programming style for developers. > > A rgrep on the lisp dir suggests that add-function is used 60 places. > AFAIK, one of the intentions of nadvice is to easily attach new functions > to "places", also in core. But I could easily be wrong. add-function is about modifying function variables (i.e., places that are actually supposed to be configurable). It is not about advices. I believe you're thinking of add-advice. --001a11401f8a79b04d0523dce671 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

On 6 Nov 2015 9:47 am, "Rasmus" <rasmus@gmx.us> wrote:
>
> John Wiegley <jwiegley@gmail.= com> writes:
>
> >>>>>> raman=C2=A0 <raman@google.com> writes:
> >
> >> You could do this seamlessly by attaching an around advice to= message and
> >> having that call alert
> >
> > Advice is only to be used by user code, not in core. It's the= "last line" of
> > customization, but shouldn't be a programming style for devel= opers.
>
> A rgrep on the lisp dir suggests that add-function is used 60 places.<= br> > AFAIK, one of the intentions of nadvice is to easily attach new functi= ons
> to "places", also in core.=C2=A0 But I could easily be wrong= .

add-function is about modifying function variables (i.e., pl= aces that are actually supposed to be configurable). It is not about advice= s.

I believe you're thinking of add-advice.

--001a11401f8a79b04d0523dce671--