In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/b3632c7127dbc8ae2250b65ba913d59a6e1caac6?hp=fe427a6378fe383fb343e07edbe0afaf4c9a18e0>

- Log -----------------------------------------------------------------
commit b3632c7127dbc8ae2250b65ba913d59a6e1caac6
Author: Karl Williamson <[email protected]>
Date:   Mon Mar 28 21:14:58 2016 -0600

    toke.c: Fix comment

M       toke.c

commit 61463a3eba401750124ace520c1bd60db4301a84
Author: Karl Williamson <[email protected]>
Date:   Mon Mar 28 21:04:40 2016 -0600

    Stop accepting deprecated NBSP in \N{}
    
    As scheduled for 5.26, this construct will no longer be accepted.

M       charclass_invlists.h
M       l1_char_class_tab.h
M       lib/_charnames.pm
M       lib/charnames.pm
M       lib/unicore/mktables
M       pod/perldelta.pod
M       pod/perldiag.pod
M       regcharclass.h
M       t/lib/charnames/alias
M       t/re/pat_advanced.t
M       toke.c
-----------------------------------------------------------------------

Summary of changes:
 charclass_invlists.h  |  2 +-
 l1_char_class_tab.h   |  6 +++---
 lib/_charnames.pm     |  9 +--------
 lib/charnames.pm      |  2 +-
 lib/unicore/mktables  |  1 -
 pod/perldelta.pod     |  9 +++------
 pod/perldiag.pod      |  8 --------
 regcharclass.h        |  2 +-
 t/lib/charnames/alias | 10 ++--------
 t/re/pat_advanced.t   | 36 ++++--------------------------------
 toke.c                | 17 ++---------------
 11 files changed, 18 insertions(+), 84 deletions(-)

diff --git a/charclass_invlists.h b/charclass_invlists.h
index 50ac8e3..629c066 100644
--- a/charclass_invlists.h
+++ b/charclass_invlists.h
@@ -87887,7 +87887,7 @@ static const U8 WB_table[19][19] = {
  * 1a0687fb9c6c4567e853913549df0944fe40821279a3e9cdaa6ab8679bc286fd 
lib/unicore/extracted/DLineBreak.txt
  * 40bcfed3ca727c19e1331f6c33806231d5f7eeeabd2e6a9e06a3740c85d0c250 
lib/unicore/extracted/DNumType.txt
  * a18d502bad39d527ac5586d7bc93e29f565859e3bcc24ada627eff606d6f5fed 
lib/unicore/extracted/DNumValues.txt
- * a054c7cdbdc57cf0a8ffb16b0b4944800df23fd6d76fc3c46ba58c5d2b38baf0 
lib/unicore/mktables
+ * 718d6ea8b96ee3d12c9c3a48ceb0f5cebe023634002ac8b2ede12b306273aa52 
lib/unicore/mktables
  * 462c9aaa608fb2014cd9649af1c5c009485c60b9c8b15b89401fdc10cf6161c6 
lib/unicore/version
  * 913d2f93f3cb6cdf1664db888bf840bc4eb074eef824e082fceda24a9445e60c 
regen/charset_translations.pl
  * 12bd58cb9d5a99f631ca95e269f7f9c90dacaf81020efa5d95a995f3cdc19200 
regen/mk_invlists.pl
diff --git a/l1_char_class_tab.h b/l1_char_class_tab.h
index 7602a78..df73664 100644
--- a/l1_char_class_tab.h
+++ b/l1_char_class_tab.h
@@ -168,7 +168,7 @@
 /* U+9D OSC */ (1U<<_CC_CNTRL)|(1U<<_CC_QUOTEMETA),
 /* U+9E PM */ (1U<<_CC_CNTRL)|(1U<<_CC_QUOTEMETA),
 /* U+9F APC */ (1U<<_CC_CNTRL)|(1U<<_CC_QUOTEMETA),
-/* U+A0 NBSP */ 
(1U<<_CC_BLANK)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA)|(1U<<_CC_SPACE),
+/* U+A0 NBSP */ 
(1U<<_CC_BLANK)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA)|(1U<<_CC_SPACE),
 /* U+A1 INVERTED '!' */ 
