Revert change #29098 (that introduced a new warning,
authorRafael Garcia-Suarez <rgarciasuarez@gmail.com>
Fri, 24 Nov 2006 10:16:07 +0000 (10:16 +0000)
committerRafael Garcia-Suarez <rgarciasuarez@gmail.com>
Fri, 24 Nov 2006 10:16:07 +0000 (10:16 +0000)
"Variable length character upgraded in print")
p4raw-link: @29098 on //depot/perl: f46fa3876d9373760a3cd5dd806719154ff55bcb

p4raw-id: //depot/perl@29372

doio.c
pod/perl595delta.pod
pod/perldiag.pod

diff --git a/doio.c b/doio.c
index 88afb1d..e0a1fc5 100644 (file)
--- a/doio.c
+++ b/doio.c
@@ -1225,14 +1225,9 @@ Perl_do_print(pTHX_ register SV *sv, PerlIO *fp)
        tmps = SvPV_const(sv, len);
        if (PerlIO_isutf8(fp)) {
            if (!SvUTF8(sv)) {
-               const STRLEN origlen = len;
                /* We don't modify the original scalar.  */
                tmpbuf = bytes_to_utf8((const U8*) tmps, &len);
                tmps = (char *) tmpbuf;
-               if (ckWARN(WARN_UTF8) && len != origlen) {
-                   Perl_warner(aTHX_ packWARN(WARN_UTF8),
-                               "Variable length character upgraded in print");
-               }
            }
        }
        else if (DO_UTF8(sv)) {
index 41562cb..c3d59ec 100644 (file)
@@ -249,12 +249,6 @@ accordingly to the contents of that %INC entry.
 
 =head1 New or Changed Diagnostics
 
-=head2 Variable length character upgraded in print
-
-This new UTF-8 warning indicates a situation where a non-Unicode string is
-sent to a UTF-8 output layer, but given what the string contains, encoding
-problems such as double UTF-8 encoding might arise. See L<perldiag>.
-
 =head1 Changed Internals
 
 The anonymous hash and array constructors now take 1 op in the optree
index 26c2bf5..cec3945 100644 (file)
@@ -4790,18 +4790,6 @@ front of your variable.
 (F) Lookbehind is allowed only for subexpressions whose length is fixed and
 known at compile time.  See L<perlre>.
 
-=item Variable length character upgraded in print
-
-(W utf8) Perl met a variable length character that is not marked with
-Unicode in the output, but the output layer (like the C<:utf8> layer) does
-not expect that. (A variable length character is defined by having
-different memory representations between the native encoding (ISO-8859-1
-or single-byte EBCDIC) and perl's Unicode encoding (UTF-8 or UTF-EBCDIC).)
-Perl assumes any strings that are not marked as Unicode to be encoded in
-the native encoding, and implicitly converts (upgrades) them into perl's
-Unicode encoding on print. If you had intended to treat them as Unicode
-strings, you might have failed to cope with them properly.
-
 =item "%s" variable %s masks earlier declaration in same %s
 
 (W misc) A "my" or "our" variable has been redeclared in the current