Fix syntax bugs
This commit is contained in:
@@ -86,13 +86,13 @@ Macro calls use `!` followed by parentheses, brackets, or braces.
|
||||
let add = (a, b) => a + b;
|
||||
let result = add(2, 3); // 5
|
||||
|
||||
let square = f64 x => x * x;
|
||||
f64 fn() square = (x) => x * x;
|
||||
```
|
||||
|
||||
Closures can have explicit return types:
|
||||
|
||||
```mist
|
||||
let transform = i32 x => {
|
||||
let transform = i32 (x) => {
|
||||
x * 2
|
||||
};
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user