Integrate mainline
[p5sagit/p5-mst-13.2.git] / t / lib / warnings / sv
index 9af58c2..d9aa827 100644 (file)
@@ -180,6 +180,17 @@ $C .= $A ;
 EXPECT
 Use of uninitialized value in concatenation (.) or string at - line 10.
 ########
+# perlbug 20011116.125
+use warnings 'uninitialized';
+$a = undef;
+$foo = join '', $a, "\n";
+$foo = "$a\n";
+$foo = "a:$a\n";
+EXPECT
+Use of uninitialized value in join or string at - line 4.
+Use of uninitialized value in concatenation (.) or string at - line 5.
+Use of uninitialized value in concatenation (.) or string at - line 6.
+########
 # sv.c 
 use warnings 'numeric' ;
 sub TIESCALAR{bless[]} ; 
@@ -251,7 +262,7 @@ no warnings 'redefine' ;
 sub jim {} 
 *jim = \&joe ;
 EXPECT
-Subroutine fred redefined at - line 5.
+Subroutine main::fred redefined at - line 5.
 ########
 # sv.c
 use warnings 'printf' ;
@@ -326,3 +337,11 @@ no warnings 'numeric' ;
 $a = "\x{100}\x{200}" * 42;
 EXPECT
 Argument "\x{100}\x{200}" isn't numeric in multiplication (*) at - line 3.
+########
+# sv.c
+use warnings 'numeric' ;
+$a = "\x{100}\x{200}"; $a = -$a;
+no warnings 'numeric' ;
+$a = "\x{100}\x{200}"; $a = -$a;
+EXPECT
+Argument "\x{100}\x{200}" isn't numeric in negation (-) at - line 3.