src/Pure/General/position.ML
changeset 28122 3d099ce624e7
parent 28017 4919bd124a58
child 29307 3a0b38b7fbb4
equal deleted inserted replaced
28121:2303b4c53d3a 28122:3d099ce624e7
   159 
   159 
   160 (* thread data *)
   160 (* thread data *)
   161 
   161 
   162 local val tag = Universal.tag () : T Universal.tag in
   162 local val tag = Universal.tag () : T Universal.tag in
   163 
   163 
   164 fun thread_data () = the_default none (Multithreading.get_data tag);
   164 fun thread_data () = the_default none (Thread.getLocal tag);
   165 
   165 
   166 fun setmp_thread_data pos f x =
   166 fun setmp_thread_data pos f x =
   167   if ! Output.debugging then f x
   167   if ! Output.debugging then f x
   168   else Library.setmp_thread_data tag (thread_data ()) pos f x;
   168   else Library.setmp_thread_data tag (thread_data ()) pos f x;
   169 
   169