This queue is for tickets about the IO-Async CPAN distribution.

Report information
The Basics
Id:
107854
Status:
open
Priority:
Low/Low
Queue:

People
Owner:
Nobody in particular
Requestors:
kes-kes [...] yandex.ru
Cc:
AdminCc:

BugTracker
Severity:
Important
Broken in:
(no value)
Fixed in:
(no value)



Subject: Listener documenation mistake
Hi In example you show that on_stream expect two arguments: my $listener = IO::Async::Listener->new( on_stream => sub { my ( undef, $stream ) = @_; but link http://search.cpan.org/~pevans/IO-Async-0.68/lib/IO/Async/Listener.pm#on_stream_$stream describe only one
On Mon Oct 19 07:29:49 2015, kes-kes@yandex.ru wrote:
Show quoted text
> Hi > In example you show that on_stream expect two arguments: > > my $listener = IO::Async::Listener->new( > on_stream => sub { > my ( undef, $stream ) = @_; > > but link http://search.cpan.org/~pevans/IO-Async- > 0.68/lib/IO/Async/Listener.pm#on_stream_$stream > describe only one
That's just ignoring the $self that always appears as the first argument to any event handler. It's similar to it being the first argument of a method call - that fact is usually glossed over in the documentation. -- Paul Evans


This service runs on Request Tracker, is sponsored by The Perl Foundation, and maintained by Best Practical Solutions.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.