added setmp_thread_data_seq;
authorwenzelm
Thu, 24 Jan 2008 23:51:13 +0100 (2008-01-24)
changeset 25954 682e84b60e5c
parent 25953 03937086b1fe
child 25955 94a515ed8a39
added setmp_thread_data_seq;
src/Pure/General/position.ML
--- a/src/Pure/General/position.ML	Thu Jan 24 23:51:11 2008 +0100
+++ b/src/Pure/General/position.ML	Thu Jan 24 23:51:13 2008 +0100
@@ -19,6 +19,7 @@
   val properties_of: T -> Markup.property list
   val thread_data: unit -> T
   val setmp_thread_data: T -> ('a -> 'b) -> 'a -> 'b
+  val setmp_thread_data_seq: T -> ('a -> 'b Seq.seq) -> 'a -> 'b Seq.seq
   val str_of: T -> string
 end;
 
@@ -64,6 +65,9 @@
 fun thread_data () = the_default none (Multithreading.get_data tag);
 fun setmp_thread_data pos = Library.setmp_thread_data tag (thread_data ()) pos;
 
+fun setmp_thread_data_seq pos f seq =
+  setmp_thread_data pos f seq |> Seq.wrap (fn pull => setmp_thread_data pos pull ());
+
 end;