r48773 - in /branches/upstream/libcommon-sense-perl/current: Changes META.json META.yml README sense.pm

angelabad-guest at users.alioth.debian.org angelabad-guest at users.alioth.debian.org
Tue Dec 15 10:44:34 UTC 2009


Author: angelabad-guest
Date: Tue Dec 15 10:44:27 2009
New Revision: 48773

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=48773
Log:
[svn-upgrade] Integrating new upstream version, libcommon-sense-perl (3.0)

Modified:
    branches/upstream/libcommon-sense-perl/current/Changes
    branches/upstream/libcommon-sense-perl/current/META.json
    branches/upstream/libcommon-sense-perl/current/META.yml
    branches/upstream/libcommon-sense-perl/current/README
    branches/upstream/libcommon-sense-perl/current/sense.pm

Modified: branches/upstream/libcommon-sense-perl/current/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libcommon-sense-perl/current/Changes?rev=48773&op=diff
==============================================================================
--- branches/upstream/libcommon-sense-perl/current/Changes (original)
+++ branches/upstream/libcommon-sense-perl/current/Changes Tue Dec 15 10:44:27 2009
@@ -1,4 +1,12 @@
 Revision history for perl pragma common::sense.
+
+3.0  Tue Dec 15 03:24:28 CET 2009
+	- enable "use utf8" effect by default.
+	- removed "utf8" warning category. while this contains useful security
+          stuff, it also makes implementing security stuff almost impossible,
+          as it completely mangles perls internal utf8 encoding with actual
+          utf-8 encoding, and confuses "unicode", "string codepoints" and
+          "utf-8" so much that it becoems practically unusable.
 
 2.03  Wed Dec  2 18:38:53 CET 2009
 	- removed "unopened" warning category, as this breaks "stat _", which

Modified: branches/upstream/libcommon-sense-perl/current/META.json
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libcommon-sense-perl/current/META.json?rev=48773&op=diff
==============================================================================
--- branches/upstream/libcommon-sense-perl/current/META.json (original)
+++ branches/upstream/libcommon-sense-perl/current/META.json Tue Dec 15 10:44:27 2009
@@ -1,1 +1,1 @@
-{"no_index":{"directory":["t","inc"]},"meta-spec":{"version":1.4,"url":"http://module-build.sourceforge.net/META-spec-v1.4.html"},"generated_by":"ExtUtils::MakeMaker version 6.54","distribution_type":"module","version":"2.03","name":"common-sense","author":[],"license":"unknown","build_requires":{"ExtUtils::MakeMaker":0},"requires":{},"abstract":null,"configure_requires":{"ExtUtils::MakeMaker":0}}
+{"no_index":{"directory":["t","inc"]},"meta-spec":{"version":1.4,"url":"http://module-build.sourceforge.net/META-spec-v1.4.html"},"generated_by":"ExtUtils::MakeMaker version 6.54","distribution_type":"module","version":"3.0","name":"common-sense","author":[],"license":"unknown","build_requires":{"ExtUtils::MakeMaker":0},"requires":{},"abstract":null,"configure_requires":{"ExtUtils::MakeMaker":0}}

Modified: branches/upstream/libcommon-sense-perl/current/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libcommon-sense-perl/current/META.yml?rev=48773&op=diff
==============================================================================
--- branches/upstream/libcommon-sense-perl/current/META.yml (original)
+++ branches/upstream/libcommon-sense-perl/current/META.yml Tue Dec 15 10:44:27 2009
@@ -11,7 +11,7 @@
    },
    "generated_by" : "ExtUtils::MakeMaker version 6.54",
    "distribution_type" : "module",
-   "version" : "2.03",
+   "version" : "3.0",
    "name" : "common-sense",
    "author" : [],
    "license" : "unknown",

Modified: branches/upstream/libcommon-sense-perl/current/README
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libcommon-sense-perl/current/README?rev=48773&op=diff
==============================================================================
--- branches/upstream/libcommon-sense-perl/current/README (original)
+++ branches/upstream/libcommon-sense-perl/current/README Tue Dec 15 10:44:27 2009
@@ -6,12 +6,13 @@
 
      # supposed to be the same, with much lower memory usage, as:
      #
