Skip to content

Instantly share code, notes, and snippets.

@zoffixznet

zoffixznet/p6.p6 Secret

Created October 25, 2017 09:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zoffixznet/2b2364005f15dfc887b0226a1a199536 to your computer and use it in GitHub Desktop.
Save zoffixznet/2b2364005f15dfc887b0226a1a199536 to your computer and use it in GitHub Desktop.
IO::Socket::Async.listen('127.0.0.1', 15600+$_).tap: *.say
for ^20;
start react whenever IO::Socket::Async.listen('127.0.0.1', 15555) {
supply {
say 'got here';
whenever $_ {
say 'but not here';
exit;
}
}.list
}
sleep .1;
.print: "x\n" with IO::Socket::INET.new: :host<127.0.0.1>, :15555port;
sleep 2;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment