Skip to content
This repository
Fetching contributors…

Octocat-spinner-32-eaf2f5

Cannot retrieve contributors at this time

file 27 lines (18 sloc) 0.447 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
#!./parrot nqp.pbc

# Copyright (C) 2012, Parrot Foundation.

plan(3);

my $x := "ok 2 - sub sucessfully called from Task";
my $sub := sub foo() {
    say($x);
}

say("# Task ...");
my $task := pir::new__PSP('Task', $sub);

say("ok 1 - created a Task PMC from nqp");

pir::schedule__0P($task);
pir::wait__0P($task);

say("ok 3 - wait on a task");

# Local Variables:
# mode: nqp
# fill-column: 100
# End:
# vim: expandtab shiftwidth=4 ft=pir:
Something went wrong with that request. Please try again.