[Pcre-svn] [1248] code/trunk: Fix documentation typos and up…

Kezdőlap
Üzenet törlése
Szerző: Subversion repository
Dátum:  
Címzett: pcre-svn
Tárgy: [Pcre-svn] [1248] code/trunk: Fix documentation typos and upgrade documentation checking script.
Revision: 1248
          http://www.exim.org/viewvc/pcre2?view=rev&revision=1248
Author:   ph10
Date:     2020-04-24 17:05:36 +0100 (Fri, 24 Apr 2020)
Log Message:
-----------
Fix documentation typos and upgrade documentation checking script.


Modified Paths:
--------------
    code/trunk/CheckMan
    code/trunk/doc/html/pcre2_jit_free_unused_memory.html
    code/trunk/doc/html/pcre2api.html
    code/trunk/doc/html/pcre2build.html
    code/trunk/doc/html/pcre2grep.html
    code/trunk/doc/html/pcre2jit.html
    code/trunk/doc/html/pcre2partial.html
    code/trunk/doc/html/pcre2test.html
    code/trunk/doc/pcre2.txt
    code/trunk/doc/pcre2_jit_free_unused_memory.3
    code/trunk/doc/pcre2api.3
    code/trunk/doc/pcre2build.3
    code/trunk/doc/pcre2grep.1
    code/trunk/doc/pcre2jit.3
    code/trunk/doc/pcre2partial.3
    code/trunk/doc/pcre2test.1


Modified: code/trunk/CheckMan
===================================================================
--- code/trunk/CheckMan    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/CheckMan    2020-04-24 16:05:36 UTC (rev 1248)
@@ -16,6 +16,7 @@


   while (<IN>)
     {  
+    $count = 0;
     $line++; 
     if (/^\s*$/)
       {
@@ -50,14 +51,24 @@
         $yield = 1;
         }
       }
-    else
+    elsif (/\\[^ef]|\\f[^IBP]/)
       {
-      if (/\\[^ef]|\\f[^IBP]/)
-        {
-        printf "Bad backslash in line $line of $file\n";  
-        $yield = 1; 
-        } 
-      }   
+      printf "Bad backslash in line $line of $file\n";
+      $yield = 1;
+      }
+    while (/\\f[BI]/g)
+      {
+      $count++;
+      }
+    while (/\\fP/g)
+      {
+      $count--;
+      }
+    if ($count != 0)
+      {
+      printf "Mismatching formatting in line $line of $file\n";
+      $yield = 1;
+      }
     }


close(IN);

Modified: code/trunk/doc/html/pcre2_jit_free_unused_memory.html
===================================================================
--- code/trunk/doc/html/pcre2_jit_free_unused_memory.html    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/html/pcre2_jit_free_unused_memory.html    2020-04-24 16:05:36 UTC (rev 1248)
@@ -29,7 +29,7 @@
 context, for custom memory management, or NULL for standard memory management.
 JIT memory allocation retains some memory in order to improve future JIT
 compilation speed. In low memory conditions,
-\fBpcre2_jit_free_unused_memory()\fB can be used to cause this memory to be
+<b>pcre2_jit_free_unused_memory()</b> can be used to cause this memory to be
 freed.
 </P>
 <P>


Modified: code/trunk/doc/html/pcre2api.html
===================================================================
--- code/trunk/doc/html/pcre2api.html    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/html/pcre2api.html    2020-04-24 16:05:36 UTC (rev 1248)
@@ -252,7 +252,7 @@
 <b>int pcre2_substitute(const pcre2_code *<i>code</i>, PCRE2_SPTR <i>subject</i>,</b>
 <b>  PCRE2_SIZE <i>length</i>, PCRE2_SIZE <i>startoffset</i>,</b>
 <b>  uint32_t <i>options</i>, pcre2_match_data *<i>match_data</i>,</b>
-<b>  pcre2_match_context *<i>mcontext</i>, PCRE2_SPTR \fIreplacementzfP,</b>
+<b>  pcre2_match_context *<i>mcontext</i>, PCRE2_SPTR <i>replacementz</i>,</b>
 <b>  PCRE2_SIZE <i>rlength</i>, PCRE2_UCHAR *<i>outputbuffer</i>,</b>
 <b>  PCRE2_SIZE *<i>outlengthptr</i>);</b>
 </P>
