diff options
author | Michael G. Schwern <schwern@pobox.com> | 2002-08-06 06:05:10 -0700 |
---|---|---|
committer | hv <hv@crypt.org> | 2002-08-17 00:51:19 +0000 |
commit | 6d822dc4045278fb03135b2683bac92dba061369 (patch) | |
tree | 39e9aa0ce54a7caf711f12d43985793b79fb762d /t/op/hashwarn.t | |
parent | 485894a1e3cb3873ba7373c744a8b6231190fbf8 (diff) | |
download | perl-6d822dc4045278fb03135b2683bac92dba061369.tar.gz |
Remove pseudo-hashes (complete)
Message-id: <20020806200510.GC31473@ool-18b93024.dyn.optonline.net>
p4raw-id: //depot/perl@17725
Diffstat (limited to 't/op/hashwarn.t')
-rwxr-xr-x | t/op/hashwarn.t | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/t/op/hashwarn.t b/t/op/hashwarn.t index 3db2b46917..50c993939f 100755 --- a/t/op/hashwarn.t +++ b/t/op/hashwarn.t @@ -66,12 +66,18 @@ my $ref_msg = '/^Reference found where even-sized list expected/'; %hash = sub { print "ok" }; test_warning 6, shift @warnings, $odd_msg; + # Old pseudo-hash syntax, now removed. my $avhv = [{x=>1,y=>2}]; - %$avhv = (x=>13,'y'); - test_warning 7, shift @warnings, $odd_msg; - - %$avhv = 'x'; - test_warning 8, shift @warnings, $odd_msg; + eval { + %$avhv = (x=>13,'y'); + }; + test 7, $@ =~ /^Not a HASH reference/; + + # Old pseudo-hash syntax, since removed. + eval { + %$avhv = 'x'; + }; + test 8, $@ =~ /^Not a HASH reference/; $_ = { 1..10 }; test 9, ! @warnings, "Unexpected warning"; |