… | |
… | |
391 | use Errno (); |
391 | use Errno (); |
392 | use Guard (); |
392 | use Guard (); |
393 | |
393 | |
394 | use AnyEvent; |
394 | use AnyEvent; |
395 | |
395 | |
396 | our $VERSION = 1.1; |
396 | our $VERSION = 1.2; |
397 | |
397 | |
398 | =item my $rpc = AnyEvent::Fork::RPC::run $fork, $function, [key => value...] |
398 | =item my $rpc = AnyEvent::Fork::RPC::run $fork, $function, [key => value...] |
399 | |
399 | |
400 | The traditional way to call it. But it is way cooler to call it in the |
400 | The traditional way to call it. But it is way cooler to call it in the |
401 | following way: |
401 | following way: |
… | |
… | |
796 | knows nothing about (why else would one use the async backend if not for |
796 | knows nothing about (why else would one use the async backend if not for |
797 | the ability to register watchers?), the event loop would often happily |
797 | the ability to register watchers?), the event loop would often happily |
798 | continue. |
798 | continue. |
799 | |
799 | |
800 | This is why the asynchronous backend explicitly calls C<CORE::exit> when |
800 | This is why the asynchronous backend explicitly calls C<CORE::exit> when |
801 | it is done (it will raise an exception under other circumstances, which |
801 | it is done (under other circumstances, such as when there is an I/O error |
802 | might lead to the process not exiting on it's own). |
802 | and there is outstanding data to write, it will log a fatal message via |
|
|
803 | L<AnyEvent::Log>, also causing the program to exit). |
803 | |
804 | |
804 | You can override this by specifying a function name to call via the C<done> |
805 | You can override this by specifying a function name to call via the C<done> |
805 | parameter instead. |
806 | parameter instead. |
806 | |
807 | |
807 | =back |
808 | =back |