all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Alan Mackenzie <acm@muc.de>
To: help-gnu-emacs@gnu.org
Subject: Re: Regexp issue
Date: Sat, 20 Jun 2009 10:17:38 +0000 (UTC)	[thread overview]
Message-ID: <h1id02$mhe$1@colin2.muc.de> (raw)
In-Reply-To: mailman.985.1245488055.2239.help-gnu-emacs@gnu.org

Peter Dyballa <Peter_Dyballa@web.de> wrote:

> Am 20.06.2009 um 10:39 schrieb Paulo J. Matos:

>> How can I match the string => but not part of <=>?

>        [^<]=>

> [everything but "<"]<followed by exactly "=>">

Or, more precisely,

        \(^\|[^<]\)=>

, i.e. [nothing at all] or [something which isn't "<"] following by =>.
If you're using this in a string in a lisp program, you'll have to double
up the backquotes, something like

       (search-forward-regexp "\\(^\\|[^<]\\)=>")

> --
> Greetings

>   Pete

-- 
Alan Mackenzie (Nuernberg).



  parent reply	other threads:[~2009-06-20 10:17 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-20  8:39 Regexp issue Paulo J. Matos
2009-06-20  8:53 ` Peter Dyballa
     [not found] ` <mailman.985.1245488055.2239.help-gnu-emacs@gnu.org>
2009-06-20 10:17   ` Alan Mackenzie [this message]
2009-06-20 11:16     ` Peter Dyballa
     [not found]     ` <mailman.993.1245496611.2239.help-gnu-emacs@gnu.org>
2009-06-20 12:47       ` Alan Mackenzie
2009-06-20 14:53         ` Peter Dyballa
     [not found]         ` <mailman.996.1245509629.2239.help-gnu-emacs@gnu.org>
2009-06-21  1:14           ` Tim X
     [not found] <mailman.984.1245487162.2239.help-gnu-emacs@gnu.org>
2009-06-20  8:46 ` Marc Tfardy

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='h1id02$mhe$1@colin2.muc.de' \
    --to=acm@muc.de \
    --cc=help-gnu-emacs@gnu.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.
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.