diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 1998-05-14 10:53:55 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 1998-05-14 10:53:55 +0000 |
commit | 20408e3ccf502b6ce4033d8203710405ec9ef8f6 (patch) | |
tree | afa7181c847061200a7323363f84fe42102c2aa3 /lib/strict.pm | |
parent | 9b599b2a63d2324ddacddd9710c41b795a95070d (diff) | |
download | perl-20408e3ccf502b6ce4033d8203710405ec9ef8f6.tar.gz |
[win32] merge change#896 from maintbranch
p4raw-link: @896 on //depot/maint-5.004/perl: 0562b9ae2b0eff79632fc0164c13c34c06a019e2
p4raw-id: //depot/win32/perl@938
Diffstat (limited to 'lib/strict.pm')
-rw-r--r-- | lib/strict.pm | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/lib/strict.pm b/lib/strict.pm index 8492e933fd..176af387a0 100644 --- a/lib/strict.pm +++ b/lib/strict.pm @@ -72,14 +72,17 @@ See L<perlmod/Pragmatic Modules>. =cut +$strict::VERSION = "1.01"; + +my %bitmask = ( +refs => 0x00000002, +subs => 0x00000200, +vars => 0x00000400 +); + sub bits { my $bits = 0; - my $sememe; - foreach $sememe (@_) { - $bits |= 0x00000002, next if $sememe eq 'refs'; - $bits |= 0x00000200, next if $sememe eq 'subs'; - $bits |= 0x00000400, next if $sememe eq 'vars'; - } + foreach my $s (@_){ $bits |= $bitmask{$s} || 0; }; $bits; } |