mirror of
https://github.com/fluencelabs/aqua.git
synced 2024-12-13 02:05:32 +00:00
18 lines
336 B
Plaintext
18 lines
336 B
Plaintext
|
service MyOp("op"):
|
||
|
identity(s: string) -> string
|
||
|
|
||
|
service Op("op"):
|
||
|
noop: -> ()
|
||
|
|
||
|
-- peers is of size 2
|
||
|
func gather_values(peers: []string, another_peer: string) -> []string:
|
||
|
values: *string
|
||
|
|
||
|
for peer <- peers par:
|
||
|
on peer:
|
||
|
Op.noop()
|
||
|
values <<- "hello"
|
||
|
|
||
|
on another_peer:
|
||
|
MyOp.identity(values!1)
|
||
|
<- values
|