@@ -3485,7 +3485,7 @@
 <P>
 You can restrict the effect of a global substitution to a portion of the
 subject string by setting either or both of <i>startoffset</i> and an offset
-limit. Here is a \fPpcre2test\fP example:
+limit. Here is a <b>pcre2test</b> example:
 <pre>
   /B/g,replace=!,use_offset_limit
   ABC ABC ABC ABC\=offset=3,offset_limit=12


Modified: code/trunk/doc/html/pcre2build.html
===================================================================
--- code/trunk/doc/html/pcre2build.html    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/html/pcre2build.html    2020-04-24 16:05:36 UTC (rev 1248)
@@ -436,7 +436,7 @@
   --with-pcre2grep-bufsize=51200
   --with-pcre2grep-max-bufsize=2097152
 </pre>
-to the <b>configure</b> command. The caller of \fPpcre2grep\fP can override
+to the <b>configure</b> command. The caller of <b>pcre2grep</b> can override
 these values by using --buffer-size and --max-buffer-size on the command line.
 </P>
 <br><a name="SEC17" href="#TOC1">PCRE2TEST OPTION FOR LIBREADLINE SUPPORT</a><br>


Modified: code/trunk/doc/html/pcre2grep.html
===================================================================
--- code/trunk/doc/html/pcre2grep.html    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/html/pcre2grep.html    2020-04-24 16:05:36 UTC (rev 1248)
@@ -562,7 +562,7 @@
 are very large and so effectively unlimited.
 </P>
 <P>
-\fB--max-buffer-size=<i>number</i>
+<b>--max-buffer-size</b>=<i>number</i>
 This limits the expansion of the processing buffer, whose initial size can be
 set by <b>--buffer-size</b>. The maximum buffer size is silently forced to be no
 smaller than the starting buffer size.
@@ -597,7 +597,7 @@
 There is a limit to the number of lines that can be matched, imposed by the way
 that <b>pcre2grep</b> buffers the input file as it scans it. With a sufficiently
 large processing buffer, this should not be a problem, but the <b>-M</b> option
-does not work when input is read line by line (see \fP--line-buffered\fP.)
+does not work when input is read line by line (see <b>--line-buffered</b>.)
 </P>
 <P>
 <b>-N</b> <i>newline-type</i>, <b>--newline</b>=<i>newline-type</i>


Modified: code/trunk/doc/html/pcre2jit.html
===================================================================
--- code/trunk/doc/html/pcre2jit.html    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/html/pcre2jit.html    2020-04-24 16:05:36 UTC (rev 1248)
@@ -90,7 +90,7 @@
 There is a limit to the size of pattern that JIT supports, imposed by the size
 of machine stack that it uses. The exact rules are not documented because they
 may change at any time, in particular, when new optimizations are introduced.
-If a pattern is too big, a call to \fBpcre2_jit_compile()\fB returns
+If a pattern is too big, a call to <b>pcre2_jit_compile()</b> returns
 PCRE2_ERROR_NOMEMORY.
 </P>
 <P>
@@ -339,12 +339,12 @@
 You can free a JIT stack at any time, as long as it will not be used by
 <b>pcre2_match()</b> again. When you assign the stack to a match context, only a
 pointer is set. There is no reference counting or any other magic. You can free
-compiled patterns, contexts, and stacks in any order, anytime. Just \fIdo
-not\fP call <b>pcre2_match()</b> with a match context pointing to an already
-freed stack, as that will cause SEGFAULT. (Also, do not free a stack currently
-used by <b>pcre2_match()</b> in another thread). You can also replace the stack
-in a context at any time when it is not in use. You should free the previous
-stack before assigning a replacement.
+compiled patterns, contexts, and stacks in any order, anytime.
+Just <i>do not</i> call <b>pcre2_match()</b> with a match context pointing to an
+already freed stack, as that will cause SEGFAULT. (Also, do not free a stack
+currently used by <b>pcre2_match()</b> in another thread). You can also replace
+the stack in a context at any time when it is not in use. You should free the
+previous stack before assigning a replacement.
 </P>
 <P>
 (5) Should I allocate/free a stack every time before/after calling


