diff options
author | Greg Brown <greg.brown01@ed.ac.uk> | 2023-07-12 14:02:42 +0100 |
---|---|---|
committer | Greg Brown <greg.brown01@ed.ac.uk> | 2023-07-12 14:02:42 +0100 |
commit | fd658831ab53f07969524fee0257d086d6f79f5a (patch) | |
tree | b1861aa0f726f35a40ec0f5c0809a845b39c4361 /src/Data/Maybe/Properties.idr | |
parent | 66658a7102c5761fe6e4cfc5058f2fdafaa71b36 (diff) |
Prove unification correct.
Diffstat (limited to 'src/Data/Maybe/Properties.idr')
-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 |