Permalink
Browse files

clear

  • Loading branch information...
1 parent 33c7e76 commit fdbdaa790114f3658f68fea64f230c18e1815480 Jake Donham committed Apr 22, 2010
Showing with 10 additions and 0 deletions.
  1. +4 −0 src/froc/froc_dlist.ml
  2. +6 −0 src/froc/froc_dlist.mli
View
@@ -43,3 +43,7 @@ let iter f d =
if not (t == d)
then (f t.data; loop t.next) in
loop d.next
+
+let clear d =
+ d.next <- d;
+ d.prev <- d
View
@@ -41,3 +41,9 @@ val iter : ('a -> unit) -> 'a t -> unit
is skipped; it is expected that [iter] is called on the dummy
element returned from [empty].
*)
+
+val clear : 'a t -> unit
+ (**
+ Clears the items in the list. Tt is expected that [clear] is
+ called on the dummy element returned from [empty].
+ *)

0 comments on commit fdbdaa7

Please sign in to comment.