Perhaps it could be optimised, though.
Cheers,
Simon
S
| -Original Message-
| From: Paul Liu [mailto:nine...@gmail.com]
| Sent: 11 October 2011 22:20
| To: Simon Peyton-Jones
| Cc: cvs-ghc@haskell.org
| Subject: Re: help needed to understand weak reference and its design choice
tuff fully paged out.
S
| -Original Message-
| From: Paul Liu [mailto:nine...@gmail.com]
| Sent: 11 October 2011 22:20
| To: Simon Peyton-Jones
| Cc: cvs-ghc@haskell.org
| Subject: Re: help needed to understand weak reference and its design choice
|
| Hi Simon, thanks a lot for the point
Hi Simon, thanks a lot for the pointer!
I was kind of wondering why mkWeak# has an IO type, and the paper made
it much clearer that it's not about reachability from the Weak#
object, but the side effect that's between key and value objects.
Just out of curiosity, why not implement a memo table wh
| I'm just trying to understand the design rationale behind GHC's weak
| references. Any help is greatly appreciated! Thanks!
Did you read the paper
http://research.microsoft.com/en-us/um/people/simonpj/papers/weak.htm
It gives the design rationale in detail.
Simon
| -Original Message-