--- cvsroot/Coro/eg/bench 2001/07/14 22:14:21 1.3 +++ cvsroot/Coro/eg/bench 2001/07/17 00:24:15 1.4 @@ -14,8 +14,9 @@ sub a { $n++; # do something to taint the benchmark results ;) } +$|=1; -$b = new Coro sub { +$b = async { # do a little unrolling... while() { yield; yield; yield; yield; yield; @@ -28,12 +29,12 @@ *transfer = \&Coro::State::transfer; -$c = Coro::State::newprocess { +$c = Coro::State::_newprocess [sub { while() { transfer($c, $main); transfer($c, $main); transfer($c, $main); transfer($c, $main); } -}; +}]; transfer($main, $c);