(1U<<_CC_GRAPH)|(1U<<_CC_PRINT)|(1U<<_CC_PUNCT)|(1U<<_CC_QUOTEMETA),
 /* U+A2 CENT */ (1U<<_CC_GRAPH)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA),
 /* U+A3 POUND */ (1U<<_CC_GRAPH)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA),
@@ -336,7 +336,7 @@
 /* 0x3E U+9E PM */ (1U<<_CC_CNTRL)|(1U<<_CC_QUOTEMETA),
 /* 0x3F U+1A SUB */ (1U<<_CC_ASCII)|(1U<<_CC_CNTRL)|(1U<<_CC_QUOTEMETA),
 /* 0x40 U+20 SP */ 
(1U<<_CC_ASCII)|(1U<<_CC_BLANK)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA)|(1U<<_CC_SPACE),
-/* 0x41 U+A0 NBSP */ 
(1U<<_CC_BLANK)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA)|(1U<<_CC_SPACE)|(1U<<_CC_UTF8_IS_CONTINUATION),
+/* 0x41 U+A0 NBSP */ 
(1U<<_CC_BLANK)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA)|(1U<<_CC_SPACE)|(1U<<_CC_UTF8_IS_CONTINUATION),
 /* 0x42 U+E2 I8=A1 a with '^' */ 
(1U<<_CC_ALPHANUMERIC)|(1U<<_CC_ALPHA)|(1U<<_CC_CASED)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_GRAPH)|(1U<<_CC_IDFIRST)|(1U<<_CC_LOWER)|(1U<<_CC_PRINT)|(1U<<_CC_WORDCHAR)|(1
 ... [55 chars truncated]
 /* 0x43 U+E4 I8=A2 a with diaeresis */ 
(1U<<_CC_ALPHANUMERIC)|(1U<<_CC_ALPHA)|(1U<<_CC_CASED)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_GRAPH)|(1U<<_CC_IDFIRST)|(1U<<_CC_LOWER)|(1U<<_CC_PRINT)|(1U<<_CC_WORDCH
 ... [61 chars truncated]
 /* 0x44 U+E0 I8=A3 a with grave */ 
(1U<<_CC_ALPHANUMERIC)|(1U<<_CC_ALPHA)|(1U<<_CC_CASED)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_GRAPH)|(1U<<_CC_IDFIRST)|(1U<<_CC_LOWER)|(1U<<_CC_PRINT)|(1U<<_CC_WORDCHAR)|
 ... [57 chars truncated]
@@ -599,7 +599,7 @@
 /* 0x3E U+9E PM */ (1U<<_CC_CNTRL)|(1U<<_CC_QUOTEMETA),
 /* 0x3F U+1A SUB */ (1U<<_CC_ASCII)|(1U<<_CC_CNTRL)|(1U<<_CC_QUOTEMETA),
 /* 0x40 U+20 SP */ 
(1U<<_CC_ASCII)|(1U<<_CC_BLANK)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA)|(1U<<_CC_SPACE),
-/* 0x41 U+A0 NBSP */ 
(1U<<_CC_BLANK)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA)|(1U<<_CC_SPACE)|(1U<<_CC_UTF8_IS_CONTINUATION),
+/* 0x41 U+A0 NBSP */ 
(1U<<_CC_BLANK)|(1U<<_CC_PRINT)|(1U<<_CC_QUOTEMETA)|(1U<<_CC_SPACE)|(1U<<_CC_UTF8_IS_CONTINUATION),
 /* 0x42 U+E2 I8=A1 a with '^' */ 
