all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* matching [^/]
@ 2004-07-09  8:39 Simon Strobl
  2004-07-09 15:29 ` Michael Slass
  2004-07-12 13:17 ` Simon Strobl
  0 siblings, 2 replies; 4+ messages in thread
From: Simon Strobl @ 2004-07-09  8:39 UTC (permalink / raw)


Hello,

suppose a buffer contains the following string and you want to match
the part "// VP1zr".
 
 // VP1zr // 1(0)

I typed "//[^/]+" into the re-builder. It matched the whole line. I
could not find an explanation for this behaviour on the Emacs info
site.

Can someone explain it to me? 


Simon

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

* Re: matching [^/]
  2004-07-09  8:39 matching [^/] Simon Strobl
@ 2004-07-09 15:29 ` Michael Slass
  2004-07-12 13:17 ` Simon Strobl
  1 sibling, 0 replies; 4+ messages in thread
From: Michael Slass @ 2004-07-09 15:29 UTC (permalink / raw)


simon_strobl@yahoo.de (Simon Strobl) writes:

>Hello,
>
>suppose a buffer contains the following string and you want to match
>the part "// VP1zr".
> 
> // VP1zr // 1(0)
>
>I typed "//[^/]+" into the re-builder. It matched the whole line. I
>could not find an explanation for this behaviour on the Emacs info
>site.
>
>Can someone explain it to me? 
>
>
>Simon

re-builder is highlighting all matches to your regexp, and your string
matches twice:
'// VP1zr '
'// 1(0)'

The two matches are adjacent, so the highlighted regions touch each
other, and they look like one.


-- 
Mike Slass

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

* Re: matching [^/]
       [not found] <200407091601.i69G1fL15330@dell3.ma.utexas.edu>
@ 2004-07-11 16:12 ` Joe Corneli
  0 siblings, 0 replies; 4+ messages in thread
From: Joe Corneli @ 2004-07-11 16:12 UTC (permalink / raw)
  Cc: simon_strobl

   suppose a buffer contains the following string and you want to match
   the part "// VP1zr".
    
    // VP1zr // 1(0)


I had a similar regexp to match and got the answer I needed here:

http://lists.gnu.org/archive/html/help-gnu-emacs/2004-01/msg00109.html

maybe that will help you.

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

* Re: matching [^/]
  2004-07-09  8:39 matching [^/] Simon Strobl
  2004-07-09 15:29 ` Michael Slass
@ 2004-07-12 13:17 ` Simon Strobl
  1 sibling, 0 replies; 4+ messages in thread
From: Simon Strobl @ 2004-07-12 13:17 UTC (permalink / raw)


Thanks, Joe and Michael.

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

end of thread, other threads:[~2004-07-12 13:17 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-07-09  8:39 matching [^/] Simon Strobl
2004-07-09 15:29 ` Michael Slass
2004-07-12 13:17 ` Simon Strobl
     [not found] <200407091601.i69G1fL15330@dell3.ma.utexas.edu>
2004-07-11 16:12 ` Joe Corneli

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.