[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re:
From: |
Eli Zaretskii |
Subject: |
bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks) |
Date: |
Wed, 20 Jul 2016 17:55:11 +0300 |
> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: rpluim@gmail.com, 23917@debbugs.gnu.org, alex.bennee@linaro.org,
> jwiegley@gmail.com, nljlistbox2@gmail.com
> Date: Tue, 19 Jul 2016 21:50:07 -0400
>
> > Do we care that using save-match-data in every call to replace-match
> > might mean a performance hit?
>
> I do but:
> - to be honest, it's probably lost in the noise.
> - if we copy search_regs.start and search_regs.end with something like
> alloca+memcpy (instead of calling Fmatch_data), the cost should be even more
> lost in the noise. Especially if you consider that the current code
> already loops through the match-data to adjust it.
> - it's the best fix we've found so far.
What about Noam's suggestion:
> Is it not possible to adjust the match data *before* calling buffer
> modification hooks? Seems to me the root of the problem is that buffer
> modification hooks get to see this invalid intermediate state where the
> match data is out of sync with the buffer.
Is it OK to adjust the match data before actually making the
replacement? If so, I think it's a simpler solution.
> PS: I can think of one (theoretical) other/better way to fix this
> problem: move the match-data adjustment so it's done within
> replace_range before running the after-change-functions.
Isn't that almost the same as what Noam suggested?
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), (continued)
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Stefan Monnier, 2016/07/19
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Eli Zaretskii, 2016/07/19
- bug#23917: [O] bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Alex Bennée, 2016/07/19
- bug#23917: [O] bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Eli Zaretskii, 2016/07/19
- bug#23917: [O] bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Alex Bennée, 2016/07/19
- bug#23917: [O] bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Eli Zaretskii, 2016/07/19
- bug#23917: [O] bug#23917: bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Alex Bennée, 2016/07/20
- bug#23917: [O] bug#23917: bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Eli Zaretskii, 2016/07/20
- bug#23917: [O] bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Sebastian Wiesner, 2016/07/19
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Stefan Monnier, 2016/07/19
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks),
Eli Zaretskii <=
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Stefan Monnier, 2016/07/20
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Eli Zaretskii, 2016/07/20
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Stefan Monnier, 2016/07/20
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), npostavs, 2016/07/20
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Stefan Monnier, 2016/07/20
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Noam Postavsky, 2016/07/20
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Stefan Monnier, 2016/07/20
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Eli Zaretskii, 2016/07/20
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), npostavs, 2016/07/20
- bug#23917: Please consider making Bug #23917 a blocker for 25.1 (was Re: org-capture: Capture template ‘g’: Match data clobbered by buffer modification hooks), Eli Zaretskii, 2016/07/21