(1U<<_CC_ALPHANUMERIC)|(1U<<_CC_ALPHA)|(1U<<_CC_CASED)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_GRAPH)|(1U<<_CC_IDFIRST)|(1U<<_CC_LOWER)|(1U<<_CC_PRINT)|(1U<<_CC_WORDCHAR)|(1
 ... [55 chars truncated]
 /* 0x43 U+E4 I8=A2 a with diaeresis */ 
(1U<<_CC_ALPHANUMERIC)|(1U<<_CC_ALPHA)|(1U<<_CC_CASED)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_GRAPH)|(1U<<_CC_IDFIRST)|(1U<<_CC_LOWER)|(1U<<_CC_PRINT)|(1U<<_CC_WORDCH
 ... [61 chars truncated]
 /* 0x44 U+E0 I8=A3 a with grave */ 
(1U<<_CC_ALPHANUMERIC)|(1U<<_CC_ALPHA)|(1U<<_CC_CASED)|(1U<<_CC_CHARNAME_CONT)|(1U<<_CC_GRAPH)|(1U<<_CC_IDFIRST)|(1U<<_CC_LOWER)|(1U<<_CC_PRINT)|(1U<<_CC_WORDCHAR)|
 ... [57 chars truncated]
diff --git a/lib/_charnames.pm b/lib/_charnames.pm
index bb7d7c6..50fdd85 100644
--- a/lib/_charnames.pm
+++ b/lib/_charnames.pm
@@ -6,7 +6,7 @@
 package _charnames;
 use strict;
 use warnings;
-our $VERSION = '1.43';
+our $VERSION = '1.44';
 use unicore::Name;    # mktables-generated algorithmically-defined names
 
 use bytes ();          # for $bytes::hint_bits
@@ -202,13 +202,6 @@ sub alias (@) # Set up a single alias
             }
 
             $^H{charnames_name_aliases}{$name} = $value;
-            if (warnings::enabled('deprecated')
-                && $name =~ / ( .* $nbsp ) ( .* ) $ /x)
-            {
-                  carp "NO-BREAK SPACE in a charnames alias definition is "
-                       . "deprecated; marked by <-- HERE in '$1 <-- HERE "
-                       . $2 . "'";
-            }
         }
     }
   }
diff --git a/lib/charnames.pm b/lib/charnames.pm
index 2efe3d5..a0f3227 100644
--- a/lib/charnames.pm
+++ b/lib/charnames.pm
@@ -1,7 +1,7 @@
 package charnames;
 use strict;
 use warnings;
-our $VERSION = '1.43';
+our $VERSION = '1.44';
 use unicore::Name;    # mktables-generated algorithmically-defined names
 use _charnames ();    # The submodule for this where most of the work gets done
 
diff --git a/lib/unicore/mktables b/lib/unicore/mktables
index 9efc759..bea8739 100644
--- a/lib/unicore/mktables
+++ b/lib/unicore/mktables
@@ -14865,7 +14865,6 @@ sub compile_perl() {
                                     + ord("(")
                                     + ord(")")
                                     + ord("-")
-                                    + utf8::unicode_to_native(0xA0) # NBSP
                         );
 
     my @composition = ('Name', 'Unicode_1_Name', '_Perl_Name_Alias');
diff --git a/pod/perldelta.pod b/pod/perldelta.pod
index 3c19b1f..c0dbcab 100644
--- a/pod/perldelta.pod
+++ b/pod/perldelta.pod
@@ -34,13 +34,10 @@ L</Selected Bug Fixes> section.
 
 =head1 Incompatible Changes
 
-XXX For a release on a stable branch, this section aspires to be:
+=head2 C<NBSP> is no longer permissible in C<\N{...}>
 
-    There are no changes intentionally incompatible with 5.XXX.XXX
-    If any exist, they are bugs, and we request that you submit a
-    report.  See L</Reporting Bugs> below.
-
-[ List each incompatible change as a =head2 entry ]
+The name of a character may no longer contain non-breaking spaces.  It
+has been deprecated to do so since Perl v5.22.
 
 =head1 Deprecations
 
diff --git a/pod/perldiag.pod b/pod/perldiag.pod
index 78aeb16..ea0d21e 100644
--- a/pod/perldiag.pod
+++ b/pod/perldiag.pod
@@ -3784,14 +3784,6 @@ setgid script to even be allowed to attempt.  Generally 
speaking there
 will be another way to do what you want that is, if not secure, at least
 securable.  See L<perlsec>.
 
