all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* read-from-minibuffer & match data
@ 2012-12-18 20:06 Joost Kremers
  2012-12-19  0:05 ` Drew Adams
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Joost Kremers @ 2012-12-18 20:06 UTC (permalink / raw)
  To: help-gnu-emacs

Hi,

The other day I started experiencing a problem with code that has been
working just fine for about nine months now. Turns out the problem was
caused by read-from-minibuffer changing the match data. (Basically, I
had a call to read-from-minibuffer after calling string-match and before
calling replace-match.)

Since this code has been working fine for nine months for me and I
haven't had any complaints from others using the code, and since I keep
up-to-date with emacs snapshot releases, I suspect a recent change to
emacs caused this problem.

So now I'm wondering: has there been a recent change to
read-from-minibuffer (or code underlying it) that causes the match data
to change and if so, should this be considered a bug? Or is
read-from-minibuffer simply not guaranteed not to touch the match data,
meaning there is a bug in my code and I have just been lucky that this
hasn't bitten me before?

I've put a save-match-data into the function to solve the issue, but I'd
just like to make sure this isn't a bug in emacs.

TIA

-- 
Joost Kremers                                      joostkremers@yahoo.com
Selbst in die Unterwelt dringt durch Spalten Licht
EN:SiS(9)


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2012-12-20  6:01 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-18 20:06 read-from-minibuffer & match data Joost Kremers
2012-12-19  0:05 ` Drew Adams
2012-12-19  0:48 ` Stefan Monnier
2012-12-19  3:07   ` Drew Adams
2012-12-19  5:05     ` Stefan Monnier
2012-12-19  5:18       ` Drew Adams
     [not found] ` <mailman.15639.1355876062.855.help-gnu-emacs@gnu.org>
2012-12-19 12:26   ` Joost Kremers
2012-12-19 15:56     ` Barry Margolin
2012-12-19 20:43       ` Joost Kremers
2012-12-20  6:01         ` Barry Margolin

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.