]> matita.cs.unibo.it Git - helm.git/blobdiff - components/extlib/hExtlib.mli
Bug fixed: inductive types were no longer removed from the environment during
[helm.git] / components / extlib / hExtlib.mli
index a38b09334c7d2cb677c4e673d911f73441015443..0c2206a08bd82339f85cb3ad8c60934b9fcb0aba 100644 (file)
@@ -40,7 +40,6 @@ val safe_rmdir: string -> unit (** removes a dir if it exists and is empty *)
 val is_dir_empty: string -> bool (** checks if the dir is empty *)
 val rmdir_descend: string -> unit (** rmdir -p *)
 
-
   (** find all _files_ whose name matches test under a filesystem root.
    * Test is passed the filename path relative to the given filesystem root *)
 val find: ?test:(string -> bool) -> string -> string list 
@@ -79,6 +78,13 @@ val filter_map: ('a -> 'b option) -> 'a list -> 'b list (** filter + map *)
 val list_concat: ?sep:'a list -> 'a list list -> 'a list (**String.concat-like*)
 val list_findopt: ('a -> 'b option) -> 'a list -> 'b option
 val flatten_map: ('a -> 'b list) -> 'a list -> 'b list
+val list_last: 'a list -> 'a
+
+  (** split_nth n l
+   * @returns two list, the first contains at least n elements, the second the
+   * remaining one
+   * @raise Failure when List.length l < n *)
+val split_nth: int -> 'a list -> 'a list * 'a list
 
 (** {2 Debugging & Profiling} *)