… | |
… | |
495 | Remembers C<$SELF> and creates a closure out of the BLOCK. When the |
495 | Remembers C<$SELF> and creates a closure out of the BLOCK. When the |
496 | closure is executed, sets up the environment in the same way as in C<rcv> |
496 | closure is executed, sets up the environment in the same way as in C<rcv> |
497 | callbacks, i.e. runtime errors will cause the port to get C<kil>ed. |
497 | callbacks, i.e. runtime errors will cause the port to get C<kil>ed. |
498 | |
498 | |
499 | The effect is basically as if it returned C<< sub { peval $SELF, sub { |
499 | The effect is basically as if it returned C<< sub { peval $SELF, sub { |
500 | BLOCK } } >>. |
500 | BLOCK }, @_ } >>. |
501 | |
501 | |
502 | This is useful when you register callbacks from C<rcv> callbacks: |
502 | This is useful when you register callbacks from C<rcv> callbacks: |
503 | |
503 | |
504 | rcv delayed_reply => sub { |
504 | rcv delayed_reply => sub { |
505 | my ($delay, @reply) = @_; |
505 | my ($delay, @reply) = @_; |