aboutsummaryrefslogtreecommitdiffstats
path: root/src/common/Optionmonad.v
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/Optionmonad.v')
-rw-r--r--src/common/Optionmonad.v12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/common/Optionmonad.v b/src/common/Optionmonad.v
index 14a41ef..4a80ff8 100644
--- a/src/common/Optionmonad.v
+++ b/src/common/Optionmonad.v
@@ -63,4 +63,14 @@ Module Option <: Monad.
End Option.
-Module OptionExtra := MonadExtra(Option).
+Module OptionExtra.
+ Module OE := MonadExtra(Option).
+ Export OE.
+
+ Lemma mfold_left_Some :
+ forall A B f x n y,
+ @mfold_left A B f x n = Some y ->
+ exists n', n = Some n'.
+ Proof. induction x; intros; destruct n; eauto. Qed.
+
+End OptionExtra.