… | |
… | |
1005 | # AnyEvent not yet initialised, so make sure to load Coro::AnyEvent |
1005 | # AnyEvent not yet initialised, so make sure to load Coro::AnyEvent |
1006 | # as soon as it is |
1006 | # as soon as it is |
1007 | push @AnyEvent::post_detect, sub { require Coro::AnyEvent }; |
1007 | push @AnyEvent::post_detect, sub { require Coro::AnyEvent }; |
1008 | } |
1008 | } |
1009 | |
1009 | |
1010 | =item AnyEvent::postpone BLOCK |
1010 | =item AnyEvent::postpone { BLOCK } |
1011 | |
1011 | |
1012 | Arranges for the block to be executed as soon as possible, but not before |
1012 | Arranges for the block to be executed as soon as possible, but not before |
1013 | the call itself returns. In practise, the block will be executed just |
1013 | the call itself returns. In practise, the block will be executed just |
1014 | before the event loop polls for new events, or shortly afterwards. |
1014 | before the event loop polls for new events, or shortly afterwards. |
1015 | |
1015 | |
… | |
… | |
1453 | |
1453 | |
1454 | sub time() { |
1454 | sub time() { |
1455 | AnyEvent->time |
1455 | AnyEvent->time |
1456 | } |
1456 | } |
1457 | |
1457 | |
|
|
1458 | *postpone = \&AnyEvent::postpone; |
|
|
1459 | |
1458 | package AnyEvent::Base; |
1460 | package AnyEvent::Base; |
1459 | |
1461 | |
1460 | # default implementations for many methods |
1462 | # default implementations for many methods |
1461 | |
1463 | |
1462 | sub time { |
1464 | sub time { |