2 ms·
If you're allocating the entire linked list at once, that may well happen in practice. Otherwise, there is no good way it can happen automatically; but, compact
by tsimionescu 4y ago
If you're allocating the entire linked list at once, that may well happen in practice. Otherwise, there is no good way it can happen automatically; but, compacting GCs will usually do this for you (assuming that the list elements are only reachable from the previous element).
- ShredKazoo 4y agoInteresting thanks!