[Tutor] weakref module (was: fibonacci [caching]

Danny Yoo dyoo@hkn.eecs.berkeley.edu
Wed Feb 19 00:15:02 2003


On Tue, 18 Feb 2003, Terry Carroll wrote:

> On Fri, 14 Feb 2003, Danny Yoo wrote:
>
> > import weakref
>
> What does this do, in this program?  I've read the docs on weakref and,
> while I admit I don't completely get it, I don't see what it does in
> this fibonacci code.  The program (seems to) work without it, too.

Absolutely nothing.  *grin*

I goofed and was about to do some experiments with the "weak references"
module (weakref), and when I cut and paste, I accidently pasted that
module import in too.

(I was planning to use it with the fibonacci cache, but then thought that
it might just complicate matters... for me.  *grin*)

Talk to you later!