-=item NO-BREAK SPACE in a charnames alias definition is deprecated
-
-(D deprecated) You defined a character name which contained a no-break
-space character.  Change it to a regular space.  Usually these names are
-defined in the C<:alias> import argument to C<use charnames>, but they
-could be defined by a translator installed into C<$^H{charnames}>.  See
-L<charnames/CUSTOM ALIASES>.
-
 =item No code specified for -%c
 
 (F) Perl's B<-e> and B<-E> command-line options require an argument.  If
diff --git a/regcharclass.h b/regcharclass.h
index 08f3dbf..ac5f239 100644
--- a/regcharclass.h
+++ b/regcharclass.h
@@ -1895,7 +1895,7 @@
  * 1a0687fb9c6c4567e853913549df0944fe40821279a3e9cdaa6ab8679bc286fd 
lib/unicore/extracted/DLineBreak.txt
  * 40bcfed3ca727c19e1331f6c33806231d5f7eeeabd2e6a9e06a3740c85d0c250 
lib/unicore/extracted/DNumType.txt
  * a18d502bad39d527ac5586d7bc93e29f565859e3bcc24ada627eff606d6f5fed 
lib/unicore/extracted/DNumValues.txt
- * a054c7cdbdc57cf0a8ffb16b0b4944800df23fd6d76fc3c46ba58c5d2b38baf0 
lib/unicore/mktables
+ * 718d6ea8b96ee3d12c9c3a48ceb0f5cebe023634002ac8b2ede12b306273aa52 
lib/unicore/mktables
  * 462c9aaa608fb2014cd9649af1c5c009485c60b9c8b15b89401fdc10cf6161c6 
lib/unicore/version
  * 913d2f93f3cb6cdf1664db888bf840bc4eb074eef824e082fceda24a9445e60c 
regen/charset_translations.pl
  * d9c04ac46bdd81bb3e26519f2b8eb6242cb12337205add3f7cf092b0c58dccc4 
regen/regcharclass.pl
diff --git a/t/lib/charnames/alias b/t/lib/charnames/alias
index 33ccff4..c0b039f 100644
--- a/t/lib/charnames/alias
+++ b/t/lib/charnames/alias
@@ -416,12 +416,6 @@ use utf8;
 use open qw( :utf8 :std );
 use charnames ":alias" => { "NBSP SEPARATED SPACE" => "BLACK SMILING FACE" };
 print "ok\n" if "\N{NBSP SEPARATED SPACE}" eq "\x{263B}";
-print "ok\n" if "\N{NBSP SEPARATED SPACE}" eq "\x{263B}";
-no warnings 'deprecated';
-print "ok\n" if "\N{NBSP SEPARATED SPACE}" eq "\x{263B}";
 EXPECT
