31 lines
498 B
Plaintext
31 lines
498 B
Plaintext
process foo (?[int]: in, ![int]: out)
|
|
{
|
|
[int]: xs;
|
|
[int]: ys;
|
|
int: n;
|
|
n = 0;
|
|
while (n <> -1)
|
|
{
|
|
in ? xs;
|
|
in ? ys;
|
|
out ! xs; ### Copy
|
|
out ! ys; ### Move
|
|
ys = [];
|
|
seqeach (i : xs)
|
|
{
|
|
ys = ys ++ [i + 5]; ### Move (ys)
|
|
}
|
|
out ! xs; ### Copy
|
|
out ! ys; ### Move
|
|
}
|
|
out ! xs; ### Copy
|
|
ys = xs; ### Move
|
|
out ! ys; ### Move
|
|
}
|
|
|
|
process main (?uint8: in, ![uint8]: out, ![uint8]: err)
|
|
{
|
|
channel [int]: c;
|
|
foo(?c,!c);
|
|
}
|