+     # use utf8;
      # use strict qw(vars subs);
      # use feature qw(say state switch);
      # no warnings;
      # use warnings qw(FATAL closed threads internal debugging pack substr malloc
      #                 portable prototype inplace io pipe unpack regexp
-     #                 deprecated exiting glob digit printf utf8 layer
+     #                 deprecated exiting glob digit printf layer
      #                 reserved parenthesis taint closure semicolon);
      # no warnings qw(exec newline unopened);
 
@@ -44,6 +45,17 @@
     What follows is a more thorough discussion of what this module does, and
     why it does it, and what the advantages (and disadvantages) of this
     approach are.
+
+    use utf8
+        While it's not common sense to write your programs in UTF-8, it's
+        quickly becoming the most common encoding, and the most convenient
+        encoding available (you can do really nice quoting tricks...).
+        Experience has shown that our programs were either all pure ascii or
+        utf-8, both of which will stay the same.
+
+        There are few drawbacks to enabling UTF-8 source code by default
+        (mainly some speed hits due to bugs in older versions of perl), so
+        this module enables UTF-8 source code encoding by default.
 
     use strict qw(subs vars)
         Using "use strict" is definitely common sense, but "use strict

Modified: branches/upstream/libcommon-sense-perl/current/sense.pm
URL: http://svn.debian.org/wsvn/pkg-perl/branches/upstream/libcommon-sense-perl/current/sense.pm?rev=48773&op=diff
==============================================================================
--- branches/upstream/libcommon-sense-perl/current/sense.pm (original)
+++ branches/upstream/libcommon-sense-perl/current/sense.pm Tue Dec 15 10:44:27 2009
@@ -8,12 +8,13 @@
 
  # supposed to be the same, with much lower memory usage, as:
  #
+ # use utf8;
  # use strict qw(vars subs);
  # use feature qw(say state switch);
  # no warnings;
  # use warnings qw(FATAL closed threads internal debugging pack substr malloc
  #                 portable prototype inplace io pipe unpack regexp
- #                 deprecated exiting glob digit printf utf8 layer
+ #                 deprecated exiting glob digit printf layer
  #                 reserved parenthesis taint closure semicolon);
  # no warnings qw(exec newline unopened);
 
@@ -50,6 +51,18 @@
 
 =over 4
 
+=item use utf8
+
+While it's not common sense to write your programs in UTF-8, it's quickly
+becoming the most common encoding, and the most convenient encoding
+available (you can do really nice quoting tricks...). Experience has shown
+that our programs were either all pure ascii or utf-8, both of which will
+stay the same.
+
+There are few drawbacks to enabling UTF-8 source code by default (mainly
+some speed hits due to bugs in older versions of perl), so this module
+enables UTF-8 source code encoding by default.
+
 =item use strict qw(subs vars)
 
 Using C<use strict> is definitely common sense, but C<use strict
@@ -190,14 +203,14 @@
 
 package common::sense;
 
-our $VERSION = '2.03';
+our $VERSION = '3.0';
 
 # paste this into perl to find bitmask
 
 # no warnings;
 # use warnings qw(FATAL closed threads internal debugging pack substr malloc portable prototype
 #                 inplace io pipe unpack regexp deprecated exiting glob digit printf
-#                 utf8 layer reserved parenthesis taint closure semicolon);
+#                 layer reserved parenthesis taint closure semicolon);
 # no warnings qw(exec newline unopened);
 # BEGIN { warn join "", map "\\x$_", unpack "(H2)*", ${^WARNING_BITS}; exit 0 };
 
@@ -205,10 +218,10 @@
 
 sub import {
    # verified with perl 5.8.0, 5.10.0
-   ${^WARNING_BITS} ^= ${^WARNING_BITS} ^ "\xfc\x3f\x33\x00\x0f\xf3\xcf\xc0\xf3\xfc\x33\x03";
-
-   # use strict vars subs
-   $^H |= 0x00000600;
+   ${^WARNING_BITS} ^= ${^WARNING_BITS} ^ "\xfc\x3f\x33\x00\x0f\xf3\xcf\xc0\xf3\xfc\x33\x00";
+
+   # use utf8, strict vars subs
+   $^H |= 0x00800600;
 
    # use feature
    $^H{feature_switch} =




More information about the Pkg-perl-cvs-commits mailing list