LYR-PAR0012
a lambda without '=>' before its body
A lambda's parameters, or its parameters and return type, are not followed by =>; or the parameters of a trailing block { a, b => … } are not.
Explanation
A lambda is its parameters in parentheses, an optional : T with its throws, then => and the body: (x: int): int => x * 2. In a trailing block the parameters are followed by => too.
Write => between the signature and the body.
Wrong
fn main(): void {
let f = (x: int): int x => x;
}
Right
fn main(): void {
let f = (x: int): int => x;
let _ = f(1);
}