GNU bug report logs - #76313
New function `replace-region`

Previous Next

Package: emacs;

Reported by: Stefan Monnier <monnier <at> iro.umontreal.ca>

Date: Sat, 15 Feb 2025 22:19:02 UTC

Severity: normal

Tags: patch

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Subject: bug#76313: closed (Re: bug#76313: New function `replace-region`)
Date: Tue, 18 Feb 2025 20:05:02 +0000
[Message part 1 (text/plain, inline)]
Your bug report

#76313: New function `replace-region`

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to 76313 <at> debbugs.gnu.org.

-- 
76313: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=76313
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 76313-done <at> debbugs.gnu.org
Subject: Re: bug#76313: New function `replace-region`
Date: Tue, 18 Feb 2025 15:04:22 -0500
> So basically, you reject every attempt to compromise that I could come
> up with, and keep pressing for your original proposal, whose downsides
> I prefer not to sustain.  Are you really saying that your way is the
> only way? why?

Never mind,


        Stefan


[Message part 3 (message/rfc822, inline)]
From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: bug-gnu-emacs <at> gnu.org
Subject: New function `replace-region`
Date: Sat, 15 Feb 2025 17:18:15 -0500
[Message part 4 (text/plain, inline)]
Tags: patch

We often need to replace a chunk of buffer text with something else.
It is easy enough to do with `insert` + `delete-region`, but that
has suboptimal behavior w.r.t markers, so rather than let coders
reinvent a slightly-better replacement I propose we add a dedicated
function for it.

So I suggest the patch below.  Comments?  Objections?


        Stefan
[replace-region.patch (text/patch, attachment)]

This bug report was last modified 75 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.