1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
package Thread; require Exporter; require DynaLoader; @ISA = qw(Exporter DynaLoader); @EXPORT_OK = qw(yield cond_signal cond_broadcast cond_wait async); # # Methods # # # Exported functions # sub async (&) { return new Thread $_[0]; } bootstrap Thread; 1;