GH-196 pattern matching lhs #701

Merged
zxq9 merged 6 commits from GH-196-pattern-matching-lhs into lima 2020-01-15 17:41:04 +09:00
Showing only changes of commit 0c2c7e0ed6 - Show all commits

View File

@ -20,6 +20,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
function somes(xs : list(option('a))) : list('a) = function somes(xs : list(option('a))) : list('a) =
[ x | Some(x) <- xs ] [ x | Some(x) <- xs ]
``` ```
- Allow pattern matching in let-bindings (aborting on match failures):
```
function test(m : map(int, int)) =
let Some(x) = Map.lookup(m, 0)
x
```
### Changed ### Changed
- FATE code generator improvements. - FATE code generator improvements.
### Removed ### Removed