|
|
1 | BEGIN { |
|
|
2 | if ($^O =~ /mswin32/i) { |
|
|
3 | print <<EOF; |
|
|
4 | 1..0 # Perl binary broken, skipping test. Upgrading to a working perl is advised. |
|
|
5 | EOF |
|
|
6 | exit 0; |
|
|
7 | } |
|
|
8 | } |
|
|
9 | |
1 | BEGIN { $| = 1; print "1..5\n"; } |
10 | BEGIN { $| = 1; print "1..5\n"; } |
2 | |
11 | |
3 | use Coro; |
12 | use Coro; |
4 | |
13 | |
5 | print "ok 1\n"; |
14 | print "ok 1\n"; |
… | |
… | |
21 | 3 == $? >> 8 |
30 | 3 == $? >> 8 |
22 | ? "not " : "", "ok 3\n"; |
31 | ? "not " : "", "ok 3\n"; |
23 | |
32 | |
24 | my $coro = new Coro sub { |
33 | my $coro = new Coro sub { |
25 | print "ok 5\n"; |
34 | print "ok 5\n"; |
26 | Coro::State::_exit 0; |
35 | Coro::Util::_exit 0; |
27 | }; |
36 | }; |
28 | |
37 | |
29 | $Coro::idle = sub { |
38 | $Coro::idle = sub { |
30 | $coro->ready; |
39 | $coro->ready; |
31 | }; |
40 | }; |