help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

regular expression


From: Burkhard Schultheis
Subject: regular expression
Date: Mon, 25 Jan 2010 12:00:16 +0100
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.1.5) Gecko/20091204 Thunderbird/3.0

I want to search for the following string: A hyphen not surrounded by spaces. Therefore I tried the following pattern:
[^ ]-[^ ].
But this pattern finds a hyphen preceded by a letter and followed by a newline character, too.

How to exclude the newline character? I tried
[^ ]-[^ \n]
but that does not work. Why? And how to search for this?

Thank you in advance!

Regards
Burkhard


reply via email to

[Prev in Thread] Current Thread [Next in Thread]