Lima master merge #776

Merged
zxq9 merged 26 commits from lima-master-merge into master 2020-10-16 02:50:48 +09:00
Showing only changes of commit 6b60fde2df - Show all commits

View File

@ -22,7 +22,9 @@ namespace Option =
/** Assume it is `Some`
*/
function force(o : option('a)) : 'a = default(abort("Forced None value"), o)
function force(o : option('a)) : 'a = switch(o)
None => abort("Forced None value")
Some(x) => x
function on_elem(o : option('a), f : 'a => unit) : unit = match((), f, o)