Modified: code/trunk/doc/html/pcre2partial.html
===================================================================
--- code/trunk/doc/html/pcre2partial.html    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/html/pcre2partial.html    2020-04-24 16:05:36 UTC (rev 1248)
@@ -295,7 +295,7 @@
   Partial match: 123ab
                  &#60;&#60;&#60;
 </pre>
-However, the \fPallusedtext\fP modifier is not available for JIT matching,
+However, the <b>allusedtext</b> modifier is not available for JIT matching,
 because JIT matching does not record the first (or last) consulted characters.
 For this reason, this information is not available via the API. It is therefore
 not possible in general to obtain the exact number of characters that must be


Modified: code/trunk/doc/html/pcre2test.html
===================================================================
--- code/trunk/doc/html/pcre2test.html    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/html/pcre2test.html    2020-04-24 16:05:36 UTC (rev 1248)
@@ -261,7 +261,7 @@
 If both -C and -LM are present, whichever is first is recognized.
 </P>
 <P>
-\fB-pattern\fB <i>modifier-list</i>
+<b>-pattern</b> <i>modifier-list</i>
 Behave as if each pattern line contains the given modifiers.
 </P>
 <P>


Modified: code/trunk/doc/pcre2.txt
===================================================================
--- code/trunk/doc/pcre2.txt    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/pcre2.txt    2020-04-24 16:05:36 UTC (rev 1248)
@@ -180,8 +180,8 @@
        Last updated: 17 September 2018
        Copyright (c) 1997-2018 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2API(3)                Library Functions Manual                PCRE2API(3)



@@ -351,7 +351,7 @@
        int pcre2_substitute(const pcre2_code *code, PCRE2_SPTR subject,
          PCRE2_SIZE length, PCRE2_SIZE startoffset,
          uint32_t options, pcre2_match_data *match_data,
-         pcre2_match_context *mcontext, PCRE2_SPTR replacementzfP,
+         pcre2_match_context *mcontext, PCRE2_SPTR replacementz,
          PCRE2_SIZE rlength, PCRE2_UCHAR *outputbuffer,
          PCRE2_SIZE *outlengthptr);


@@ -3796,8 +3796,8 @@
        Last updated: 19 March 2020
        Copyright (c) 1997-2020 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2BUILD(3)              Library Functions Manual              PCRE2BUILD(3)



@@ -4390,8 +4390,8 @@
        Last updated: 20 March 2020
        Copyright (c) 1997-2020 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2CALLOUT(3)            Library Functions Manual            PCRE2CALLOUT(3)



@@ -4820,8 +4820,8 @@
        Last updated: 03 February 2019
        Copyright (c) 1997-2019 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2COMPAT(3)             Library Functions Manual             PCRE2COMPAT(3)



@@ -5029,8 +5029,8 @@
        Last updated: 13 July 2019
        Copyright (c) 1997-2019 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2JIT(3)                Library Functions Manual                PCRE2JIT(3)



@@ -5334,7 +5334,7 @@
        pcre2_match() again. When you assign the stack to a match context, only
        a  pointer  is  set. There is no reference counting or any other magic.
        You can free compiled patterns, contexts, and stacks in any order, any-
-       time.  Just  do not call pcre2_match() with a match context pointing to
+       time.   Just do not call pcre2_match() with a match context pointing to
        an already freed stack, as that will cause SEGFAULT. (Also, do not free
        a  stack  currently  used  by pcre2_match() in another thread). You can
        also replace the stack in a context at any time when it is not in  use.
@@ -5454,8 +5454,8 @@
        Last updated: 23 May 2019
        Copyright (c) 1997-2019 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2LIMITS(3)             Library Functions Manual             PCRE2LIMITS(3)



@@ -5524,8 +5524,8 @@
        Last updated: 02 February 2019
        Copyright (c) 1997-2019 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2MATCHING(3)           Library Functions Manual           PCRE2MATCHING(3)



@@ -5748,8 +5748,8 @@
        Last updated: 23 May 2019
        Copyright (c) 1997-2019 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2PARTIAL(3)            Library Functions Manual            PCRE2PARTIAL(3)



@@ -6128,8 +6128,8 @@
        Last updated: 04 September 2019
        Copyright (c) 1997-2019 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2PATTERN(3)            Library Functions Manual            PCRE2PATTERN(3)



