From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Pip Cet Newsgroups: gmane.emacs.bugs Subject: bug#36190: 27.0.50; `put-text-property' etc. with buffer argument calls current buffer's `after-change-functions' Date: Fri, 14 Jun 2019 11:14:53 +0000 Message-ID: References: <83h88tzbly.fsf@gnu.org> <835zp9z4oj.fsf@gnu.org> <83y325xnk0.fsf@gnu.org> <83k1doy5om.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="000000000000a62ecb058b46c3ce" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="250993"; mail-complaints-to="usenet@blaine.gmane.org" Cc: 36190@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Jun 14 13:16:50 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1hbkCQ-00136v-Ca for geb-bug-gnu-emacs@m.gmane.org; Fri, 14 Jun 2019 13:16:50 +0200 Original-Received: from localhost ([::1]:50208 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hbkCO-0002UA-7h for geb-bug-gnu-emacs@m.gmane.org; Fri, 14 Jun 2019 07:16:48 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35846) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hbkC1-0002RF-G7 for bug-gnu-emacs@gnu.org; Fri, 14 Jun 2019 07:16:28 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hbkBf-0002jr-1T for bug-gnu-emacs@gnu.org; Fri, 14 Jun 2019 07:16:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:51314) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hbkBe-0002jW-LT for bug-gnu-emacs@gnu.org; Fri, 14 Jun 2019 07:16:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hbkBe-0000g1-Cb for bug-gnu-emacs@gnu.org; Fri, 14 Jun 2019 07:16:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Pip Cet Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 14 Jun 2019 11:16:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 36190 X-GNU-PR-Package: emacs Original-Received: via spool by 36190-submit@debbugs.gnu.org id=B36190.15605109392564 (code B ref 36190); Fri, 14 Jun 2019 11:16:02 +0000 Original-Received: (at 36190) by debbugs.gnu.org; 14 Jun 2019 11:15:39 +0000 Original-Received: from localhost ([127.0.0.1]:36625 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hbkBG-0000fH-Cy for submit@debbugs.gnu.org; Fri, 14 Jun 2019 07:15:38 -0400 Original-Received: from mail-oi1-f171.google.com ([209.85.167.171]:41175) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hbkBD-0000f3-Mn for 36190@debbugs.gnu.org; Fri, 14 Jun 2019 07:15:36 -0400 Original-Received: by mail-oi1-f171.google.com with SMTP id g7so1667186oia.8 for <36190@debbugs.gnu.org>; Fri, 14 Jun 2019 04:15:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=r0obNx3DxGcuS03YrIpM3uSPq3g0XalXl701oKp3TqY=; b=keFJM0E2cqrGibEayQ4cL0B0X410pzip+7JZI0A+vN4lgj4gyaeJyeLd9lKTvM2yOD LE52DHJieQOVB8aD/xiLwp8IfeOdQYs1fiHonCSN7bMDZGAwudy/SjtLHn7HrixuOCFX 89vx+b4yNgBmbW03wzl4MtXGESx4XJDWuh/saVvSVq9HLKjfWhsVjrK8qdGGyt/QfDPX teAZKdLwAvg4x20GqXExJYANAi/I1sqob2e7uKVtQpnPnIthPNu2ZmdE6dZSm8qmssfm DNJtUFXwQmArLEAQIWQa9pdOxExEIaxaEQDmkODPsz6cNd1Xs57Qz68AEwu+jv2GjmpI v0fg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=r0obNx3DxGcuS03YrIpM3uSPq3g0XalXl701oKp3TqY=; b=tSAHg9dcmnfHnGCJuzXExHNotIIJJMCLVWEvw1ZYeDhMzzsb1oCmLKR+YIh8s801g6 GnxIDvTiRcUFmDfR5ToHPessH6YK+4EEo9tDuEbnn/POARKKTA8vz/BH6JwOEGGsTxnv J+rZlTnCpIkxvKwweo2HTf1WF/i1cpwaIqj+poOZYBvx5MpAIclgUbPApSdRI0blHLLN /hWaWb03gCWku/PigEecG+rFntBLuJAHdBUCnLG7BDnD7uvG/lBhFVKD+NsPbuC+C9vd v0ssOcxpUaGqYoHX3yP1cgd6PtE3TWRZRdwYJcyq3gCS4Gya00OKKjFwjI8km2u0JXKP ZtFg== X-Gm-Message-State: APjAAAUc7ebm/etSKWkm8d6+/OApHyqmYTVen2uYEYBcO/m3v/41S58u RsGYwUhul8HA0/HUPD+3+7OBizxP9IVZI/oP4rU= X-Google-Smtp-Source: APXvYqy9+HfrzLA+Ytr4JagrjzLaZtxzzz+Ji9xjvF/5xHfj7srtcJnPg8xIqaIDuL1K7CrmDPhTR0Td0TVSBOkRaCM= X-Received: by 2002:aca:dcd7:: with SMTP id t206mr1524121oig.30.1560510929963; Fri, 14 Jun 2019 04:15:29 -0700 (PDT) In-Reply-To: <83k1doy5om.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 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.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:160548 Archived-At: --000000000000a62ecb058b46c3ce Content-Type: text/plain; charset="UTF-8" On Fri, Jun 14, 2019 at 7:41 AM Eli Zaretskii wrote: > > > From: Pip Cet > > Date: Thu, 13 Jun 2019 21:37:40 +0000 > > Cc: 36190@debbugs.gnu.org > > > > +/* Signal a change immediately after it happens. > > + BUFFER is the buffer in which the change happened. > > + CHARPOS is the character position of the start of the changed text. > > + LENDEL is the number of characters of the text before the change. > > + (Not the whole buffer; just the part that was changed.) > > + LENINS is the number of characters in that part of the text > > + after the change. */ > > I would just say "Like signal_after_change, but ..." and describe only > the BUFFER argument. > > > +void > > +signal_after_change_in_buffer (struct buffer *buffer, ptrdiff_t charpos, ptrdiff_t lendel, ptrdiff_t lenins) > > +{ > > + ptrdiff_t count = SPECPDL_INDEX (); > > + > > + record_unwind_current_buffer (); > > + set_buffer_internal (buffer); > > + signal_after_change (charpos, lendel, lenins); > > + unbind_to (count, Qnil); > > +} > > I still think we should explicitly detect the current_buffer case here > and if so, avoid the calls to everything else except > signal_after_change itself. > > But I indeed like this patch better, although the concerns over the > performance hit are still present. Thanks. Okay, I fixed those two issues. As for the performance problem, should we amend the documentation to state that if many changes are made, it's better to use `with-current-buffer' instead of repeatedly calling put-text-property with a buffer argument? --000000000000a62ecb058b46c3ce Content-Type: text/x-patch; charset="US-ASCII"; name="0001-Switch-to-correct-buffer-in-put-text-property-etc.patch" Content-Disposition: attachment; filename="0001-Switch-to-correct-buffer-in-put-text-property-etc.patch" Content-Transfer-Encoding: base64 Content-ID: X-Attachment-Id: f_jwvzndou0 RnJvbSBiMjNlYmU0NTE2NjRiMGY1MGEwMmZiMmU0ZWU1YTQxODc3ZGZlMzJkIE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBQaXAgQ2V0IDxwaXBjZXRAZ21haWwuY29tPgpEYXRlOiBGcmks IDE0IEp1biAyMDE5IDExOjA1OjMxICswMDAwClN1YmplY3Q6IFtQQVRDSF0gU3dpdGNoIHRvIGNv cnJlY3QgYnVmZmVyIGluIHB1dC10ZXh0LXByb3BlcnR5IGV0Yy4KCiogc3JjL3RleHRwcm9wLmMg KGFkZF90ZXh0X3Byb3BlcnRpZXNfMSwgc2V0X3RleHRfcHJvcGVydGllcykKKEZyZW1vdmVfdGV4 dF9wcm9wZXJ0aWVzLCBGcmVtb3ZlX2xpc3Rfb2ZfdGV4dF9wcm9wZXJ0aWVzKToKdXNlIGBzaWdu YWxfYWZ0ZXJfY2hhbmdlX2luX2J1ZmZlcicuCiogc3JjL2luc2RlbC5jIChzaWduYWxfYWZ0ZXJf Y2hhbmdlX2luX2J1ZmZlcik6IE5ldyBmdW5jdGlvbi4KLS0tCiBzcmMvaW5zZGVsLmMgICB8IDE2 ICsrKysrKysrKysrCiBzcmMvbGlzcC5oICAgICB8ICAxICsKIHNyYy90ZXh0cHJvcC5jIHwgNzMg KysrKysrKysrKysrKysrKysrKysrKysrKysrLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0KIDMgZmls ZXMgY2hhbmdlZCwgNTcgaW5zZXJ0aW9ucygrKSwgMzMgZGVsZXRpb25zKC0pCgpkaWZmIC0tZ2l0 IGEvc3JjL2luc2RlbC5jIGIvc3JjL2luc2RlbC5jCmluZGV4IDg1ZmZmZDhmZDEuLjQ5YWNhOTRl MDMgMTAwNjQ0Ci0tLSBhL3NyYy9pbnNkZWwuYworKysgYi9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mVfbGlzdF9vZl90ZXh0X3Byb3Bl cnRpZXMsCiAgICAgICBsZW4gLT0gTEVOR1RIIChpKTsKICAgICAgIGkgPSBuZXh0X2ludGVydmFs IChpKTsKICAgICAgIGlmICghaSkKLSAgICAgICAgewotICAgICAgICAgIGlmIChtb2RpZmllZCkK LSAgICAgICAgICAgIHsKLSAgICAgICAgICAgICAgaWYgKEJVRkZFUlAgKG9iamVjdCkpCi0gICAg ICAgICAgICAgICAgc2lnbmFsX2FmdGVyX2NoYW5nZSAoWEZJWE5VTSAoc3RhcnQpLAotICAgICAg ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIFhGSVhOVU0gKGVuZCkgLSBYRklYTlVNIChz dGFydCksCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgWEZJWE5VTSAoZW5k KSAtIFhGSVhOVU0gKHN0YXJ0KSk7Ci0gICAgICAgICAgICAgIHJldHVybiBRdDsKLSAgICAgICAg ICAgIH0KLSAgICAgICAgICBlbHNlCi0gICAgICAgICAgICByZXR1cm4gUW5pbDsKLSAgICAgICAg fQorCXsKKwkgIGlmIChtb2RpZmllZCkKKwkgICAgeworCSAgICAgIGlmIChCVUZGRVJQIChvYmpl Y3QpKQorCQlzaWduYWxfYWZ0ZXJfY2hhbmdlX2luX2J1ZmZlciAoWEJVRkZFUiAob2JqZWN0KSwg WEZJWE5VTSAoc3RhcnQpLAorCQkJCQkgICAgICAgWEZJWE5VTSAoZW5kKSAtIFhGSVhOVU0gKHN0 YXJ0KSwKKwkJCQkJICAgICAgIFhGSVhOVU0gKGVuZCkgLSBYRklYTlVNIChzdGFydCkpOworCSAg ICAgIHJldHVybiBRdDsKKwkgICAgfQorCSAgZWxzZQorCSAgICByZXR1cm4gUW5pbDsKKwl9CiAg ICAgfQogfQogDAotLSAKMi4yMC4xCgo= --000000000000a62ecb058b46c3ce--