| 499 |
\fBpcre_exec()\fP returns, starting with number 0 for the string that matched |
\fBpcre_exec()\fP returns, starting with number 0 for the string that matched |
| 500 |
the whole pattern. Otherwise, it outputs "No match" when the return is |
the whole pattern. Otherwise, it outputs "No match" when the return is |
| 501 |
PCRE_ERROR_NOMATCH, and "Partial match:" followed by the partially matching |
PCRE_ERROR_NOMATCH, and "Partial match:" followed by the partially matching |
| 502 |
substring when \fBpcre_exec()\fP returns PCRE_ERROR_PARTIAL. For any other |
substring when \fBpcre_exec()\fP returns PCRE_ERROR_PARTIAL. (Note that this is |
| 503 |
returns, it outputs the PCRE negative error number. Here is an example of an |
the entire substring that was inspected during the partial match; it may |
| 504 |
interactive \fBpcretest\fP run. |
include characters before the actual match start if a lookbehind assertion, |
| 505 |
|
\eK, \eb, or \eB was involved.) For any other returns, it outputs the PCRE |
| 506 |
|
negative error number. Here is an example of an interactive \fBpcretest\fP run. |
| 507 |
.sp |
.sp |
| 508 |
$ pcretest |
$ pcretest |
| 509 |
PCRE version 7.0 30-Nov-2006 |
PCRE version 7.0 30-Nov-2006 |
| 586 |
(Using the normal matching function on this data finds only "tang".) The |
(Using the normal matching function on this data finds only "tang".) The |
| 587 |
longest matching string is always given first (and numbered zero). After a |
longest matching string is always given first (and numbered zero). After a |
| 588 |
PCRE_ERROR_PARTIAL return, the output is "Partial match:", followed by the |
PCRE_ERROR_PARTIAL return, the output is "Partial match:", followed by the |
| 589 |
partially matching substring. |
partially matching substring. (Note that this is the entire substring that was |
| 590 |
|
inspected during the partial match; it may include characters before the actual |
| 591 |
|
match start if a lookbehind assertion, \eK, \eb, or \eB was involved.) |
| 592 |
.P |
.P |
| 593 |
If \fB/g\fP is present on the pattern, the search for further matches resumes |
If \fB/g\fP is present on the pattern, the search for further matches resumes |
| 594 |
at the end of the longest match. For example: |
at the end of the longest match. For example: |
| 767 |
.rs |
.rs |
| 768 |
.sp |
.sp |
| 769 |
.nf |
.nf |
| 770 |
Last updated: 14 June 2010 |
Last updated: 22 October 2010 |
| 771 |
Copyright (c) 1997-2010 University of Cambridge. |
Copyright (c) 1997-2010 University of Cambridge. |
| 772 |
.fi |
.fi |