Skip to content

Instantly share code, notes, and snippets.

@Praetonus
Created March 29, 2017 11:42
Show Gist options
  • Save Praetonus/f2ae2ab3b6543e05ef2dea4622753e6d to your computer and use it in GitHub Desktop.
Save Praetonus/f2ae2ab3b6543e05ef2dea4622753e6d to your computer and use it in GitHub Desktop.
actor A
let _array: Array[U8] = Array[U8]
be send(b: B) =>
let array_copy = recover trn Array[U8] end
array_copy.reserve(_array.size())
for i in _array.values() do
array_copy.push(i)
end
b.receive(consume array_copy)
actor B
be receive(a: Array[U8] val) =>
None
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment