From unknown Sun Aug 10 09:46:44 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#16949 <16949@debbugs.gnu.org> To: bug#16949 <16949@debbugs.gnu.org> Subject: Status: 24.3; [PATCH] insert-pair now leaves the point where the docstring says it should Reply-To: bug#16949 <16949@debbugs.gnu.org> Date: Sun, 10 Aug 2025 16:46:44 +0000 retitle 16949 24.3; [PATCH] insert-pair now leaves the point where the docs= tring says it should reassign 16949 emacs submitter 16949 Dima Kogan severity 16949 normal tag 16949 patch fixed thanks From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 06 02:26:40 2014 Received: (at submit) by debbugs.gnu.org; 6 Mar 2014 07:26:40 +0000 Received: from localhost ([127.0.0.1]:52298 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WLShT-0007Od-Hq for submit@debbugs.gnu.org; Thu, 06 Mar 2014 02:26:40 -0500 Received: from eggs.gnu.org ([208.118.235.92]:37102) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WLSYW-00078i-GS for submit@debbugs.gnu.org; Thu, 06 Mar 2014 02:17:25 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WLSYP-0002EY-M0 for submit@debbugs.gnu.org; Thu, 06 Mar 2014 02:17:24 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.5 required=5.0 tests=BAYES_05,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:56693) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLSYP-0002EU-Is for submit@debbugs.gnu.org; Thu, 06 Mar 2014 02:17:17 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38796) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLSYJ-0000mp-Oe for bug-gnu-emacs@gnu.org; Thu, 06 Mar 2014 02:17:17 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WLSYE-0002Cs-1O for bug-gnu-emacs@gnu.org; Thu, 06 Mar 2014 02:17:11 -0500 Received: from out3-smtp.messagingengine.com ([66.111.4.27]:46789) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WLSYD-0002Cj-TE for bug-gnu-emacs@gnu.org; Thu, 06 Mar 2014 02:17:05 -0500 Received: from compute4.internal (compute4.nyi.mail.srv.osa [10.202.2.44]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id 25E2620970 for ; Thu, 6 Mar 2014 02:17:04 -0500 (EST) Received: from frontend2 ([10.202.2.161]) by compute4.internal (MEProxy); Thu, 06 Mar 2014 02:17:04 -0500 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:subject:date:message-id :mime-version:content-type; s=smtpout; bh=h4ZClIPVadZ+tfaxorg3Iz SymOk=; b=CTNqLk31dmicQSJGa2hM5vKhK+QHhwwPYXWtv4YBAvhow36dUtWrJw XdlxKTUhrfa7zGJ71CqH76jtSrCu6nb6VEwZLML8hpNKRpuL46bTGlj2NmmFGmIE zSFBFPNMibir5gZ/5zAYDL5escpoLp+TRlxSNmf+bmlYBxM6TpW1k= X-Sasl-enc: 0alj7BVlaL1INlpXFE5hgWaApwUuK+ByZWvotOqOsqwu 1394090223 Received: from shorty.local (unknown [23.243.199.75]) by mail.messagingengine.com (Postfix) with ESMTPA id E0C3C6800D4 for ; Thu, 6 Mar 2014 02:17:03 -0500 (EST) Received: from dima by shorty.local with local (Exim 4.80) (envelope-from ) id 1WLSYA-0005kM-4d for bug-gnu-emacs@gnu.org; Wed, 05 Mar 2014 23:17:02 -0800 From: Dima Kogan To: bug-gnu-emacs@gnu.org Subject: 24.3; [PATCH] insert-pair now leaves the point where the docstring says it should Date: Wed, 05 Mar 2014 23:17:01 -0800 Message-ID: <87ob1j4x02.fsf@secretsauce.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Thu, 06 Mar 2014 02:26:37 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) --=-=-= Content-Type: text/plain The docstring of insert-pair states that after insertion, the point ends up after the opening character. This was not true if the pair was inserted to surround a region. This small patch fixes it. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-insert-pair-now-behaves-like-its-docstring-says.patch >From 5ae4b68706e4a1c8daa0bb91602a62911c29a9a8 Mon Sep 17 00:00:00 2001 From: Dima Kogan Date: Wed, 5 Mar 2014 23:10:57 -0800 Subject: [PATCH] insert-pair now behaves like its docstring says The docstring of insert-pair states that after insertion, the point ends up after the opening character. This was not true if the pair was inserted to surround a region --- lisp/emacs-lisp/lisp.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/emacs-lisp/lisp.el b/lisp/emacs-lisp/lisp.el index 0487515..420b205 100644 --- a/lisp/emacs-lisp/lisp.el +++ b/lisp/emacs-lisp/lisp.el @@ -536,7 +536,7 @@ This command assumes point is not in a string or comment." (if (and transient-mark-mode mark-active) (progn (save-excursion (goto-char (region-end)) (insert close)) - (save-excursion (goto-char (region-beginning)) (insert open))) + (goto-char (region-beginning)) (insert open)) (if arg (setq arg (prefix-numeric-value arg)) (setq arg 0)) (cond ((> arg 0) (skip-chars-forward " \t")) -- 1.9.0 --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Tue Feb 23 21:55:16 2016 Received: (at 16949) by debbugs.gnu.org; 24 Feb 2016 02:55:16 +0000 Received: from localhost ([127.0.0.1]:41963 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aYPbg-000222-7W for submit@debbugs.gnu.org; Tue, 23 Feb 2016 21:55:16 -0500 Received: from hermes.netfonds.no ([80.91.224.195]:54326) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aYPbe-00021t-Sc for 16949@debbugs.gnu.org; Tue, 23 Feb 2016 21:55:15 -0500 Received: from cpe-60-225-211-161.nsw.bigpond.net.au ([60.225.211.161] helo=mouse) by hermes.netfonds.no with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1aYPbH-0006DM-Pl; Wed, 24 Feb 2016 03:54:52 +0100 From: Lars Ingebrigtsen To: Dima Kogan Subject: Re: bug#16949: 24.3; [PATCH] insert-pair now leaves the point where the docstring says it should References: <87ob1j4x02.fsf@secretsauce.net> Date: Wed, 24 Feb 2016 13:54:47 +1100 In-Reply-To: <87ob1j4x02.fsf@secretsauce.net> (Dima Kogan's message of "Wed, 05 Mar 2014 23:17:01 -0800") Message-ID: <87ziuqn7go.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-MailScanner-ID: 1aYPbH-0006DM-Pl X-Netfonds-MailScanner: Found to be clean X-Netfonds-MailScanner-From: larsi@gnus.org MailScanner-NULL-Check: 1456887292.92528@p1kflPSvI/TmU4lbe+HT1g X-Spam-Status: No X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 16949 Cc: 16949@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.0 (/) Dima Kogan writes: > The docstring of insert-pair states that after insertion, the point ends > up after the opening character. This was not true if the pair was > inserted to surround a region. This small patch fixes it. > >>>From 5ae4b68706e4a1c8daa0bb91602a62911c29a9a8 Mon Sep 17 00:00:00 2001 > From: Dima Kogan > Date: Wed, 5 Mar 2014 23:10:57 -0800 > Subject: [PATCH] insert-pair now behaves like its docstring says > > The docstring of insert-pair states that after insertion, the point > ends up after the opening character. This was not true if the pair was > inserted to surround a region > --- > lisp/emacs-lisp/lisp.el | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lisp/emacs-lisp/lisp.el b/lisp/emacs-lisp/lisp.el > index 0487515..420b205 100644 > --- a/lisp/emacs-lisp/lisp.el > +++ b/lisp/emacs-lisp/lisp.el > @@ -536,7 +536,7 @@ This command assumes point is not in a string or comment." > (if (and transient-mark-mode mark-active) > (progn > (save-excursion (goto-char (region-end)) (insert close)) > - (save-excursion (goto-char (region-beginning)) (insert open))) > + (goto-char (region-beginning)) (insert open)) > (if arg (setq arg (prefix-numeric-value arg)) > (setq arg 0)) > (cond ((> arg 0) (skip-chars-forward " \t")) Thanks; applied to emacs-25. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Tue Feb 23 21:55:03 2016 Received: (at control) by debbugs.gnu.org; 24 Feb 2016 02:55:03 +0000 Received: from localhost ([127.0.0.1]:41960 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aYPbT-00021b-1k for submit@debbugs.gnu.org; Tue, 23 Feb 2016 21:55:03 -0500 Received: from hermes.netfonds.no ([80.91.224.195]:54321) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aYPbR-000219-87 for control@debbugs.gnu.org; Tue, 23 Feb 2016 21:55:01 -0500 Received: from cpe-60-225-211-161.nsw.bigpond.net.au ([60.225.211.161] helo=mouse) by hermes.netfonds.no with esmtpsa (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.72) (envelope-from ) id 1aYPb4-0006Cr-VN for control@debbugs.gnu.org; Wed, 24 Feb 2016 03:54:39 +0100 Date: Wed, 24 Feb 2016 13:54:35 +1100 Message-Id: <871t82om1g.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #16949 X-MailScanner-ID: 1aYPb4-0006Cr-VN X-Netfonds-MailScanner: Found to be clean X-Netfonds-MailScanner-From: larsi@gnus.org MailScanner-NULL-Check: 1456887280.06841@PgWqJjM2CjI4O0S/0kmnzA X-Spam-Status: No X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.0 (/) tags 16949 fixed close 16949 25.1 From unknown Sun Aug 10 09:46:44 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 23 Mar 2016 11:24:06 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator