async
$t= async {block};
- Creates a new thread to execute the block that follows it. The block is treated as an anonymous subroutine (and therefore has a semicolon after the closing bracket). Returns a thread object.
asyncisn't exported by default, so you can either specifyuse Thread qw(async);or fully qualify the name (Thread::async).