-OPTIONS regex
-NO-BREAK SPACE in a charnames alias definition is deprecated; marked by <-- 
HERE in 'NBSP SEPARATED  <-- HERE SPACE' at - line \d+.
-ok
-ok
-ok
+OPTIONS regex fatal
+Invalid character in charnames alias definition; marked by <-- HERE in 'NBSP 
<-- HERE SEPARATED SPACE' at - line 3
diff --git a/t/re/pat_advanced.t b/t/re/pat_advanced.t
index 913e846..6e0b0da 100644
--- a/t/re/pat_advanced.t
+++ b/t/re/pat_advanced.t
@@ -986,41 +986,13 @@ sub run_tests {
                         . "SPACE";
         my $NBSP_utf8 = $NBSP_Latin1;
         utf8::upgrade($NBSP_utf8);
-        eval qq[is("\\N{$NBSP_Latin1}", "$NBSP_Latin1", "An NBSP in character 
name works")];
-        like ($w, qr/NO-BREAK SPACE in a charnames alias definition is 
deprecated/, "... but returns a deprecation warning");
+        () = eval qq[is("\\N{$NBSP_Latin1}", "$NBSP_Latin1"];
+        like ($@, qr/Invalid character in \\N\{...}/, "A NO-BREAK SPACE in a 
charnames alias is fatal");
         undef $w;
             {
             use feature 'unicode_eval';
-            eval qq[use utf8; is("\\N{$NBSP_utf8}", "$NBSP_utf8", "Same under 
'use utf8': they work")];
-            like ($w, qr/NO-BREAK SPACE in a charnames alias definition is 
deprecated/, "... but return a deprecation warning");
-        }
-        {
-            # disable lexical warnings
-            BEGIN { ${^WARNING_BITS} = undef; $^W = 0 }
-            undef $w;
-            () = eval qq["\\N{$NBSP_Latin1}"];
-            like ($w, qr/NO-BREAK SPACE in a charnames alias definition is 
deprecated/, "And returns a deprecation warning outside of lexical warnings");
-            undef $w;
-            use feature 'unicode_eval';
-            eval qq[use utf8; () = "\\N{$NBSP_utf8}"];
-            like ($w, qr/NO-BREAK SPACE in a charnames alias definition is 
deprecated/, "... same under utf8");
-        }
-        {
-            no warnings 'deprecated';
-            undef $w;
-            eval qq["\\N{$NBSP_Latin1}"];
-            ok (! defined $w, "... and no warning if warnings are off");
-            use feature 'unicode_eval';
-            eval qq[use utf8; "\\N{$NBSP_utf8}"];
-            ok (! defined $w, "... same under 'use utf8'");
-        }
-        {
-            use warnings FATAL=>'deprecated';
-            () = eval qq["\\N{$NBSP_Latin1}"];
-            like ($@, qr/NO-BREAK SPACE in a charnames alias definition is 
deprecated/, "... the warning can be fatal");
-            use feature 'unicode_eval';
-            eval qq[use utf8; () = "\\N{$NBSP_utf8}"];
-            like ($@, qr/NO-BREAK SPACE in a charnames alias definition is 
deprecated/, "... same under utf8");
+            eval qq[use utf8; is("\\N{$NBSP_utf8}"];
+            like ($@, qr/Invalid character in \\N\{...}/, "A NO-BREAK SPACE in 
a charnames alias is fatal");
         }
 
         {
diff --git a/toke.c b/toke.c
index c95f6d2..7daa4a7 100644
--- a/toke.c
+++ b/toke.c
@@ -2588,11 +2588,6 @@ S_get_and_check_backslash_N_name(pTHX_ const char* s, 
const char* const e)
            if (*s == ' ' && *(s-1) == ' ') {
                 goto multi_spaces;
             }
-           if ((U8) *s == NBSP_NATIVE && ckWARN_d(WARN_DEPRECATED)) {
-                Perl_warner(aTHX_ packWARN(WARN_DEPRECATED),
-                           "NO-BREAK SPACE in a charnames "
-                           "alias definition is deprecated");
-            }
             s++;
         }
     }
@@ -2640,14 +2635,6 @@ S_get_and_check_backslash_N_name(pTHX_ const char* s, 
const char* const e)
                 {
                     goto bad_charname;
                 }
-                if (*s == *NBSP_UTF8
-                    && *(s+1) == *(NBSP_UTF8+1)
-                    && ckWARN_d(WARN_DEPRECATED))
-                {
-                    Perl_warner(aTHX_ packWARN(WARN_DEPRECATED),
-                                "NO-BREAK SPACE in a charnames "
-                                "alias definition is deprecated");
-                }
                 s += 2;
             }
             else {
@@ -8904,8 +8891,8 @@ S_scan_word(pTHX_ char *s, char *dest, STRLEN destlen, 
int allow_package, STRLEN
  *          2) '{'
  *     The final case currently doesn't get this far in the program, so we
  *     don't test for it.  If that were to change, it would be ok to allow it.
- *  c) When not under Unicode rules, any upper Latin1 character
- *  d) Otherwise, when unicode rules are used, all XIDS characters.
+ *  b) When not under Unicode rules, any upper Latin1 character
+ *  c) Otherwise, when unicode rules are used, all XIDS characters.
  *
  *      Because all ASCII characters have the same representation whether
  *      encoded in UTF-8 or not, we can use the foo_A macros below and '\0' and

--
Perl5 Master Repository

Reply via email to