Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
wshuang
on March 19, 2015
|
parent
|
context
|
favorite
| on:
Improving Go's 'container/list'
Sorry, but I just wonder wouldn't this pointer to self structure prevent garbage collection?
davekeck
on March 19, 2015
[–]
Reference cycles aren't a problem for GCs because any objects that aren't reachable from a root set of nodes are considered garbage and get collected. (I only read part of the article, but hopefully that answers your question...)
lmm
on March 19, 2015
|
parent
|
next
[–]
To clarify, they aren't a problem for mark/sweep GCs. Reference counting can be considered a form of GC.
wshuang
on March 19, 2015
|
parent
|
prev
[–]
Cool, thanks :)
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: