diff options
author | Father Chrysostomos <sprout@cpan.org> | 2012-05-21 13:52:29 -0700 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2012-05-21 17:51:55 -0700 |
commit | b41bf23f2b8c6b924aea825b7135a4e70a5ebd29 (patch) | |
tree | b8739775cf91653e8e597fb3c6fa42ddfed7f5b6 /pod | |
parent | 3f38d37f755ccbb11c56a809829adea1496d2464 (diff) | |
download | perl-b41bf23f2b8c6b924aea825b7135a4e70a5ebd29.tar.gz |
perldiag: Rewrap symref error for better splain output
Before:
(F) You've told Perl to dereference a string, something which use strict
blocks to prevent it happening accidentally. See
"Symbolic references" in perlref. This can be triggered by an @ or $ in a
double-quoted string immediately before interpolating a variable, for example
in "user @$twitter_id", which says to treat the contents of $twitter_id
as an array reference; use a \ to have a literal @ symbol followed by the
contents of $twitter_id: "user \@$twitter_id".
After:
(F) You've told Perl to dereference a string, something which
use strict blocks to prevent it happening accidentally. See
"Symbolic references" in perlref. This can be triggered by an @ or $
in a double-quoted string immediately before interpolating a variable,
for example in "user @$twitter_id", which says to treat the contents
of $twitter_id as an array reference; use a \ to have a literal @
symbol followed by the contents of $twitter_id: "user \@$twitter_id".
Diffstat (limited to 'pod')
-rw-r--r-- | pod/perldiag.pod | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/pod/perldiag.pod b/pod/perldiag.pod index 3cf0188b52..08d52c7ac6 100644 --- a/pod/perldiag.pod +++ b/pod/perldiag.pod @@ -1268,13 +1268,13 @@ test the type of the reference, if need be. =item Can't use string ("%s") as %s ref while "strict refs" in use -(F) You've told Perl to dereference a string, something which C<use strict> -blocks to prevent it happening accidentally. See -L<perlref/"Symbolic references">. This can be triggered by an C<@> or C<$> in a -double-quoted string immediately before interpolating a variable, for example -in C<"user @$twitter_id">, which says to treat the contents of C<$twitter_id> -as an array reference; use a C<\> to have a literal C<@> symbol followed by the -contents of C<$twitter_id>: C<"user \@$twitter_id">. +(F) You've told Perl to dereference a string, something which +C<use strict> blocks to prevent it happening accidentally. See +L<perlref/"Symbolic references">. This can be triggered by an C<@> or C<$> +in a double-quoted string immediately before interpolating a variable, +for example in C<"user @$twitter_id">, which says to treat the contents +of C<$twitter_id> as an array reference; use a C<\> to have a literal C<@> +symbol followed by the contents of C<$twitter_id>: C<"user \@$twitter_id">. =item Can't use subscript on %s |