sx's '=>' body form (already used for lambdas) works today for top-level function declarations and struct member methods. Pin the surface with examples/139-expression-bodied-fn.sx so a parser regression here surfaces immediately. Coverage: - module-top: double :: (x: s32) -> s32 => x * 2; - niladic: answer :: () -> s32 => 42; - struct method: total :: (self: *Point) -> s32 => self.x + self.y; Next: extend the same form to '#objc_class' member methods (the M2.1(a/b) class-constant + class-method overrides path).
2 lines
2 B
Plaintext
2 lines
2 B
Plaintext
0
|