mirror of
https://github.com/HigherOrderCO/Bend.git
synced 2024-09-11 03:45:29 +03:00
12 lines
214 B
Plaintext
12 lines
214 B
Plaintext
data Option = (Some val) | None
|
|
|
|
Option/and = @a @b match a {
|
|
Option/Some: match b {
|
|
Option/Some: (Option/Some (a.val, b.val))
|
|
Option/None: Option/None
|
|
}
|
|
Option/None: Option/None
|
|
}
|
|
|
|
main = Option/and
|