erg/examples/declare.d.er
2022-11-07 17:37:46 +09:00

15 lines
251 B
Python

.x: Int
.f: Int -> Int
.C: ClassType
# or .C.__call__: Int -> .C
.C.__call__: (x: Int) -> .C
.C.f: (self: .C, y: Int) -> Int
#[
# Class declaration syntax
.C: ClassType {.x = Int}
.C.
__call__: (x: Int) -> .C
f: (self: .C, y: Int) -> Int
]#