diff --git a/doc/html/pcre2pattern.html b/doc/html/pcre2pattern.html index 4fed554..d201cf2 100644 --- a/doc/html/pcre2pattern.html +++ b/doc/html/pcre2pattern.html @@ -1907,6 +1907,7 @@ group can match. Suppose you want to match the name of a weekday, either as a 3-letter abbreviation or as the full name, and in both cases you want to extract the abbreviation. This pattern (ignoring the line breaks) does the job:
+  (?J)
   (?<DN>Mon|Fri|Sun)(?:day)?|
   (?<DN>Tue)(?:sday)?|
   (?<DN>Wed)(?:nesday)?|
@@ -1927,7 +1928,7 @@ they appear in the overall pattern. The first one that is set is used for the
 reference. For example, this pattern matches both "foofoo" and "barbar" but not
 "foobar" or "barfoo":
 
-  (?:(?<n>foo)|(?<n>bar))\k<n>
+  (?J)(?:(?<n>foo)|(?<n>bar))\k<n>
 
 

diff --git a/doc/html/pcre2syntax.html b/doc/html/pcre2syntax.html index 3687b35..b4b78b6 100644 --- a/doc/html/pcre2syntax.html +++ b/doc/html/pcre2syntax.html @@ -467,7 +467,7 @@ Changes of these options within a group are automatically cancelled at the end of the group.
   (?i)            caseless
-  (?J)            allow duplicate names
+  (?J)            allow duplicate named groups
   (?m)            multiline
   (?n)            no auto capture
   (?s)            single line (dotall)
diff --git a/doc/pcre2.txt b/doc/pcre2.txt
index e99dbef..7af1916 100644
--- a/doc/pcre2.txt
+++ b/doc/pcre2.txt
@@ -7678,6 +7678,7 @@ NAMED CAPTURE GROUPS
        and in both cases you want to extract the  abbreviation.  This  pattern
        (ignoring the line breaks) does the job:
 
+         (?J)
          (?Mon|Fri|Sun)(?:day)?|
          (?Tue)(?:sday)?|
          (?Wed)(?:nesday)?|
@@ -7697,7 +7698,7 @@ NAMED CAPTURE GROUPS
        is  set  is  used  for the reference. For example, this pattern matches
        both "foofoo" and "barbar" but not "foobar" or "barfoo":
 
-         (?:(?foo)|(?bar))\k
+         (?J)(?:(?foo)|(?bar))\k
 
 
        If you make a subroutine call to a non-unique named group, the one that
@@ -10629,7 +10630,7 @@ OPTION SETTING
        the end of the group.
 
          (?i)            caseless
-         (?J)            allow duplicate names
+         (?J)            allow duplicate named groups
          (?m)            multiline
          (?n)            no auto capture
          (?s)            single line (dotall)
diff --git a/doc/pcre2pattern.3 b/doc/pcre2pattern.3
index 4819187..9430c6b 100644
--- a/doc/pcre2pattern.3
+++ b/doc/pcre2pattern.3
@@ -1907,6 +1907,7 @@ group can match. Suppose you want to match the name of a weekday, either as a
 3-letter abbreviation or as the full name, and in both cases you want to
 extract the abbreviation. This pattern (ignoring the line breaks) does the job:
 .sp
+  (?J)
   (?Mon|Fri|Sun)(?:day)?|
   (?Tue)(?:sday)?|
   (?Wed)(?:nesday)?|
@@ -1926,7 +1927,7 @@ they appear in the overall pattern. The first one that is set is used for the
 reference. For example, this pattern matches both "foofoo" and "barbar" but not
 "foobar" or "barfoo":
 .sp
-  (?:(?foo)|(?bar))\ek
+  (?J)(?:(?foo)|(?bar))\ek
 .sp
 .P
 If you make a subroutine call to a non-unique named group, the one that
diff --git a/doc/pcre2syntax.3 b/doc/pcre2syntax.3
index 765ddbf..8e08f9b 100644
--- a/doc/pcre2syntax.3
+++ b/doc/pcre2syntax.3
@@ -441,7 +441,7 @@ Changes of these options within a group are automatically cancelled at the end
 of the group.
 .sp
   (?i)            caseless
-  (?J)            allow duplicate names
+  (?J)            allow duplicate named groups
   (?m)            multiline
   (?n)            no auto capture
   (?s)            single line (dotall)