diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2005-12-15 18:00:34 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2005-12-15 18:00:34 +0000 |
commit | 2e6a7e23333d305fb863f36ae0c2231e95e85865 (patch) | |
tree | fd2be062bdf11d7ba1d78c2596ddb61702f74754 /pod/perl593delta.pod | |
parent | ce8abf5f5d2e5b19646ab17c24a3ea87c70428c8 (diff) | |
download | perl-2e6a7e23333d305fb863f36ae0c2231e95e85865.tar.gz |
Fix for [perl #37886] strict 'refs' doesn't apply inside defined
p4raw-id: //depot/perl@26374
Diffstat (limited to 'pod/perl593delta.pod')
-rw-r--r-- | pod/perl593delta.pod | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/pod/perl593delta.pod b/pod/perl593delta.pod index 9ebc819865..b6f7b40756 100644 --- a/pod/perl593delta.pod +++ b/pod/perl593delta.pod @@ -29,6 +29,20 @@ a number of misparsing issues when a global C<_> subroutine is defined. =head1 Selected Bug Fixes +=head2 C<defined $$x> + +C<use strict "refs"> was ignoring taking a hard reference in an argument +to defined(), as in : + + use strict "refs"; + my $x = "foo"; + if (defined $$x) {...} + +This now correctly produces the run-time error C<Can't use string as a +SCALAR ref while "strict refs" in use>. (However, C<defined @$foo> and +C<defined %$foo> are still allowed. Those constructs are discouraged +anyway.) + =head1 New or Changed Diagnostics =head1 Changed Internals |