mirror of
https://github.com/fluencelabs/aqua.git
synced 2025-03-15 11:40:50 +00:00
34 lines
770 B
Plaintext
34 lines
770 B
Plaintext
aqua A
|
|
|
|
export test
|
|
|
|
ability InnerAb:
|
|
arrow() -> i8, i8
|
|
|
|
ability TestAb:
|
|
inner: InnerAb
|
|
|
|
-- func create(a: i8, b: i8) -> TestAb:
|
|
-- arrow = () -> i8, i8:
|
|
-- <- a, b
|
|
-- <- TestAb(inner = InnerAb(arrow = arrow))
|
|
--
|
|
-- func test() -> i8, i8, i8, i8, i8, i8:
|
|
-- Ab <- create(1, 2)
|
|
-- ab <- create(3, 4)
|
|
-- AB <- create(5, 6)
|
|
-- res1, res2 <- ab.inner.arrow()
|
|
-- res3, res4 <- Ab.inner.arrow()
|
|
-- res5, res6 <- AB.inner.arrow()
|
|
-- <- res1, res2, res3, res4, res5, res6
|
|
|
|
func create(a: i8, b: i8) -> i8 -> i8, i8:
|
|
arrow = (c: i8) -> i8, i8:
|
|
<- a, b
|
|
<- arrow
|
|
|
|
func test() -> i8, i8, i8, i8, i8, i8:
|
|
Ab <- create(1, 2)
|
|
ab <- create(3, 4)
|
|
AB <- create(5, 6)
|
|
<- res1, res2, res3, res4, res5, res6 |