--- Coro/Coro.pm 2001/07/25 21:12:57 1.25 +++ Coro/Coro.pm 2001/07/27 02:51:33 1.26 @@ -45,6 +45,7 @@ { my @async; + my $init; # this way of handling attributes simply is NOT scalable ;() sub import { @@ -56,6 +57,13 @@ for (@_) { if ($_ eq "Coro") { push @async, $ref; + unless ($init++) { + eval q{ + sub INIT { + &async(pop @async) while @async; + } + }; + } } else { push @attrs, $_; } @@ -64,9 +72,6 @@ }; } - sub INIT { - &async(pop @async) while @async; - } } =item $main @@ -259,7 +264,7 @@ L, L, L, L, L, L, L, L, -L, L. +L, L. =head1 AUTHOR