From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Newsgroups: gmane.emacs.bugs Subject: bug#52003: Unexpected advising behavior due to recursive implementation Date: Sun, 21 Nov 2021 12:08:39 +0100 Message-ID: References: <43094E20-7F74-4CE0-ABE7-4348ADFFFCE0@acm.org> Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.21\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35690"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 52003@debbugs.gnu.org To: Daniel Sausner Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Nov 21 12:09:12 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mokie-00097Q-42 for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 21 Nov 2021 12:09:12 +0100 Original-Received: from localhost ([::1]:57936 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mokic-0002gi-ON for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 21 Nov 2021 06:09:10 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:39116) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mokiU-0002gW-Cd for bug-gnu-emacs@gnu.org; Sun, 21 Nov 2021 06:09:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:32778) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mokiU-0006AF-4P for bug-gnu-emacs@gnu.org; Sun, 21 Nov 2021 06:09:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mokiT-0003li-Q8 for bug-gnu-emacs@gnu.org; Sun, 21 Nov 2021 06:09:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Mattias =?UTF-8?Q?Engdeg=C3=A5rd?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 21 Nov 2021 11:09:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 52003 X-GNU-PR-Package: emacs Original-Received: via spool by 52003-submit@debbugs.gnu.org id=B52003.163749293414468 (code B ref 52003); Sun, 21 Nov 2021 11:09:01 +0000 Original-Received: (at 52003) by debbugs.gnu.org; 21 Nov 2021 11:08:54 +0000 Original-Received: from localhost ([127.0.0.1]:44323 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mokiL-0003lI-N7 for submit@debbugs.gnu.org; Sun, 21 Nov 2021 06:08:53 -0500 Original-Received: from mail1467c50.megamailservers.eu ([91.136.14.67]:43408 helo=mail268c50.megamailservers.eu) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mokiI-0003l1-HF for 52003@debbugs.gnu.org; Sun, 21 Nov 2021 06:08:51 -0500 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1637492923; bh=rXDPSHp8kZ7nKavabdhllPp7p/5m9yIl1TelVx3Sna4=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=r6XzKI1tOYShvvOg1QP1mGDpXiz5lwz2/tQAwgLyV9y+6qxw7jhgonvCfJYp0K6J1 mrVzvwfTxgSWI3Mij52GsWldoc631hCXBAxSRuLcuy1fe8Zhsdz2zMj/lmWrMh1W+d EdDjeBVba8c9rHBfqG4VRVxr9gjU8yV10H+v7Pys= Feedback-ID: mattiase@acm.or Original-Received: from [192.168.0.4] (c188-150-171-71.bredband.tele2.se [188.150.171.71]) (authenticated bits=0) by mail268c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id 1ALB8efB025026; Sun, 21 Nov 2021 11:08:42 +0000 In-Reply-To: X-Mailer: Apple Mail (2.3445.104.21) X-CTCH-RefID: str=0001.0A742F1C.619A28BA.0087, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CSC: 0 X-CHA: v=2.4 cv=B8LabMhM c=1 sm=1 tr=0 ts=619a28bb a=SF+I6pRkHZhrawxbOkkvaA==:117 a=SF+I6pRkHZhrawxbOkkvaA==:17 a=kj9zAlcOel0A:10 a=M51BFTxLslgA:10 a=zZOMBPAxS-NNN_PNjq0A:9 a=CjuIK1q_8ugA:10 X-Origin-Country: SE X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:220554 Archived-At: 21 nov. 2021 kl. 10.32 skrev Daniel Sausner : > I see. I somehow assumed that functions at that level would aim to be = compliant to the max. Yes but what would that mean? The best we can do is to promise that a = function F, when called in a manner consistent with the documentation, = behaves accordingly. We cannot guarantee the absence of calls to F, can = we? But unless I'm mistaken, that's what you are unhappy about: = `forward-sexp` may call itself when you call it. A lot of other code = calls that function as part of their implementation. Don't they cause = trouble, or is it just the recursive call? > Well, I'd say that in that case the non-interactive performance = outweighs this particular corner case of advising these core functions, = which I came to understand is a hot iron. The cost of that extra function call is probably going to be lost in the = noise. I'm not looking for excuses to avoid work here but would like to = know what problem rearranging the code would actually solve.=20 > Therefore I'd say this bug report can be closed from my point of view. = I guess I still have to use advising as I currently see no other = feasible way out, but I can make it sensitive to `interactive` as well. What are you trying to do? Can't you define a mode-specific = forward-sexp-function?