X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fcomponents%2Fextlib%2FhExtlib.ml;h=0d19524dcf1842d2667f36de5286b7adfdfb8ba0;hb=dd5a5cfcb19e3ef5059dbb2d777a6f147dd556a6;hp=2f388c0b5e83bbad8ca5359f2d0d936d7aedeb38;hpb=6ba6011b7c8cadb8fe328812e0134e27909fb308;p=helm.git diff --git a/helm/software/components/extlib/hExtlib.ml b/helm/software/components/extlib/hExtlib.ml index 2f388c0b5..0d19524dc 100644 --- a/helm/software/components/extlib/hExtlib.ml +++ b/helm/software/components/extlib/hExtlib.ml @@ -155,6 +155,15 @@ let rec list_iter_default2 f l1 def l2 = | a::ta, [] -> f a def; list_iter_default2 f ta def [] ;; +let rec list_forall_default3 f l1 l2 def l3 = + match l1,l2,l3 with + | [], [], _ -> true + | [], _, _ + | _, [], _ -> raise (Invalid_argument "list_forall_default3") + | a::ta, b::tb, c::tc -> f a b c && list_forall_default3 f ta tb def tc + | a::ta, b::tb, [] -> f a b def && list_forall_default3 f ta tb def [] +;; + let sharing_map f l = let unchanged = ref true in let rec aux b = function