summaryrefslogtreecommitdiff
path: root/t/lib/strict
diff options
context:
space:
mode:
Diffstat (limited to 't/lib/strict')
-rw-r--r--t/lib/strict/vars6
1 files changed, 4 insertions, 2 deletions
diff --git a/t/lib/strict/vars b/t/lib/strict/vars
index 06d9e0059e..16deab9837 100644
--- a/t/lib/strict/vars
+++ b/t/lib/strict/vars
@@ -372,14 +372,14 @@ EXPECT
20
########
-# multiple our declarations in same scope, same package, no warning
+# multiple our declarations in same scope, same package, warning
use strict 'vars';
use warnings;
our $foo;
${foo} = 10;
our $foo;
EXPECT
-
+"our" variable $foo redeclared at - line 7.
########
# multiple our declarations in same scope, same package, warning
@@ -390,12 +390,14 @@ use warnings;
our $foo;
{
our $foo;
+ our $foo;
package Foo;
our $foo;
}
EXPECT
"our" variable $foo redeclared at - line 9.
(Did you mean "local" instead of "our"?)
+"our" variable $foo redeclared at - line 10.
########
--FILE-- abc