Closed duythinht closed 7 years ago
Thanks, this is great idea! A bit unsure if I want to use .value
, (as it is sort of a hack) and perhaps impl. __bool__()
for both Nothing
and Maybe
. But I can change that later if I decide to do it that way.
In my opinion we need combine Maybe instance by boolean operator. For example when I want to check a value is None and return Nothing instead of Just(None)
Should be