@@ -9562,8 +9562,8 @@
        Last updated: 24 February 2020
        Copyright (c) 1997-2020 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2PERFORM(3)            Library Functions Manual            PCRE2PERFORM(3)



@@ -9797,8 +9797,8 @@
        Last updated: 03 February 2019
        Copyright (c) 1997-2019 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2POSIX(3)              Library Functions Manual              PCRE2POSIX(3)



@@ -10127,8 +10127,8 @@
        Last updated: 30 January 2019
        Copyright (c) 1997-2019 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2SAMPLE(3)             Library Functions Manual             PCRE2SAMPLE(3)



@@ -10406,8 +10406,8 @@
        Last updated: 27 June 2018
        Copyright (c) 1997-2018 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2SYNTAX(3)             Library Functions Manual             PCRE2SYNTAX(3)



@@ -10922,8 +10922,8 @@
        Last updated: 28 December 2019
        Copyright (c) 1997-2019 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 
 PCRE2UNICODE(3)            Library Functions Manual            PCRE2UNICODE(3)



@@ -11357,5 +11357,5 @@
        Last updated: 23 February 2020
        Copyright (c) 1997-2020 University of Cambridge.
 ------------------------------------------------------------------------------
-
-
+ 
+ 


Modified: code/trunk/doc/pcre2_jit_free_unused_memory.3
===================================================================
--- code/trunk/doc/pcre2_jit_free_unused_memory.3    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/pcre2_jit_free_unused_memory.3    2020-04-24 16:05:36 UTC (rev 1248)
@@ -17,7 +17,7 @@
 context, for custom memory management, or NULL for standard memory management.
 JIT memory allocation retains some memory in order to improve future JIT
 compilation speed. In low memory conditions,
-\fBpcre2_jit_free_unused_memory()\fB can be used to cause this memory to be
+\fBpcre2_jit_free_unused_memory()\fP can be used to cause this memory to be
 freed.
 .P
 There is a complete description of the PCRE2 native API in the


