emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nicolas Goaziou <mail@nicolasgoaziou.fr>
To: Loris Bennett <loris.bennett@fu-berlin.de>
Cc: emacs-orgmode@gnu.org
Subject: Re: Stackoverflow in regexp matcher
Date: Wed, 03 Feb 2016 12:19:43 +0100	[thread overview]
Message-ID: <87si1a9h2o.fsf@nicolasgoaziou.fr> (raw)
In-Reply-To: <87y4b2qm7h.fsf@hornfels.zedat.fu-berlin.de> (Loris Bennett's message of "Wed, 03 Feb 2016 08:36:50 +0100")

Hello,

"Loris Bennett" <loris.bennett@fu-berlin.de> writes:

>   re-search-forward("^[^%]*\\\\usepackage.*{biblatex}" nil t)

This is a pathological regexp. [^%] is anything but a percent sign, so
it can contain newline characters. Basically [^%]* can match an entire
buffer if it doesn't contain any %.

I think the regexp used in `reftex-using-biblatex-p' should be

  "^[^%\n]*\\\\usepackage.*{biblatex}"


Regards,

-- 
Nicolas Goaziou

  reply	other threads:[~2016-02-03 11:17 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-02 13:56 Stackoverflow in regexp matcher Loris Bennett
2016-02-02 15:47 ` Nick Dokos
2016-02-03  7:36   ` Loris Bennett
2016-02-03 11:19     ` Nicolas Goaziou [this message]
2016-02-03 11:34       ` Loris Bennett
2016-02-03 17:50         ` Alan Schmitt
2016-02-04  7:30           ` Loris Bennett
2016-02-03 11:44       ` Peter Neilson

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

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87si1a9h2o.fsf@nicolasgoaziou.fr \
    --to=mail@nicolasgoaziou.fr \
    --cc=emacs-orgmode@gnu.org \
    --cc=loris.bennett@fu-berlin.de \
    /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.
Code repositories for project(s) associated with this public inbox

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

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 read-only IMAP folder(s) and NNTP newsgroup(s).