On Wednesday, May 27, 2015 06:05:54 AM Michael Turok wrote:
> Thanks folks!    I guess that's also why WeakRef() isn't documented.  ;-)

Feel free to add some documentation ;-). It's as simple as 
https://github.com/JuliaLang/julia/blob/master/CONTRIBUTING.md#improving-documentation

--Tim

> 
> On Tuesday, May 26, 2015 at 4:06:29 PM UTC-4, Stefan Karpinski wrote:
> > Yes, that's right. Cycles are collected by mark-and-sweep GC – when a
> > cyclic structure is no longer reachable, none of it is marked, allowing it
> > to be freed during the sweep phase.
> > 
> > On Tue, May 26, 2015 at 11:37 AM, Yichao Yu <[email protected]
> > 
> > <javascript:>> wrote:
> >> On Tue, May 26, 2015 at 11:31 AM, Michael Turok <[email protected]
> >> 
> >> <javascript:>> wrote:
> >> > In looking at the manual for incompletely initialized classes (click
> >> 
> >> here),
> >> 
> >> > with an example of a SelfReferential class, wouldn't you want to wrap
> >> 
> >> this
> >> 
> >> > in a WeakRef()?
> >> > 
> >> > Or does the GC know what to do when it encounters a circular reference
> >> > already?
> >> 
> >> AFAICT, circular reference is only an issue for reference counting.
> >> Julia's mark and sweep GC doesn't have that problem.
> >> 
> >> > Thanks,
> >> > Michael

Reply via email to