Re: please help with my regular expression

John Ferrier <john_j_ferrier-/[email protected]>
Newsgroups gmane.editors.nedit.user
Message-ID <[email protected]>
It make no difference. The following works:

<[0-9]+(\.[0-9]*)?([DEde][-+]?[0-9]*)?|[0-9]*\.[0-9]+([DEde][-+]?[0-9]*)?>

Thanks anyway.

John


________________________________
From: Bert Wesarg <bert.wesarg-gM/[email protected]>
To: General NEdit discussion list <[email protected]>
Sent: Friday, February 20, 2009 11:50:34 AM
Subject: Re: please help with my regular expression

On Fri, Feb 20, 2009 at 18:15, John Ferrier <john_j_ferrier-/[email protected]> wrote:
> The following regular expression used in fortan language to match numerical constant
>
>         <[0-9]+(\.[0-9]*)?([DEde][-+]?[0-9]*)?|\.[0-9]+([DEde][-+]?[0-9]*)?>
You should not use <> as 'delimiters', because that would not work
with a '.' inside. Try this:

    (?<!\Y)[0-9]+(\.[0-9]*)?([DEde][-+]?[0-9]*)?|\.[0-9]+([DEde][-+]?[0-9]*)?(?!\Y)

Bert
-- 
NEdit Discuss mailing list - [email protected]
http://www.nedit.org/mailman/listinfo/discuss



      
-- 
NEdit Discuss mailing list - [email protected]
http://www.nedit.org/mailman/listinfo/discuss
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.