[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: replace-regexp
From: |
Stefan Monnier |
Subject: |
Re: replace-regexp |
Date: |
Sat, 08 May 2021 19:11:51 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Emanuel Berg via Users list for the GNU Emacs text editor [2021-05-08 23:54:03]
wrote:
> Stefan Monnier via Users list for the GNU Emacs text editor wrote:
>> My comment wasn't just for regexp-replacement but more
>> generally for operating on a region. So better or not will
>> depend on the specific case. In many cases either way is
>> about as good.
> In general I don't like to use `setq' and in this case it also
You can use (let ((end (copy-marker end t))) ...), of course.
I don't find it cryptic at all, but I'm probably not well placed to judge.
In any case, my main point was that using narrowing can have undesirable
side effects because narrowing has a far-reaching impact on operations
in the buffer, so depending on what you need to do within your loop you
might prefer to stay away from it (unless this far-reaching impact is
exactly what you're looking for, obviously).
Stefan
- Re: replace-regexp, (continued)
- Re: replace-regexp, Emanuel Berg, 2021/05/08
- Re: replace-regexp, Stefan Monnier, 2021/05/08
- Re: replace-regexp, Emanuel Berg, 2021/05/08
- Re: replace-regexp, Tassilo Horn, 2021/05/08
- Re: replace-regexp, Emanuel Berg, 2021/05/08
- RE: [External] : Re: replace-regexp, Drew Adams, 2021/05/08
- Re: replace-regexp, Emanuel Berg, 2021/05/08
- Re: replace-regexp, Emanuel Berg, 2021/05/08
- Re: replace-regexp, Stefan Monnier, 2021/05/08
- Re: replace-regexp, Emanuel Berg, 2021/05/08
- Re: replace-regexp,
Stefan Monnier <=
- Re: replace-regexp, Emanuel Berg, 2021/05/08
- Re: replace-regexp, Stefan Monnier, 2021/05/08
- Re: replace-regexp, Emanuel Berg, 2021/05/08
- Re: replace-regexp, Emanuel Berg, 2021/05/09
- avoid narrow-to-region (was: Re: replace-regexp), Emanuel Berg, 2021/05/08
- Re: avoid narrow-to-region (was: Re: replace-regexp), Yuri Khan, 2021/05/09
- Re: avoid narrow-to-region (was: Re: replace-regexp), Emanuel Berg, 2021/05/09
- Re: avoid narrow-to-region (was: Re: replace-regexp), Yuri Khan, 2021/05/09
- Re: avoid narrow-to-region (was: Re: replace-regexp), Emanuel Berg, 2021/05/09
- Re: avoid narrow-to-region (was: Re: replace-regexp), Jean Louis, 2021/05/09