src/Pure/Concurrent/synchronized.ML
changeset 32592 e29c0b7dcf66
parent 32295 400cc493d466
child 32738 15bb09ca0378
     1.1 --- a/src/Pure/Concurrent/synchronized.ML	Wed Sep 16 21:31:57 2009 +0200
     1.2 +++ b/src/Pure/Concurrent/synchronized.ML	Wed Sep 16 22:46:10 2009 +0200
     1.3 @@ -8,7 +8,6 @@
     1.4  sig
     1.5    type 'a var
     1.6    val var: string -> 'a -> 'a var
     1.7 -  val peek: 'a var -> 'a
     1.8    val value: 'a var -> 'a
     1.9    val timed_access: 'a var -> ('a -> Time.time option) -> ('a -> ('b * 'a) option) -> 'b option
    1.10    val guarded_access: 'a var -> ('a -> ('b * 'a) option) -> 'b
    1.11 @@ -33,9 +32,7 @@
    1.12    cond = ConditionVar.conditionVar (),
    1.13    var = ref x};
    1.14  
    1.15 -fun peek (Var {var, ...}) = ! var;  (*unsynchronized!*)
    1.16 -
    1.17 -fun value (Var {name, lock, cond, var}) = SimpleThread.synchronized name lock (fn () => ! var);
    1.18 +fun value (Var {var, ...}) = ! var;
    1.19  
    1.20  
    1.21  (* synchronized access *)