Re: touch# primitive

2018-09-19 Thread Ben Gamari
Daniel Cartwright writes: > in GHC.Prim, there is a primitive 'touch#'. It seems that it is used to > keep pointers alive, and takes something of any runtime representation, and > a State# RealWorld, but there's really no documentation on it, so my idea > of what it does is just a guess. Can anyo

Re: touch# primitive

2018-09-18 Thread Ben Lippmeier
> On 19 Sep 2018, at 1:07 am, Daniel Cartwright wrote: > > in GHC.Prim, there is a primitive 'touch#'. It seems that it is used to keep > pointers alive, and takes something of any runtime representation, and a > State# RealWorld, but there's really no documentation on it, so my idea of > wha

touch# primitive

2018-09-18 Thread Daniel Cartwright
in GHC.Prim, there is a primitive 'touch#'. It seems that it is used to keep pointers alive, and takes something of any runtime representation, and a State# RealWorld, but there's really no documentation on it, so my idea of what it does is just a guess. Can anyone explain what exactly it does? ___