From: Jim Meyering <meyering@ascend.com>
Cc: ding@gnus.org
Subject: string-match doesn't honor anchor when START is nonzero
Date: 25 Jan 2000 22:20:39 +0100 [thread overview]
Message-ID: <uryk8kxrgpk.fsf@ixi.eng.ascend.com> (raw)
In GNU Emacs 20.5.1 (i686-pc-linux-gnu, X toolkit)
of Fri Dec 10 1999 on ixi.eng.ascend.com
configured using `configure --prefix=/p/p/emacs-20.5'
------------
The following seems to be at the root of a problem I noticed in Gnus.
Is it expected that this would evaluate to nil? (it does)
(string-match "^j" " j" 1)
I expected it to return `1', but the `^' gets in the way.
The documentation for string-match doesn't address this point
as far as I could see.
If returning `nil' is the intended behavior, then there's a bug in
mail-utils.el (rmail-dont-reply-to) because it seems to expect `1' and
fails when it gets the `nil'. The result is that that function removes
only one of two matching, adjacent addresses.
This illustrates the problem:
(setq rmail-dont-reply-to-names "f.")
(load "mail-utils")
(rmail-dont-reply-to "b, f1, f2, f3, f4, f5, f6")
Return value: "b, f2, f4, f6"
It should be
Return value: "b"
next reply other threads:[~2000-01-25 21:20 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2000-01-25 21:20 Jim Meyering [this message]
2000-01-26 14:42 ` Richard Stallman
2000-01-26 15:08 ` Jim Meyering
2000-01-26 16:07 ` Gerd Moellmann
2000-01-26 16:34 ` Jim Meyering
2000-01-27 12:53 ` Gerd Moellmann
2000-01-27 16:30 ` Jim Meyering
2000-02-09 18:22 ` mail-utils.el (rmail-dont-reply-to) is still buggy Jim Meyering
2000-02-12 16:43 ` Gerd Moellmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=uryk8kxrgpk.fsf@ixi.eng.ascend.com \
--to=meyering@ascend.com \
--cc=ding@gnus.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).