>
>
> The main question is: does the STM transaction actually "see" that I
> changed
> part of the underlying array, so that the transaction gets re-tried? Or do
> I
> have to implement this manually, and if yes: how?
>
>
The transaction does not detect anything inside the unsafeIOtoSTM.  But to
implement this manually is  simple: use "retry" whenever you need to retry
the local  transaction. if the affected transactions are more than the local
trnasaction, create an special TVar to be inspected by all of them. for
example  doesTheArrayHasChanged :: TVar Bool.
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to