Navigation Menu

Skip to content

Commit

Permalink
[operators] let and temp
Browse files Browse the repository at this point in the history
  • Loading branch information
moritz committed Aug 11, 2012
1 parent d1e3098 commit 19de2cf
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions lib/operators.pod
Expand Up @@ -481,4 +481,22 @@ details.
Creates a I<one> L<Junction> from its arguments. See L<Junction> for more
details.
=head1 Named Unary Precedence
=head2 prefix temp
sub prefix:<temp>(Mu $a is rw)
"temporizes" the variable passed as the argument, which means it is reset
to its old value on scope exit. (This is similar to the
L<local|http://perldoc.perl.org/functions/local.html> operator in Perl 5,
except that C<temp> does not reset the value).
=head2 prefix let
sub prefix:<let>(Mu $a is rw)
Hypothetical reset: if the current scope is exited either through an exception
or C<fail()>, the old value is restored.
=end pod

0 comments on commit 19de2cf

Please sign in to comment.