Modified: code/trunk/doc/pcre2api.3
===================================================================
--- code/trunk/doc/pcre2api.3    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/pcre2api.3    2020-04-24 16:05:36 UTC (rev 1248)
@@ -187,7 +187,7 @@
 .B int pcre2_substitute(const pcre2_code *\fIcode\fP, PCRE2_SPTR \fIsubject\fP,
 .B "  PCRE2_SIZE \fIlength\fP, PCRE2_SIZE \fIstartoffset\fP,"
 .B "  uint32_t \fIoptions\fP, pcre2_match_data *\fImatch_data\fP,"
-.B "  pcre2_match_context *\fImcontext\fP, PCRE2_SPTR \fIreplacementzfP,"
+.B "  pcre2_match_context *\fImcontext\fP, PCRE2_SPTR \fIreplacementz\fP,"
 .B "  PCRE2_SIZE \fIrlength\fP, PCRE2_UCHAR *\fIoutputbuffer\fP,"
 .B "  PCRE2_SIZE *\fIoutlengthptr\fP);"
 .fi
@@ -3495,7 +3495,7 @@
 .P
 You can restrict the effect of a global substitution to a portion of the
 subject string by setting either or both of \fIstartoffset\fP and an offset
-limit. Here is a \fPpcre2test\fP example:
+limit. Here is a \fBpcre2test\fP example:
 .sp
   /B/g,replace=!,use_offset_limit
   ABC ABC ABC ABC\e=offset=3,offset_limit=12


Modified: code/trunk/doc/pcre2build.3
===================================================================
--- code/trunk/doc/pcre2build.3    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/pcre2build.3    2020-04-24 16:05:36 UTC (rev 1248)
@@ -439,7 +439,7 @@
   --with-pcre2grep-bufsize=51200
   --with-pcre2grep-max-bufsize=2097152
 .sp
-to the \fBconfigure\fP command. The caller of \fPpcre2grep\fP can override
+to the \fBconfigure\fP command. The caller of \fBpcre2grep\fP can override
 these values by using --buffer-size and --max-buffer-size on the command line.
 .
 .


Modified: code/trunk/doc/pcre2grep.1
===================================================================
--- code/trunk/doc/pcre2grep.1    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/pcre2grep.1    2020-04-24 16:05:36 UTC (rev 1248)
@@ -488,7 +488,7 @@
 when the PCRE2 library is compiled; if they are not specified, the defaults
 are very large and so effectively unlimited.
 .TP
-\fB--max-buffer-size=\fInumber\fP
+\fB--max-buffer-size\fP=\fInumber\fP
 This limits the expansion of the processing buffer, whose initial size can be
 set by \fB--buffer-size\fP. The maximum buffer size is silently forced to be no
 smaller than the starting buffer size.
@@ -520,7 +520,7 @@
 There is a limit to the number of lines that can be matched, imposed by the way
 that \fBpcre2grep\fP buffers the input file as it scans it. With a sufficiently
 large processing buffer, this should not be a problem, but the \fB-M\fP option
-does not work when input is read line by line (see \fP--line-buffered\fP.)
+does not work when input is read line by line (see \fB--line-buffered\fP.)
 .TP
 \fB-N\fP \fInewline-type\fP, \fB--newline\fP=\fInewline-type\fP
 Six different conventions for indicating the ends of lines in scanned files are


Modified: code/trunk/doc/pcre2jit.3
===================================================================
--- code/trunk/doc/pcre2jit.3    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/pcre2jit.3    2020-04-24 16:05:36 UTC (rev 1248)
@@ -64,7 +64,7 @@
 There is a limit to the size of pattern that JIT supports, imposed by the size
 of machine stack that it uses. The exact rules are not documented because they
 may change at any time, in particular, when new optimizations are introduced.
-If a pattern is too big, a call to \fBpcre2_jit_compile()\fB returns
+If a pattern is too big, a call to \fBpcre2_jit_compile()\fP returns
 PCRE2_ERROR_NOMEMORY.
 .P
 PCRE2_JIT_COMPLETE requests the JIT compiler to generate code for complete
@@ -315,12 +315,12 @@
 You can free a JIT stack at any time, as long as it will not be used by
 \fBpcre2_match()\fP again. When you assign the stack to a match context, only a
 pointer is set. There is no reference counting or any other magic. You can free
-compiled patterns, contexts, and stacks in any order, anytime. Just \fIdo
-not\fP call \fBpcre2_match()\fP with a match context pointing to an already
-freed stack, as that will cause SEGFAULT. (Also, do not free a stack currently
-used by \fBpcre2_match()\fP in another thread). You can also replace the stack
-in a context at any time when it is not in use. You should free the previous
-stack before assigning a replacement.
+compiled patterns, contexts, and stacks in any order, anytime.
+Just \fIdo not\fP call \fBpcre2_match()\fP with a match context pointing to an
+already freed stack, as that will cause SEGFAULT. (Also, do not free a stack
+currently used by \fBpcre2_match()\fP in another thread). You can also replace
+the stack in a context at any time when it is not in use. You should free the
+previous stack before assigning a replacement.
 .P
 (5) Should I allocate/free a stack every time before/after calling
 \fBpcre2_match()\fP?


Modified: code/trunk/doc/pcre2partial.3
===================================================================
--- code/trunk/doc/pcre2partial.3    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/pcre2partial.3    2020-04-24 16:05:36 UTC (rev 1248)
@@ -261,7 +261,7 @@
   Partial match: 123ab
                  <<<
 .sp
-However, the \fPallusedtext\fP modifier is not available for JIT matching,
+However, the \fBallusedtext\fP modifier is not available for JIT matching,
 because JIT matching does not record the first (or last) consulted characters.
 For this reason, this information is not available via the API. It is therefore
 not possible in general to obtain the exact number of characters that must be


Modified: code/trunk/doc/pcre2test.1
===================================================================
--- code/trunk/doc/pcre2test.1    2020-04-24 15:36:53 UTC (rev 1247)
+++ code/trunk/doc/pcre2test.1    2020-04-24 16:05:36 UTC (rev 1248)
@@ -218,7 +218,7 @@
 standard output, then exit with zero exit code. All other options are ignored.
 If both -C and -LM are present, whichever is first is recognized.
 .TP 10
-\fB-pattern\fB \fImodifier-list\fP
+\fB-pattern\fP \fImodifier-list\fP
 Behave as if each pattern line contains the given modifiers.
 .TP 10
 \fB-q\fP