diff options
-rw-r--r-- | lib/feature.pm | 7 | ||||
-rw-r--r-- | pod/perlref.pod | 4 | ||||
-rwxr-xr-x | regen/feature.pl | 7 |
3 files changed, 11 insertions, 7 deletions
diff --git a/lib/feature.pm b/lib/feature.pm index 884712467e..3f8f89dadb 100644 --- a/lib/feature.pm +++ b/lib/feature.pm @@ -272,9 +272,10 @@ regardless of what feature declarations are in scope. =head2 The 'postderef' and 'postderef_qq' features The 'postderef_qq' feature extends the applicability of L<postfix -dereference syntax|perlref/Postfix Dereference Syntax> so that postfix array -and scalar dereference are available in double-quotish interpolations. For -example, it makes the following two statements equivalent: +dereference syntax|perlref/Postfix Dereference Syntax> so that +postfix array dereference, postfix scalar dereference, and +postfix array highest index access are available in double-quotish interpolations. +For example, it makes the following two statements equivalent: my $s = "[@{ $h->{a} }]"; my $s = "[$h->{a}->@*]"; diff --git a/pod/perlref.pod b/pod/perlref.pod index 2fd321b0b4..6934e0bb7e 100644 --- a/pod/perlref.pod +++ b/pod/perlref.pod @@ -757,7 +757,9 @@ Glob elements can be extracted through the postfix dereferencing feature: Postfix array and scalar dereferencing I<can> be used in interpolating strings (double quotes or the C<qq> operator), but only if the -C<postderef_qq> feature is enabled. +C<postderef_qq> feature is enabled. Interpolation of postfix array highest index +access (C<< ->$#* >>) is also supported when the C<postderef_qq> feature is +enabled. =head2 Postfix Reference Slicing diff --git a/regen/feature.pl b/regen/feature.pl index 51e5ae008e..a23757a78e 100755 --- a/regen/feature.pl +++ b/regen/feature.pl @@ -692,9 +692,10 @@ regardless of what feature declarations are in scope. =head2 The 'postderef' and 'postderef_qq' features The 'postderef_qq' feature extends the applicability of L<postfix -dereference syntax|perlref/Postfix Dereference Syntax> so that postfix array -and scalar dereference are available in double-quotish interpolations. For -example, it makes the following two statements equivalent: +dereference syntax|perlref/Postfix Dereference Syntax> so that +postfix array dereference, postfix scalar dereference, and +postfix array highest index access are available in double-quotish interpolations. +For example, it makes the following two statements equivalent: my $s = "[@{ $h->{a} }]"; my $s = "[$h->{a}->@*]"; |