Commits

Anonymous committed e725b35

new Oleg's combinator feedI

  • Participants
  • Parent commits 4d56422

Comments (0)

Files changed (1)

File iteratees.ml

     end
   ;
 
+
+(* Feed Iteratee a piece of stream. Disregard the remaining stream
+   (the operation typically used by enumerators)
+*)
+
+value feedI
+  (k : stream 'el -> IO.m (iteratee 'el 'a  *  stream 'el))
+  (str : stream 'el)
+ :
+  IO.m (iteratee 'el 'a)
+ =
+  k str >>% (IO.return % fst)
+;
+
+
 end
 ;  (* `Make' functor *)