"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "doc/pcre.3" between
pcre-8.43.tar.bz2 and pcre-8.44.tar.bz2

About: The PCRE library implements Perl compatible regular expression pattern matching.

pcre.3  (pcre-8.43.tar.bz2):pcre.3  (pcre-8.44.tar.bz2)
skipping to change at line 83 skipping to change at line 83
If you are using PCRE in a non-UTF application that permits users to supp ly arbitrary patterns for compi- If you are using PCRE in a non-UTF application that permits users to supp ly arbitrary patterns for compi-
lation, you should be aware of a feature that allows users to turn on UT F support from within a pattern, lation, you should be aware of a feature that allows users to turn on UT F support from within a pattern,
provided that PCRE was built with UTF support. For example, an 8-bit patt ern that begins with "(*UTF8)" provided that PCRE was built with UTF support. For example, an 8-bit patt ern that begins with "(*UTF8)"
or "(*UTF)" turns on UTF-8 mode, which interprets patterns and subject s as strings of UTF-8 characters or "(*UTF)" turns on UTF-8 mode, which interprets patterns and subject s as strings of UTF-8 characters
instead of individual 8-bit characters. This causes both the pattern and any data against which it is instead of individual 8-bit characters. This causes both the pattern and any data against which it is
matched to be checked for UTF-8 validity. If the data string is very lon g, such a check might use suffi- matched to be checked for UTF-8 validity. If the data string is very lon g, such a check might use suffi-
ciently many resources as to cause your application to lose performance. ciently many resources as to cause your application to lose performance.
One way of guarding against this possibility is to use the pcre_fullinfo( ) function to check the compiled One way of guarding against this possibility is to use the pcre_fullinfo( ) function to check the compiled
pattern's options for UTF. Alternatively, from release 8.33, you can set the PCRE_NEVER_UTF option at pattern's options for UTF. Alternatively, from release 8.33, you can set the PCRE_NEVER_UTF option at
compile time. This causes an compile time error if a pattern contains a U TF-setting sequence. compile time. This causes a compile time error if a pattern contains a UT F-setting sequence.
If your application is one that supports UTF, be aware that validity chec king can take time. If the same If your application is one that supports UTF, be aware that validity chec king can take time. If the same
data string is to be matched many times, you can use the PCRE_NO_UTF[8|16 |32]_CHECK option for the second data string is to be matched many times, you can use the PCRE_NO_UTF[8|16 |32]_CHECK option for the second
and subsequent matches to save redundant checks. and subsequent matches to save redundant checks.
Another way that performance can be hit is by running a pattern that has a very large search tree against Another way that performance can be hit is by running a pattern that has a very large search tree against
a string that will never match. Nested unlimited repeats in a pattern are a common example. PCRE provides a string that will never match. Nested unlimited repeats in a pattern are a common example. PCRE provides
some protection against this: see the PCRE_EXTRA_MATCH_LIMIT feature in t he pcreapi page. some protection against this: see the PCRE_EXTRA_MATCH_LIMIT feature in t he pcreapi page.
USER DOCUMENTATION USER DOCUMENTATION
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)