Diff for /embedaddon/pcre/doc/html/pcretest.html between versions 1.1.1.4 and 1.1.1.5

version 1.1.1.4, 2013/07/22 08:25:57 version 1.1.1.5, 2014/06/15 19:46:05
Line 187  equivalent to adding <b>/M</b> to each regular express Line 187  equivalent to adding <b>/M</b> to each regular express
 bytes for both libraries.  bytes for both libraries.
 </P>  </P>
 <P>  <P>
   <b>-O</b>
   Behave as if each pattern has the <b>/O</b> modifier, that is disable
   auto-possessification for all patterns.
   </P>
   <P>
 <b>-o</b> <i>osize</i>  <b>-o</b> <i>osize</i>
 Set the number of elements in the output vector that is used when calling  Set the number of elements in the output vector that is used when calling
 <b>pcre[16|32]_exec()</b> or <b>pcre[16|32]_dfa_exec()</b> to be <i>osize</i>. The  <b>pcre[16|32]_exec()</b> or <b>pcre[16|32]_dfa_exec()</b> to be <i>osize</i>. The
Line 256  should never be studied (see the <b>/S</b> pattern mod Line 261  should never be studied (see the <b>/S</b> pattern mod
 </P>  </P>
 <P>  <P>
 <b>-t</b>  <b>-t</b>
Run each compile, study, and match many times with a timer, and outputRun each compile, study, and match many times with a timer, and output the
resulting time per compile or match (in milliseconds). Do not set <b>-m</b> withresulting times per compile, study, or match (in milliseconds). Do not set
<b>-t</b>, because you will then get the size output a zillion times, and the<b>-m</b> with <b>-t</b>, because you will then get the size output a zillion
timing will be distorted. You can control the number of iterations that aretimes, and the timing will be distorted. You can control the number of
used for timing by following <b>-t</b> with a number (as a separate item on theiterations that are used for timing by following <b>-t</b> with a number (as a
command line). For example, "-t 1000" would iterate 1000 times. The default isseparate item on the command line). For example, "-t 1000" iterates 1000 times.
to iterate 500000 times.The default is to iterate 500000 times.
 </P>  </P>
 <P>  <P>
 <b>-tm</b>  <b>-tm</b>
 This is like <b>-t</b> except that it times only the matching phase, not the  This is like <b>-t</b> except that it times only the matching phase, not the
 compile or study phases.  compile or study phases.
 </P>  </P>
   <P>
   <b>-T</b> <b>-TM</b>
   These behave like <b>-t</b> and <b>-tm</b>, but in addition, at the end of a run,
   the total times for all compiles, studies, and matches are output.
   </P>
 <br><a name="SEC5" href="#TOC1">DESCRIPTION</a><br>  <br><a name="SEC5" href="#TOC1">DESCRIPTION</a><br>
 <P>  <P>
 If <b>pcretest</b> is given two filename arguments, it reads from the first and  If <b>pcretest</b> is given two filename arguments, it reads from the first and
Line 287  option states whether or not <b>readline()</b> will be Line 297  option states whether or not <b>readline()</b> will be
 <P>  <P>
 The program handles any number of sets of input on a single input file. Each  The program handles any number of sets of input on a single input file. Each
 set starts with a regular expression, and continues with any number of data  set starts with a regular expression, and continues with any number of data
lines to be matched against the pattern.lines to be matched against that pattern.
 </P>  </P>
 <P>  <P>
 Each data line is matched separately and independently. If you want to do  Each data line is matched separately and independently. If you want to do
Line 361  sections. Line 371  sections.
   <b>/M</b>              show compiled memory size    <b>/M</b>              show compiled memory size
   <b>/m</b>              set PCRE_MULTILINE    <b>/m</b>              set PCRE_MULTILINE
   <b>/N</b>              set PCRE_NO_AUTO_CAPTURE    <b>/N</b>              set PCRE_NO_AUTO_CAPTURE
     <b>/O</b>              set PCRE_NO_AUTO_POSSESS
   <b>/P</b>              use the POSIX wrapper    <b>/P</b>              use the POSIX wrapper
   <b>/S</b>              study the pattern after compilation    <b>/S</b>              study the pattern after compilation
   <b>/s</b>              set PCRE_DOTALL    <b>/s</b>              set PCRE_DOTALL
Line 419  options that do not correspond to anything in Perl: Line 430  options that do not correspond to anything in Perl:
   <b>/f</b>              PCRE_FIRSTLINE    <b>/f</b>              PCRE_FIRSTLINE
   <b>/J</b>              PCRE_DUPNAMES    <b>/J</b>              PCRE_DUPNAMES
   <b>/N</b>              PCRE_NO_AUTO_CAPTURE    <b>/N</b>              PCRE_NO_AUTO_CAPTURE
     <b>/O</b>              PCRE_NO_AUTO_POSSESS
   <b>/U</b>              PCRE_UNGREEDY    <b>/U</b>              PCRE_UNGREEDY
   <b>/W</b>              PCRE_UCP    <b>/W</b>              PCRE_UCP
   <b>/X</b>              PCRE_EXTRA    <b>/X</b>              PCRE_EXTRA
Line 562  matched. There are a number of qualifying characters t Line 574  matched. There are a number of qualifying characters t
 They may appear in any order.  They may appear in any order.
 </P>  </P>
 <P>  <P>
If <b>S</b> is followed by an exclamation mark, <b>pcre[16|32]_study()</b> is calledIf <b>/S</b> is followed by an exclamation mark, <b>pcre[16|32]_study()</b> is
with the PCRE_STUDY_EXTRA_NEEDED option, causing it always to return acalled with the PCRE_STUDY_EXTRA_NEEDED option, causing it always to return a
 <b>pcre_extra</b> block, even when studying discovers no useful information.  <b>pcre_extra</b> block, even when studying discovers no useful information.
 </P>  </P>
 <P>  <P>
Line 642  function: Line 654  function:
 The <b>/+</b> modifier works as described above. All other modifiers are  The <b>/+</b> modifier works as described above. All other modifiers are
 ignored.  ignored.
 </P>  </P>
   <br><b>
   Locking out certain modifiers
   </b><br>
   <P>
   PCRE can be compiled with or without support for certain features such as
   UTF-8/16/32 or Unicode properties. Accordingly, the standard tests are split up
   into a number of different files that are selected for running depending on
   which features are available. When updating the tests, it is all too easy to
   put a new test into the wrong file by mistake; for example, to put a test that
   requires UTF support into a file that is used when it is not available. To help
   detect such mistakes as early as possible, there is a facility for locking out
   specific modifiers. If an input line for <b>pcretest</b> starts with the string
   "&#60; forbid " the following sequence of characters is taken as a list of
   forbidden modifiers. For example, in the test files that must not use UTF or
   Unicode property support, this line appears:
   <pre>
     &#60; forbid 8W
   </pre>
   This locks out the /8 and /W modifiers. An immediate error is given if they are
   subsequently encountered. If the character string contains &#60; but not &#62;, all the
   multi-character modifiers that begin with &#60; are locked out. Otherwise, such
   modifiers must be explicitly listed, for example:
   <pre>
     &#60; forbid &#60;JS&#62;&#60;cr&#62;
   </pre>
   There must be a single space between &#60; and "forbid" for this feature to be
   recognised. If there is not, the line is interpreted either as a request to
   re-load a pre-compiled pattern (see "SAVING AND RELOADING COMPILED PATTERNS"
   below) or, if there is a another &#60; character, as a pattern that uses &#60; as its
   delimiter.
   </P>
 <br><a name="SEC7" href="#TOC1">DATA LINES</a><br>  <br><a name="SEC7" href="#TOC1">DATA LINES</a><br>
 <P>  <P>
 Before each data line is passed to <b>pcre[16|32]_exec()</b>, leading and trailing  Before each data line is passed to <b>pcre[16|32]_exec()</b>, leading and trailing
Line 662  recognized: Line 705  recognized:
   \v         vertical tab (\x0b)    \v         vertical tab (\x0b)
   \nnn       octal character (up to 3 octal digits); always    \nnn       octal character (up to 3 octal digits); always
                a byte unless &#62; 255 in UTF-8 or 16-bit or 32-bit mode                 a byte unless &#62; 255 in UTF-8 or 16-bit or 32-bit mode
     \o{dd...}  octal character (any number of octal digits}
   \xhh       hexadecimal byte (up to 2 hex digits)    \xhh       hexadecimal byte (up to 2 hex digits)
   \x{hh...}  hexadecimal character (any number of hex digits)    \x{hh...}  hexadecimal character (any number of hex digits)
   \A         pass the PCRE_ANCHORED option to <b>pcre[16|32]_exec()</b> or <b>pcre[16|32]_dfa_exec()</b>    \A         pass the PCRE_ANCHORED option to <b>pcre[16|32]_exec()</b> or <b>pcre[16|32]_dfa_exec()</b>
Line 1031  writing the file, <b>pcretest</b> expects to read a ne Line 1075  writing the file, <b>pcretest</b> expects to read a ne
 </P>  </P>
 <P>  <P>
 A saved pattern can be reloaded into <b>pcretest</b> by specifying &#60; and a file  A saved pattern can be reloaded into <b>pcretest</b> by specifying &#60; and a file
name instead of a pattern. The name of the file must not contain a &#60; character,name instead of a pattern. There must be no space between &#60; and the file name,
as otherwise <b>pcretest</b> will interpret the line as a pattern delimited by &#60;which must not contain a &#60; character, as otherwise <b>pcretest</b> will
characters.interpret the line as a pattern delimited by &#60; characters. For example:
For example: 
 <pre>  <pre>
    re&#62; &#60;/some/file     re&#62; &#60;/some/file
   Compiled pattern loaded from /some/file    Compiled pattern loaded from /some/file
Line 1091  Cambridge CB2 3QH, England. Line 1134  Cambridge CB2 3QH, England.
 </P>  </P>
 <br><a name="SEC17" href="#TOC1">REVISION</a><br>  <br><a name="SEC17" href="#TOC1">REVISION</a><br>
 <P>  <P>
Last updated: 26 April 2013Last updated: 12 November 2013
 <br>  <br>
 Copyright &copy; 1997-2013 University of Cambridge.  Copyright &copy; 1997-2013 University of Cambridge.
 <br>  <br>

Removed from v.1.1.1.4  
changed lines
  Added in v.1.1.1.5


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>