| 1198 |
set, and a match attempt fails when the current position is at a CRLF sequence, |
set, and a match attempt fails when the current position is at a CRLF sequence, |
| 1199 |
the match position is advanced by two characters instead of one, in other |
the match position is advanced by two characters instead of one, in other |
| 1200 |
words, to after the CRLF. |
words, to after the CRLF. |
| 1201 |
|
.P |
| 1202 |
|
Anomalous effects can occur when CRLF is a valid newline sequence and explicit |
| 1203 |
|
\er or \en escapes appear in the pattern. For example, the string "\er\enA" |
| 1204 |
|
matches the unanchored pattern \enA but not [X\en]A. This happens because, in |
| 1205 |
|
the first case, PCRE knows that the match must start with \en, and so it skips |
| 1206 |
|
there before trying to match. In the second case, it has no knowledge about the |
| 1207 |
|
starting character, so it starts matching at the beginning of the string, and |
| 1208 |
|
on failing, skips over the CRLF as described above. However, if the pattern is |
| 1209 |
|
studied, the match succeeds, because then PCRE once again knows where to start. |
| 1210 |
.sp |
.sp |
| 1211 |
PCRE_NOTBOL |
PCRE_NOTBOL |
| 1212 |
.sp |
.sp |
| 1895 |
.rs |
.rs |
| 1896 |
.sp |
.sp |
| 1897 |
.nf |
.nf |
| 1898 |
Last updated: 09 August 2007 |
Last updated: 20 August 2007 |
| 1899 |
Copyright (c) 1997-2007 University of Cambridge. |
Copyright (c) 1997-2007 University of Cambridge. |
| 1900 |
.fi |
.fi |