Gnus development mailing list
 help / color / mirror / Atom feed
From: prj@po.cwru.edu (Paul Jarc)
Subject: Re: gnus-split-references tweak
Date: Thu, 07 Feb 2002 11:30:50 -0500	[thread overview]
Message-ID: <m3ofj15k4v.fsf@multivac.cwru.edu> (raw)
In-Reply-To: <m3adum2grn.fsf@defun.localdomain> (Jesper Harder's message of "Thu, 07 Feb 2002 02:59:56 +0100")

Jesper Harder <harder@ifa.au.dk> wrote:
> prj@po.cwru.edu (Paul Jarc) writes:
>> -      (when (string-match "<[^> \t]+>\\'" references)
>> -       (match-string 0 references)))))
>> +      (when (string-match "\(<[^<]+[^< \t]\)[ \t]*\\'" references)
>> +       (match-string 1 references)))))
>
> You missed a couple of backslashes in the regexp, it should be
>
>   "\\(<[^<]+[^< \t]\\)[ \t]*\\'"

Not my day.  And yet somehow it seems to work anyway.  Weird.

> I think this one:
>
>       (when (string-match "\\(<[^>]+>\\)[ \t]*\\'" references)
> 	(match-string 1 references)))))
>
> is more efficient -- the performance penalty was only about 2%.

Yeah, that should be ok.  I've sometimes seen References fields
truncated in the missle of a Message-ID, and this regexp won't find
the last, partial one, but that's ok because the partial one wouldn't
have matched any message's Message-ID anyway.


paul



  reply	other threads:[~2002-02-07 16:30 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-02-06 18:55 Paul Jarc
2002-02-06 20:50 ` Paul Jarc
2002-02-06 20:50   ` Jesper Harder
2002-02-06 21:32     ` Paul Jarc
2002-02-07  1:59       ` Jesper Harder
2002-02-07 16:30         ` Paul Jarc [this message]
2002-02-07 20:06         ` Paul Jarc

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=m3ofj15k4v.fsf@multivac.cwru.edu \
    --to=prj@po.cwru.edu \
    /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).