GNU bug report logs - #33414
27.0.50; inhibit-changing-match-data can be t in syntax-propertize functions, breaking backtrace and looking-at

Previous Next

Package: emacs;

Reported by: Pip Cet <pipcet <at> gmail.com>

Date: Sat, 17 Nov 2018 13:31:02 UTC

Severity: normal

Found in version 27.0.50

Fixed in version 29.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: p.stephani2 <at> gmail.com, 33414 <at> debbugs.gnu.org, pipcet <at> gmail.com
Subject: bug#33414: 27.0.50; inhibit-changing-match-data can be t in syntax-propertize functions, breaking backtrace and looking-at
Date: Sun, 05 Sep 2021 11:45:50 +0200
Eli Zaretskii <eliz <at> gnu.org> writes:

> FWIW, I don't share the above view.  We bind variables to affect
> behavior of functions all over the place, and that is perfectly okay,
> IMO.

This one leads to really hard to debug problems, though.

>> -@defun looking-at regexp
>> +@defun looking-at regexp &optional inhibit-save
>                                       ^^^^^^^^^^^^
> A typo?

Yup.  I changed the name of these parameters five times while writing
the patch.

>> +(make-obsolete-variable 'inhibit-changing-match-data nil "28.1")
>
> Really? why obsolete it?

Because it's not used (and shouldn't be used).  `save-match-data' is the
proper way to achieve this in normal code.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




This bug report was last modified 3 years and 287 days ago.

Previous Next


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