diff options
author | Abigail <abigail@abigail.be> | 2000-09-01 09:07:32 -0400 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2000-09-01 18:19:50 +0000 |
commit | cccdd0804c01f959ef2bcf1b45a2fb56dc4d40a1 (patch) | |
tree | 912972b026d128e737467e4932abacc8db08bf23 /t/pragma | |
parent | 6b356c8efb963846940ef92952cf77e5b86bd65e (diff) | |
download | perl-cccdd0804c01f959ef2bcf1b45a2fb56dc4d40a1.tar.gz |
Re: [PATCH lib/overload.pm] Sanaty checking of arguments to overload::constant
Message-ID: <20000901170732.18249.qmail@foad.org>
p4raw-id: //depot/perl@6983
Diffstat (limited to 't/pragma')
-rwxr-xr-x | t/pragma/overload.t | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/t/pragma/overload.t b/t/pragma/overload.t index 7221d78a77..c142a64c0c 100755 --- a/t/pragma/overload.t +++ b/t/pragma/overload.t @@ -939,7 +939,7 @@ unless ($aaa) { { # check the Odd number of arguments for overload::constant warning my $a = "" ; - $SIG{__WARN__} = sub {$a = @_[0]} ; + local $SIG{__WARN__} = sub {$a = @_[0]} ; $x = eval ' overload::constant "integer" ; ' ; test($a eq "") ; # 210 use warnings 'overload' ; @@ -950,7 +950,7 @@ unless ($aaa) { { # check the `$_[0]' is not an overloadable type warning my $a = "" ; - $SIG{__WARN__} = sub {$a = @_[0]} ; + local $SIG{__WARN__} = sub {$a = @_[0]} ; $x = eval ' overload::constant "fred" => sub {} ; ' ; test($a eq "") ; # 212 use warnings 'overload' ; @@ -961,7 +961,7 @@ unless ($aaa) { { # check the `$_[1]' is not a code reference warning my $a = "" ; - $SIG{__WARN__} = sub {$a = @_[0]} ; + local $SIG{__WARN__} = sub {$a = @_[0]} ; $x = eval ' overload::constant "integer" => 1; ' ; test($a eq "") ; # 214 use warnings 'overload' ; |