octave-maintainers
[Top][All Lists]
Advanced

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

regexp doc ?


From: John W. Eaton
Subject: regexp doc ?
Date: Wed, 17 Nov 2010 04:27:57 -0500

On 17-Nov-2010, CdeMills wrote:

| while trying to cope with a problem using regexpes, I found a lot of info on
| this site:
| http://www.regular-expressions.info
| 
| Of particular interest to me was the fact the regexpes are greedy by default
| (working right to left), but also support non-greedy mode (left-to-right):
| .*?, negative look-ahead : q(?!u) matches a 'q' not followed by a 'u';
| positive look-ahead: q(?=u) matches a 'q' followed by a 'u', but 'u' is not
| matched, and so on.
| 
| So it seems that, on my platform (Ubuntu 9), the regexp lib support enriched
| modes. Is it valid on other platforms too ? If yes, could we enhance the
| help text to reflect this fact ?

There is no single definition of regular expressions.  Octave can
currently use either the system regex library or the Perl Compatible
Regular Expressions library (PCRE).  PCRE is more powerful.  I don't
know whether it matches exactly with the documentation on the site you
found, but it seems that if you are going to expand the documentation,
you should use the PCRE docs as a reference, not the info at the site
you found.  Also, if you submit changes to the docs, it must be either
your original work or you must have the right to redistribute it under
the terms of the GPL.  What is the license for the info on the site
you found?

Also, it might be good to have different documentation for the regexp
functions in Octave depending on which library is actually linked with
Octave.  Or maybe we should just require the PCRE library in order to
build Octave?

jwe


reply via email to

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