Infer final expression returns in lambdas

This commit is contained in:
pavel 2026-08-27 23:31:46 +02:00
commit 72606e7818
6 changed files with 300 additions and 7 deletions

View file

@ -27,6 +27,7 @@ across package boundaries.
- `if`, `else`, `while`, and `for (item in items)`
- function calls
- lambdas like `{ x: Int -> println(x) }` and `{ println(it) }`
- Kotlin-style final-expression returns in value lambdas, for example `{ value -> value * 2 }`
- `class` with primary-constructor fields and methods
- `interface` with method signatures
- Rust-style algebraic `enum` declarations with payload variants and exhaustive `match`