diff options
Diffstat (limited to 'src/Data/Maybe')
-rw-r--r-- | src/Data/Maybe/Properties.idr | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/Data/Maybe/Properties.idr b/src/Data/Maybe/Properties.idr index 459cb8f..c9fea96 100644 --- a/src/Data/Maybe/Properties.idr +++ b/src/Data/Maybe/Properties.idr @@ -85,3 +85,8 @@ appNothingInverse : Either (IsNothing f) (IsNothing x) appNothingInverse Nothing x prf = Left ItIsNothing appNothingInverse (Just f) Nothing prf = Right ItIsNothing + +%inline +export +bindNothing : {x : Maybe a} -> (0 ok : IsNothing x) -> (f : a -> Maybe b) -> IsNothing (x >>= f) +bindNothing ItIsNothing f = ItIsNothing |