summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorGurusamy Sarathy <gsar@cpan.org>2000-01-06 00:22:40 +0000
committerGurusamy Sarathy <gsar@cpan.org>2000-01-06 00:22:40 +0000
commit7d4045d48787d5a77a81587f2bcaccfb05f3ff1e (patch)
treed1d2b65309fb7eb4a0173b76ef768fe10e12821c /t
parentd506a20dca04253441c06a876baccc8c83469e95 (diff)
downloadperl-7d4045d48787d5a77a81587f2bcaccfb05f3ff1e.tar.gz
constant ranges could escape bareword check in list context
p4raw-id: //depot/perl@4760
Diffstat (limited to 't')
-rw-r--r--t/pragma/strict-subs18
1 files changed, 18 insertions, 0 deletions
diff --git a/t/pragma/strict-subs b/t/pragma/strict-subs
index deeb381473..ed4fe7a443 100644
--- a/t/pragma/strict-subs
+++ b/t/pragma/strict-subs
@@ -33,6 +33,24 @@ Execution of - aborted due to compilation errors.
########
# strict subs - error
+use strict 'subs' ;
+my @a = (A..Z);
+EXPECT
+Bareword "Z" not allowed while "strict subs" in use at - line 4.
+Bareword "A" not allowed while "strict subs" in use at - line 4.
+Execution of - aborted due to compilation errors.
+########
+
+# strict subs - error
+use strict 'subs' ;
+my $a = (B..Y);
+EXPECT
+Bareword "Y" not allowed while "strict subs" in use at - line 4.
+Bareword "B" not allowed while "strict subs" in use at - line 4.
+Execution of - aborted due to compilation errors.
+########
+
+# strict subs - error
use strict ;
Fred ;
EXPECT